Repository navigation
Add optional managed worktree root policy - #1414
Conversation
swjnxyf
left a comment
There was a problem hiding this comment.
Reviewed PR #1414 on special without creating a worktree. The optional policy.managed_worktree_root remains confined to effective allowed_roots, is revalidated at creation/resume, and preserves the derived placement when absent and existing managed-worktree identities on resume. I identified a Windows-only test compilation omission caused by the added RunnerPolicy field and pushed a focused follow-up commit 7a4e1d01f adding managed_worktree_root: None to the Windows persistent-shell fixture. The focused special-host test suites passed: managed_worktree (22) and config_reload (21), as did cargo fmt --all -- --check and git diff --check. The original CI run failed in the test-macos aggregate gate because changes was abandoned, not because the code tests ran and failed. A new full CI run was triggered by the fix; its native platform jobs are currently in progress. No further code-review blockers found; approving, with final integration still subject to CI results.
Closes #1272
Adds optional
[policy].managed_worktree_rootfor central placement of newly created managed worktrees while preserving the existing derived placement when unset.The configured root is validated as an absolute, existing, non-redirected directory inside effective
allowed_roots; invalid values fail closed during config check/reload and are revalidated at creation and resume. Existing worktrees remain in place, with operation identity, collision handling, lineage, and recovery preserved.Also updates the English and zh-CN Runner guides and adds focused multi-root, invalid-path, hot-reload, redirected-path, placement, and resume coverage.
Validation:
cargo test -p webcodex-runner --profile dogfood managed_worktree(22 passed)cargo test -p webcodex-runner --profile dogfood config_reload(21 passed)cargo fmt --all -- --checkpython3 scripts/check_markdown_links.pygit diff --checkThe full Runner suite had one unrelated pre-existing failure in
webcodex_runner::coding_agent::tests::diagnostics::explicit_path_mapping_restores_an_interpreter_outside_default_search_paths; 1225 passed, 11 ignored.