Distinguish an empty turn from a failed turn end to end #406
No reviewers
Labels
No labels
Compat/Breaking
Kind/Bug
Kind/Documentation
Kind/Enhancement
Kind/Feature
Kind/Security
Kind/Testing
Priority
Critical
Priority
High
Priority
Low
Priority
Medium
Reviewed
Confirmed
Reviewed
Duplicate
Reviewed
Invalid
Reviewed
Won't Fix
Status
Abandoned
Status
Blocked
Status
Need More Info
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
toasterson/Anima!406
Loading…
Reference in a new issue
No description provided.
Delete branch "claude/wi-019fa59c-distinguish-an-empty-turn-from-a-failed"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Anima work item
019fa59c-941f-7942-961c-5950e1405669(WI-387).Salvaged work. The implementer completed this turn at 18:31 UTC on 2026-07-28 — ~1000 events, reporting "everything compiles and all 323 unit tests pass" — and the runner discarded it. The content gate added in #396 reads the staged diff, but the forcing prompt asks the agent to commit and opencode does, so
git add -Afound nothing to stage, the turn was classified scaffold-only, and no branch was pushed. The commit survived only in the runner's worktree volume; I recovered it viagit bundleand rebased it onto currentmain. The fix for the discard itself is in a separate PR.The commit is the agent's own, unmodified — author and message preserved.
What it does
Most of the failed-turn branching landed in #402 (WI 019fa7ac). This closes the four remaining gaps the acceptance criteria name:
TurnOutcome(Completed/Empty/Failed) on the witness, folded into the witness hash so a failed turn and an empty turn can never share a hash. The detector reads the classification rather than inferring it from diff emptiness.outcomecolumn; legacy rows (NULL) hash differently from any classified row, so the cutover is a clean break.acp.turn_completedcarriesoutcome; summaries read "Turn completed" / "Turn empty (no progress)" / "Turn failed — <detail>".TurnDone(the "healthy-looking session with very few events and noturn_completed" shape) now records aFailedwitness, so K consecutive identical-cause session deaths park.Verification
cargo check --workspace --all-targetsclean against currentmainafter rebase. Migration 082 does not collide (main is at 081).🤖 Generated with Claude Code
d2f8a5e1aato8d26e1907d