Bug Report
Environment
- ob version: latest as of 2026-03-26
- Node.js: 22+
- OS: Ubuntu (headless server) + macOS (desktop)
- Sync plan: Active
Description
Running ob sync --continuous in bidirectional mode causes files to be overwritten with stale/empty local copies, resulting in data loss across all synced devices. Initially observed on a headless Linux server, but the root cause was traced to a macOS desktop device — the bug is in the shared sync engine.
Steps to Reproduce
- Have a vault actively synced to Obsidian Sync from multiple devices
- Edit or create files on one device — Sync pushes them to remote
- Another device (running continuously) picks up the changes but re-uploads stale local copies, overwriting the valid remote content
Observed Behavior
Files oscillate between their correct content and 0 bytes (or frontmatter-only). The Obsidian Sync version history shows a clear pattern:
version 1: 0 B (stale push)
version 2: 2.34 KB (correct content)
version 3: 1.67 KB (partial/frontmatter only — stale push)
version 4: 2.34 KB (corrected)
version 5: 1.67 KB (stale push again)
...repeating
Expected Behavior
After downloading a remote change, the sync engine should not re-upload the file it just downloaded.
Impact
Silent data loss. Files appear to save correctly but are quietly overwritten. Recovery is possible via version history, but only if caught in time.
Workaround
Use --mode pull-only on devices that don't need to push changes.
Bug Report
Environment
Description
Running
ob sync --continuousin bidirectional mode causes files to be overwritten with stale/empty local copies, resulting in data loss across all synced devices. Initially observed on a headless Linux server, but the root cause was traced to a macOS desktop device — the bug is in the shared sync engine.Steps to Reproduce
Observed Behavior
Files oscillate between their correct content and 0 bytes (or frontmatter-only). The Obsidian Sync version history shows a clear pattern:
Expected Behavior
After downloading a remote change, the sync engine should not re-upload the file it just downloaded.
Impact
Silent data loss. Files appear to save correctly but are quietly overwritten. Recovery is possible via version history, but only if caught in time.
Workaround
Use
--mode pull-onlyon devices that don't need to push changes.