{"id":23799854,"url":"https://github.com/martishin/crdt-editor","last_synced_at":"2026-05-07T02:31:17.741Z","repository":{"id":261885349,"uuid":"885604397","full_name":"martishin/crdt-editor","owner":"martishin","description":"Collaborative, conflict-free CRDT store implemented using Rust and integrated with FastAPI server and React.js client","archived":false,"fork":false,"pushed_at":"2025-12-20T21:33:50.000Z","size":67,"stargazers_count":3,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2026-04-17T06:39:40.698Z","etag":null,"topics":["crdt","pyo3","python","reactjs","rust","typescript","websocket"],"latest_commit_sha":null,"homepage":"https://crdt.martishin.com/","language":"Rust","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/martishin.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2024-11-08T23:21:37.000Z","updated_at":"2025-12-20T21:33:53.000Z","dependencies_parsed_at":"2025-10-21T12:15:43.017Z","dependency_job_id":null,"html_url":"https://github.com/martishin/crdt-editor","commit_stats":null,"previous_names":["martishin/rust-crdt-lww","martishin/react-python-rust-crdt","martishin/react-python-rust-crdt-editor","martishin/crdt-editor"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/martishin/crdt-editor","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/martishin%2Fcrdt-editor","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/martishin%2Fcrdt-editor/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/martishin%2Fcrdt-editor/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/martishin%2Fcrdt-editor/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/martishin","download_url":"https://codeload.github.com/martishin/crdt-editor/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/martishin%2Fcrdt-editor/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":32720109,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-05-07T02:14:30.463Z","status":"ssl_error","status_checked_at":"2026-05-07T02:14:29.405Z","response_time":62,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.6:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["crdt","pyo3","python","reactjs","rust","typescript","websocket"],"created_at":"2025-01-01T21:27:49.447Z","updated_at":"2026-05-07T02:31:17.716Z","avatar_url":"https://github.com/martishin.png","language":"Rust","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Collaborative CRDT Editor\nA WebSocket-based server implemented in Python with a Rust-backed CRDT (Conflict-free Replicated Data Type) functionality, providing real-time data synchronization and persistence. The server enables clients to connect, add, update, and remove key-value pairs, with all operations broadcast to connected clients.\n\n[Check out the live demo here!](https://crdt.martishin.com/)\n\n\u003cimg src=\"https://i.giphy.com/media/v1.Y2lkPTc5MGI3NjExdTQ2bjIybDJ1cWN1dWlud3dmOHFnOGR6MmhrNTdjYmR1eHpnaWxjaSZlcD12MV9pbnRlcm5hbF9naWZfYnlfaWQmY3Q9Zw/CxGDTYaEOq1vVKUEMe/giphy.gif\" width=\"700\"/\u003e\n\n## Features\n* Blazingly fast \u0026 reliable CRDT - Last-Write-Wins (LWW) Element Dictionary for conflict resolution  \n* Real-time synchronization - any changes to data are instantly reflected on all connected clients\n\n## Running Locally\n\n### Prerequisites\n- Python \u0026 Conda - for running the server\n- Node.js \u0026 npm - for running the React client\n- Rust - for building the CRDT library\n\n### Build the CRDT Library\n```bash\nmake build-lib\n```\n\n### Run the Server\n```bash\nmake run-server\n```\n\n### Run the Client\n```bash\nmake run-client\n```\n\n### Run Tests\n```bash\nmake test\n```\n\n## Algorithm\nThe LWW-Element-Dictionary CRDT is a data structure that allows multiple replicas to manage data independently and concurrently, resolving any inconsistencies that may arise. Here’s a deeper look at its functionality:\n\n### Conflict Resolution\nEach entry in the dictionary has:\n\n* A timestamp marking when it was last modified  \n* The value itself, paired with its timestamp  \n\nWhen a key’s value is updated, if the incoming timestamp is later than the existing one, the new value overwrites the old one. If a remove operation is applied with a more recent timestamp, the key is marked as removed, and any additions with earlier timestamps are ignored.\n\n### Key Operations\n* Add: Adds or updates a key-value pair if the incoming timestamp is more recent than the current one.\n* Remove: Marks a key as removed, only if the remove timestamp is later than any existing timestamps.\n* Lookup: Retrieves the value for a key if it exists and hasn’t been marked as removed.\n* Merge: Combines another dictionary with this one, resolving any conflicts based on timestamps, which allows distributed replicas to synchronize data effectively.\n\nThe CRDT approach ensures that changes made by any client will eventually propagate to all others, and the Last-Write-Wins strategy guarantees deterministic conflict resolution.\n\n## Technologies Used\n* TypeScript (Client) - A front-end built with Vite and React, providing a responsive interface for real-time data editing\n* Python (Server) - The FastAPI WebSocket server handles connections, synchronization, and data persistence\n* Rust (CRDT Library) - A high-performance CRDT library providing a Last-Write-Wins Element Dictionary for conflict resolution\n\nThis project is a powerful demonstration of cross-language interoperability, with each layer of the stack contributing to a robust, real-time distributed system.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmartishin%2Fcrdt-editor","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fmartishin%2Fcrdt-editor","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmartishin%2Fcrdt-editor/lists"}