claude exits 1 with an active git stash; harness ships/merges a scratch commit instead of the feature (porksicle #110 -> #305
Labels
No labels
Agent
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 assignees
1 participant
Notifications
Total time spent: 3 minutes 2 seconds
Due date
igor
3 minutes 2 seconds
No due date set.
Dependencies
No dependencies set
Reference
joshtronic/igor#305
Loading…
Reference in a new issue
No description provided.
Delete branch "%!s()"
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?
Diagnosis
On the tick that claimed porksicle.com#110 ("Reframe the homepage stats"), claude implemented the change, then ran a
git stashto capture "before" (master-state) screenshots. It exited 1 while the stash was still active -- before restoring its feature edits (git stash pop). Last action was reading the before screenshot, mid-workflow:The harness's commit-everything step then saw only the leftover untracked screenshot script (the real edits were stashed away) and committed that:
PR #114 shipped a scratch playwright script, not the stats reframe, and was auto-merged to master:
Issue #110's requested change was silently dropped, the issue was falsely resolved (time logged, PR merged), and dead scratch code now lives in master. Contrast #108, which also
claude exited 1 (elapsed 224s)but only after restoring its stash, so it shipped correctly (harness-commit: 3 file(s), subject: feat: add copyright year to site footer). The bug is exit-1 timing vs. stash-restore, plus the harness committing an active-stash tree with no guard.What "fixed" looks like
git stash listis non-empty, or when the diff/commit-subject doesn't correspond to the claimed issue -- abort the ship instead of committing whatever remains.git stash pop) in the cleanup trap before the commit step.chore: add script to capture before screenshotschange from master.service: agent.service
severity: high
window: 2026-06-30 21:00-22:00 (filed by the hourly logwatch pass)
Resolved — closing.
The harness defect (the issue-ship path committing/shipping a partial worktree on a nonzero
claudeexit) is fixed in #307, merged and live in production (the fail-safe${CLAUDE_EXIT:-1}gate now refuses to commit an interrupted run).The porksicle residue is handled too: the #110 reframe had already shipped correctly on the retry (porksicle#116, "Closes #110"), and the stray
shot-before.mjsscratch file is removed by porksicle#117 (approved, merging shortly).Note: #307 makes an exit-1 non-catastrophic (no more wrong-diff ships) but doesn't cure the exit-1 itself — that root-cause continues in #306.