fix(kanban): constrain worktrees to configured external root - #9
Conversation
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 47bd776fba
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
| if configured_target is not None: | ||
| # Persist the final canonical target at publication time. The | ||
| # dispatcher revalidates it before any filesystem write. | ||
| insert_workspace_path = str(configured_target) |
There was a problem hiding this comment.
Allocate distinct policy targets to decomposed children
When a worktree-backed triage card is decomposed with the policy enabled, persisting the parent-specific leaf here causes decompose_triage_task() to copy that same workspace_path into every child. The first child materializes its branch there, while subsequent children reuse the same checkout and even resolve to the first child's branch, so parallel workers can overwrite one another's results. Preserve enough source-repository identity for decomposition to derive a separate leaf for each child.
AGENTS.md reference: AGENTS.md:L54-L57
Useful? React with 👍 / 👎.
| repo = _project_repo_root(project_id) | ||
| if repo is not None: |
There was a problem hiding this comment.
Preserve source identity across profile dispatch
When a project-linked task is created under one profile and claimed by a dispatcher running another profile before its worktree exists, this lookup reads the dispatcher's per-profile projects.db, where the project need not exist. With no board default, the persisted external target is not yet a Git checkout, so every fallback fails and the task accumulates workspace spawn failures instead of dispatching; previously the persisted repo anchor made this supported cross-profile handoff independent of projects.db. Persist or otherwise resolve the source repository without consulting only the active profile's project store.
AGENTS.md reference: AGENTS.md:L84-L87
Useful? React with 👍 / 👎.
47bd776 to
35418dc
Compare
Summary
kanban.worktree_rootpolicy for canonical external worktree placement<owner>-<repo>fromremote.origin.urland persist canonical targets at task creationmaindispatcher return contractTracks cermm/wc-infrastructure#352.
Verification
scripts/run_tests.sh tests/hermes_cli/test_kanban_db.py tests/hermes_cli/test_kanban_project_link.py tests/hermes_cli/test_config.py tests/hermes_cli/test_set_config_value.py -qpython3 -m py_compile ...Review
Publication tip requires immutable current-main review before push/PR. Source live-base candidate
b47826f3fc3754259899124ee910828724ca0ba1previously received exact-tip PASS review. This PR tip includes the current-main compatibility commit and is reviewed separately.Safety
This PR does not activate the live profile by itself. Live activation and rollback are tracked separately under the explicit approval in Discord message
1533028081357557790.