Skip to content

Reuse unfinished matching agent worktrees#443

Merged
NagyVikt merged 1 commit intomainfrom
agent/codex/reuse-dirty-matching-worktree-on-branch-2026-04-28-00-56
Apr 27, 2026
Merged

Reuse unfinished matching agent worktrees#443
NagyVikt merged 1 commit intomainfrom
agent/codex/reuse-dirty-matching-worktree-on-branch-2026-04-28-00-56

Conversation

@NagyVikt
Copy link
Copy Markdown
Collaborator

Automated by gx branch finish (PR flow).

A continuation prompt can refer to an interrupted dirty sandbox that is no longer present in live handoff state. Branch start now scans managed dirty same-agent worktrees before allocating a fresh branch, so takeover-style follow-ups can attach to the preserved sandbox instead of duplicating copied changes.

Constraint: Matching must work without relying on .omx/notepad.md or active-session files.\nRejected: Always reuse any dirty same-agent worktree | too likely to steal unrelated stalled lanes\nRejected: Require exact branch-task text match | misses broader continuation wording like billing replacement versus billing sections\nConfidence: high\nScope-risk: moderate\nDirective: Keep matching conservative and dirty-worktree scoped; do not widen to clean branches without merge-state proof.\nTested: bash -n scripts/agent-branch-start.sh\nTested: bash -n templates/scripts/agent-branch-start.sh\nTested: node --test test/branch.test.js\nTested: node --test --test-name-pattern "critical runtime helper scripts" test/metadata.test.js\nTested: openspec validate agent-codex-reuse-dirty-matching-worktree-on-branch-2026-04-28-00-56 --type change --strict\nTested: openspec validate --specs\nNot-tested: Full node --test test/*.test.js; existing README about_description link assertion fails in metadata.test.js outside this change
@NagyVikt NagyVikt merged commit c795d4a into main Apr 27, 2026
@NagyVikt NagyVikt deleted the agent/codex/reuse-dirty-matching-worktree-on-branch-2026-04-28-00-56 branch April 27, 2026 23:05
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant