feat(FN-4917): complete Step 6 — document recovery contract and changeset

Fusion-Task-Id: FN-4917
Fusion-Task-Lineage: 1422a545-f4b5-4e1f-a347-8be2a4202f45
This commit is contained in:
Fusion (runfusion.ai)
2026-05-17 11:32:59 -07:00
committed by gsxdsm
parent 1dffcb492e
commit 5aeb7645ee

View File

@@ -0,0 +1,13 @@
---
"@runfusion/fusion": patch
---
Prevent and auto-recover "Refusing to start coding agent in incomplete
worktree" session-start failures. The worktree-acquisition layer now
classifies pool-returned and resume worktrees before handing them to the
executor, and the executor's two `createResolvedAgentSession` call sites
catch the three `assertValidWorktreeSession` variants in `in-progress`,
emit `worktree:incomplete-detected` + `worktree:auto-recovered` run-audit
telemetry, and requeue the task to `todo` via the shared
`autoRecoverWorktreeSessionStartFailure` helper instead of surfacing the
error to the user. Bounded by `MAX_WORKTREE_SESSION_RETRIES = 3`.