Repository task executor isolation #61
Reference in New Issue
Block a user
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
queue: KANDEV-W-088
Owner goal: Operations requested repository implementation/review tasks to start with the Worktree executor, preventing concurrent agents from changing branches or losing uncommitted work in the shared checkout.
Observable result: the actual cause of Local executor selection is corrected at its source; one newly started repository task materializes as executor_type=worktree with a task-specific workspace_path in task_environments (read-only DB evidence), and the operations session receives the task ID, environment type/path and correction evidence.
This task owns: trace the executor selection from task creation, controller inheritance/explicit arguments, workflow entry and environment preparation; make the smallest correction in the owning instruction/configuration or Kandev code; demonstrate one real Worktree launch. Use the existing task created for this work as the real launch if sufficient. No synthetic extra task solely to manufacture evidence.
Operations evidence (not independently reread by controller): all 16 Kandev task environments on 2026-10-10 used executor_type=local and D:\260720_Ai_Workspace_Tools\kandev; 0 worktree. 2026-10-06 had 12/12 worktree. The affected set includes W-028/W-047/W-017/W-013/W-082/W-084/W-083/W-085/W-086/W-087. Local executor profile d7293e39-d906-417b-b756-6237678e1737 is intended for controller sessions. Workspace default is reportedly empty.
Confirmed controller-side source: the standing controller Plan had explicitly prescribed executor d7293e39 for new R3 repository children. The controller is replacing that instruction with explicit Worktree 08eb0bba-37dc-459c-b34c-14322417bde7. Do not assume omitted-argument inheritance is the sole cause; inspect original create requests/selection evidence and distinguish explicit Local selection from fallback/inheritance.
Design basis: D:\260720_Ai_Workspace\projects\260926_Kandev\repo_Prj_Knowledge\p200_index\설계카드.md:32 invariant 5 (concurrent agents use isolated git worktrees); card :20 Orchestrator; 설계색인.md:39-40 Executors And Runtime. Read related repo AGENTS.md and current executor/environment requirements before changes.
Execution: this task explicitly selects Worktree, repository 068d4436-d120-42af-b178-8e1a45eb2279, fork main and new_workspace. Work in Kandev's assigned task worktree. If its environment is unexpectedly Local/shared, perform no shared writes and report the contradiction. Do not create a second worktree when the assigned worktree exists.
Important boundaries: controller sessions and genuinely non-repository Local tasks remain Local. Do not globally reinterpret deliberately selected Local execution without identifying the relevant contract. Fix the source actually responsible for repository tasks. If the source is Core_Manager prompt authoring outside this repo, identify the exact owning source and correction text and hand it to the owning operations/controller path; do not edit AIWS files directly.
The current operations request authorizes a source correction; follow the existing planning/implementation workflow and keep the plan reviewable. No unrelated feature, new permanent integration/e2e tests, CI changes or verification framework. Changed-logic unit tests alongside source are allowed; use narrow validation. No new flag.
No production setting/DB mutation, runtime restart, profile setting change, credential/cost change or upstream kdlbs publication. Fork PRs explicitly use --repo dreampiler/kandev. Shared checkout writes, reset/stash/clean/deletion are prohibited here. Read-only task_environments observation is allowed; do not print secrets.
Current active W-085/W-086/W-087/W-028b are separately receiving isolation instructions. Do not absorb their implementations, commit their shared modifications or conflict with their file ownership.
Completion report: verified selection source and correction, PR/merge if code changed (or owning instruction change receipt), exact new-task Worktree DB readback, outstanding deployment needs. Report to parent controller; parent forwards [→운영 세션]. Register any deployment-dependent outcome in R3 verification 230 without starting verification before the recorded build cut.
Completed: task 42095510-b94f-4310-b2cc-8820efdc1156 reached the normal review and cleanup workflow and is COMPLETED. Executor precedence is explicit profile, then parent/source inheritance, then Worktree fallback; no repository code defect was found. The standing controller Plan 02748e74-16bd-4383-9917-e7624d507135 was corrected at version e73a72de-c5ca-42e3-a5c0-e7e365d76fbe (2026-10-10T10:02:20Z) to explicitly select Worktree profile 08eb0bba-37dc-459c-b34c-14322417bde7 for repository implementation/review children. R3 preserves the same explicit rule. Existing operations read-only evidence and child Plan sections 5, 11, 13 and 14 confirm this actual task materialized with executor_type=worktree, status=ready, workspace_path=C:\Users\dream.kandev\tasks\kandev-w-088-reposit_cceo0i8i\kandev and a clean task branch. No code change, empty commit, synthetic PR, extra sample or deployment verification item. CM instruction-source promotion remains a separately assigned operations/AIWS follow-up and is not claimed complete. Queue closure belongs to operations; this report records progress only.
[W-088 판정 2026-10-13, 작업 8b5c4925] 관제 경로 해소, 잔여 있음, 닫지 않음. 해소 근거: 운영 DB task_environments(관제 workspace) 10-11 worktree 26/local 0, 10-12 worktree 19, 10-13 worktree 5; 10-12 local 4건은 저장소 없는 상류 감시 작업. 잔여: 저장소 자식이 저장소 없는 Local 부모의 실행기를 상속하는 구멍(apps/backend/internal/mcp/handlers/handlers.go:1747-1767, 상속 :1753, worktree fallback 은 상속 없음일 때만 :1730-1732). 사례 168ca7dc(상류 관제 93c6b4d0 자식, #4412): 22:04:24Z 첫 create_task 가 짧은 agent_profile_id 로 VALIDATION_ERROR, 22:05:04Z 재시도에서 executor 인자 누락 -> 부모 Local d7293e39 상속 -> 공용 체크아웃 D:\260720_Ai_Workspace_Tools\kandev 에서 실행. 관제 결정: 지금은 B(상류 관제에 executor_profile_id 명시 지시 보강), A(제품 상속 규칙 수정, 크기 S)는 후보로 보류.