Files
gbrain/test
Garry TanandClaude Fable 5 8fa9bed815 review: empty-file skip must not enter the sync failure ledger; keep inline extract for non-brainDir sync targets
Two adversarial-review fixes on the #840/#1079 takeovers:

1. importCodeFile's empty-file skip returned skipped WITH an error string.
   performSync treats skipped-with-error as a parse failure (failedFiles →
   applySyncFailureGate), so any repo containing a legitimate empty code
   file (__init__.py, barrel stubs) would BLOCK last_commit for 3
   consecutive syncs and then live in the ledger as auto-skipped — the
   fix recreated #840's spurious-failure complaint one layer up, and the
   became-empty branch reported its own successful stale-page deletion as
   a failure. The skip now carries no error, matching the content-hash
   short-circuit (banked via markCompleted, never ledgered).

2. runPhaseSync passed noExtract: willRunExtractPhase to EVERY sync
   target, but the cycle's extract phase (runPhaseExtract →
   extractForSlugs) walks brainDir only — slugs synced from other
   sources' checkouts are invisible to it, so their link/timeline
   extraction was silently dropped forever. Inline extract is now
   deduped only for the brainDir target; other targets keep it, matching
   standalone 'gbrain sync --source X' behavior. Pinned by a new
   cycle.serial test.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
2026-07-22 11:07:49 -07:00
..