Conversation
added 2 commits
April 21, 2026 14:02
Claude sessions need a separate sandbox root under .omc, but the shared branch-start, finish, prune, setup, and workspace-discovery paths still have to agree on where a branch lives. This keeps the root decision centralized, stores it on the branch, and extends the docs and install regressions around both managed worktree roots. Constraint: Claude and Codex sessions must keep separate managed worktree roots while sharing the same finish and prune scripts Rejected: Add Claude-only finish/prune variants | duplicates Guardex workflow authority and recovery logic Confidence: high Scope-risk: moderate Reversibility: clean Directive: Keep live scripts, template copies, and install regressions aligned whenever worktree-root routing changes Tested: node --test --test-name-pattern='into nested git repos, skipping node_modules/worktrees/submodules|setup --parent-workspace-view creates one-level-up VS Code workspace for repo \+ agent worktrees|doctor on protected main bootstraps sandbox branch even before setup exists|setup agent-branch-start routes Claude sessions into \.omc worktrees and stores the selected root|agent-branch-finish handles Claude-root worktrees when inferring base from source branch metadata' test/install.test.js; node --check bin/multiagent-safety.js; bash -n scripts/agent-branch-start.sh scripts/agent-branch-finish.sh scripts/agent-worktree-prune.sh templates/scripts/agent-branch-start.sh templates/scripts/agent-branch-finish.sh templates/scripts/agent-worktree-prune.sh; node --test test/frontend-how-it-works.test.js test/fuzzing.test.js test/metadata.test.js; npm_config_cache=/tmp/guardex-npm-cache npm pack --dry-run Not-tested: full npm test remains red because test/metadata.test.js already fails on main in 'active doctor command remains single-source and runs the repair-first path'
The first finish attempt rebased cleanly except for a stale assertion, and the post-conflict fallback check exposed that agent-worktree-prune still referenced a removed single-root variable. This follow-up keeps relocation logic iterating across both managed roots and aligns the fallback test with the message codex-agent emits today. Constraint: Cleanup paths must work for both .omx and .omc managed worktrees without reintroducing separate prune implementations Rejected: Leave the prune warning as a known issue | it breaks auto-cleanup during the exact fallback flow this branch touches Confidence: high Scope-risk: narrow Reversibility: clean Directive: When changing managed worktree root selection, re-run both prune cleanup paths and the codex-agent fallback test together Tested: bash -n scripts/agent-worktree-prune.sh templates/scripts/agent-worktree-prune.sh; node --test --test-name-pattern='into nested git repos, skipping node_modules/worktrees/submodules|setup --parent-workspace-view creates one-level-up VS Code workspace for repo \+ agent worktrees|doctor on protected main bootstraps sandbox branch even before setup exists|setup agent-branch-start routes Claude sessions into \.omc worktrees and stores the selected root|agent-branch-finish handles Claude-root worktrees when inferring base from source branch metadata' test/install.test.js; node --test --test-name-pattern='codex-agent restores local branch and falls back to safe worktree start when starter script switches in-place' test/install.test.js Not-tested: full npm test remains red on main because test/metadata.test.js already fails in 'active doctor command remains single-source and runs the repair-first path'
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Automated by scripts/agent-branch-finish.sh (PR flow).