This release fixes vaults created with Self-hosted LiveSync 1.0.49+ failing to open (#58). Those vaults use Unicode NFC path identity, which the previous livesync-commonlib did not support. The library moves from 0.1.34 to 0.5.0, the server detects each vault's path identity at startup, and a new COUCHDB_PATH_NORMALIZATION setting covers brand-new empty databases. Existing vaults behave as before.
Features
COUCHDB_PATH_NORMALIZATION(auto,nfc,legacy; defaultauto).autofollows an existing database and uses NFC for a brand-new empty one, matching what LiveSync 1.0.49+ creates, with a startup warning naming the override. The server declares the choice in the empty database at startup, so a LiveSync device with the other identity is refused by LiveSync with its usual rebuild/fetch message rather than syncing into a mismatched vault. Setlegacybefore first starting the server if your LiveSync devices use legacy identity. An explicit value that contradicts a populated database fails startup with guidance instead of the library's generic error.
Fixes
- Vaults created with LiveSync 1.0.49+ failed to open (#58) with
Unknown features are in use: nfc-path-identity-v1. New LiveSync databases use Unicode NFC path identity by default, which the pinned livesync-commonlib (0.1.34) did not know. The server now reads the database's path identity at startup and opens NFC vaults with the matching setting; legacy vaults are unchanged. On an NFC vault, NFC and NFD spellings of a path (e.g.Café.mdtyped on macOS vs. Linux) resolve to the same note. Reported and tested by @HobbyIngenieur (#59). - CouchDB mode: closing a vault connection, including the automatic reopen when
COUCHDB_OBFUSCATE_PROPERTIESis corrected at startup, left livesync-commonlib's internal changes feed running. On an encrypted vault that stale connection could take over the shared sync-parameters cache, after which every encrypt/decrypt failed withFailed to fetch synchronisation parameters. The feed is now stopped explicitly on close.
Dependencies
- Bump livesync-commonlib from 0.1.34 to 0.5.0 (adds
@vrtmrz/value-store;octagonal-wheelsto 0.1.56).
CI
- The CouchDB harness also runs with
TEST_PATH_NORMALIZATION=legacy, so the general scenarios are covered on both path identities. - New
npm run test:smoke: the built server over MCP against a real CouchDB across vault configurations (not run in CI).
Upgrade note
- No action is needed for existing vaults: their path identity is read from the database. Only a server pointed at an empty database behaves differently: at startup it now declares NFC, which LiveSync before 1.0.38 cannot open. Set
COUCHDB_PATH_NORMALIZATION=legacyin that case.