Skip to content

v2.1.2 — sync-engine hardening round 2 (harvest data integrity)

Choose a tag to compare

@KeilerHirsch KeilerHirsch released this 14 Jul 16:59
· 33 commits to main since this release

Second correctness pass on the harvest/sync engine — a data-integrity release. Driven by a full byte-level teardown of the codebase plus three independent multi-agent review rounds.

Fixed

  • A Cloudflare/login/WAF HTML page or a JSON API-error body (e.g. a 404 for a since-deleted conversation) could be saved as a conversation — and once written, was skipped forever. Both are now rejected before they can be persisted as, or overwrite, a real export.
  • Legacy poisoned files now self-heal on the daemon path (the on-disk - Updated: header is checked, not just file size).
  • Failed conversations retry on the next cycle — bounded, so a permanently-failing item can't make the daemon re-list and pop Chrome every interval forever.
  • Partial project-doc failures are propagated; empty memory is a no-op; a mid-harvest session timeout is a hard error; the one-shot harvest now refreshes changed conversations and exits non-zero on errors.

The security surface is unchanged — gosec, staticcheck and govulncheck are all clean. Tests-first; statement coverage 27.2% → 28.4%.

Still open (deferred to a follow-up): a single-instance guard (lockfile / named mutex) so two daemons can't share one output directory.

Full details in CHANGELOG.md.