Repository navigation
Description
The claim
An unwritable evidence log kills the capture subscription permanently, and nothing tells the user. PR #474 guarded the auto_capture_start receipt with try/catch so a failed evidence write cannot abort the pass it reports. The same class of failure remains reachable through the other evidence writes: the capture_cost receipt and the auto_capture_refused write inside the pass-error handler (src/capture/runtime.ts, throw path into the for await subscription loop around :1182). When any of them throws, the loop ends and capture is dead for the rest of the process — silently.
Reproduction
Evidence file set 0400 (uid 501 → EACCES on append), two sequential turns, count model calls:
turn1_reached=true turn2_reached=false
Turn 1 reaches the model because the guarded receipt survives; the capture_cost write then throws and ends the subscription, so turn 2 never dispatches. origin/main dies identically — the difference is only which write fires first. The capture_threw receipt that would report the failure cannot be written either, because the log is the thing that is broken.
Why it matters
The evidence log is diagnostic telemetry. A diagnostic channel that is unwritable should degrade observability, not disable the feature it observes. Today a full disk, a permissions change, or a symlink swap on one file permanently stops auto-capture with no signal in memory_status and no line in the log.
The fix, as a policy
Decide once what an evidence-write failure means, and apply it at every write site:
- Evidence writes are best-effort: catch at the call boundary, never let one escape into the subscription loop.
- A repeated failure must still become visible — a counter checked by
memory_statusis enough; a log line about the log being broken cannot work. - The
for awaitloop survives every handler failure. A test that breaks the log mid-session and asserts the next turn still captures pins the contract.
Sites to sweep: every appendLog/recordSync call reachable from the capture handler, not just the three named above.
Where
Raised while reviewing PR #474 (round-3 review, follow-up the PR body files). Pre-existing on main; #474 removed the happy-path trigger, this ticket is the remaining policy.
Activity
abogartz-opencode-self-improvement commentedon Nov 22, 2026
🎉 This issue has been resolved in version 0.33.10 🎉
The release is available on:
Your semantic-release bot 📦🚀