agent-orchestrator
agent-orchestrator copied to clipboard
feat(daemon): generic Windows .cmd/.bat launch for worker and reviewer harnesses (umbrella)
Problem
We have no generic way to launch a Windows .cmd/.bat shim for agent harnesses. Every npm-installed harness ships as a .cmd shim, not a .exe, so installs that only have the shim fail detection or launch. Each harness PR re-litigates this from scratch; PR #5267 is the latest example: it deliberately excludes .cmd shim launching because the launch mechanics don't exist yet.
What's missing:
- Supervised launch (
pty-host→agent-process supervise) can't spawn a.cmdchild; it needs thecmd.exe /d /s /cwrapping, quoting rules, process ownership, and ConPTY lifecycle done once, generically. - Binary resolution and identity validation treat non-
.execandidates as unlaunchable, so shim-only installs report "not installed" or stay undetected even when identity checking would confirm them.
Related work
- #3409: Codex resolver prefers
codex.cmdovercodex.exe, and supervise can't launch.cmd. Covers the Codex slice plus launch mechanics. - #3504: reviewer terminals invisible on Windows because ConPTY can't spawn
.cmdreviewer binaries. - #5269: closed as completed on Sep 12 by nikhilachale, but no commit or merged PR references it; #5267 is still open. The goose
.cmddetection gap may not actually be fixed. Needs re-verification.
Scope
- Build one shared
.cmd/.batlaunch path (wrapping, quoting, ownership, ConPTY lifecycle) in the supervised chain. - Make binary resolution + identity validation accept shim candidates once the launch path can exec them.
- Fold in the Codex-specific work from #3409.
- Re-open or re-verify #5269; re-add
.cmdcandidates per harness (goose, codex, reviewer binaries) with identity validation enabled.
Non-goals
- Per-harness shell scripting beyond what the shared wrapper provides.
- POSIX changes; macOS/Linux launch already works.
i tested agent and reviewer launches on my windows setup and did not hit a .cmd launch failure. i have not tested a setup where the agent is available only as a .cmd or .bat file, so i cannot confirm that case yet.