chore: drop the dead CouchDB sync channel - #107
Merged
Conversation
The server-side couch device channel was removed 2026-07-31; channelForVault()
has returned {channel:'git'} unconditionally ever since, so every couch code
path was unreachable. Deletes src/couch/, the couch fields/branches in main.ts
and resolve-host.ts, and the couch-only integration test suite + fakes.
Contributor
|
🎉 PR Validation ✅ PASSED Commit: Checks:
Ready to merge! ✨ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
CouchDB was dropped as a sync channel on 2026-07-31: the server route the plugin minted its per-memory JWT from (
POST /account/couch-token) was deleted then, and git smart-HTTP is the only device channel now. Everything removed here could only ever fail.The channel was already unreachable in practice - discovery has not advertised
couchsince the cutover, sochannelForVault()returnedgitfor every memory and the whole branch was dead weight.What goes
src/couch/in full - channel, doc model, state, sync, token client (10 files).main.ts: the live-replication event wiring (modify/create/delete/rename + the 2s tick),couchSyncNow/buildCouchSync/couchStateFor, the token-post wiring, and bothchannel === 'couch'branches - the sync path and the preview path.resolve-host.ts:channelForVault,VaultChannel,parseCouchVaultand the three couch fields onSyncResolution.settings.ts:couchState/CouchMemoryState, dead oncecouchStateForwas gone.gitBoundMemory()- its only caller was the couch guard that kept a couch memory out of a git-bound folder.What does not change
buildRepoUrl,gitEndpoint,HostResolverand its cache, OAuth, and every/api/memoriescall are untouched. The sync path now unconditionally builds the git remote, which is what it already did for every real memory.Test coverage
29 files, -2,869 lines. That includes
src/main.test.tsand 5 of 6 integration suites (delete-conflict,first-sync,preview-count,resilience,sync-roundtrip) - each one existed only to exercise CouchDB replication;main.test.ts's four tests were couch-teardown and the git-bound-folder guard.lifecycle.test.tskeeps its non-couch connect-flow test,management.test.tsis untouched.97 tests pass, coverage stays above the 70% floor. Nothing that survives lost a test.