Bug description
On Windows, running /codex:review or any command that triggers SpawnedCodexAppServerClient fails with:
Root cause
codex is installed via npm as a .cmd shim on Windows. In plugins/codex/scripts/lib/app-server.mjs line 188, spawn("codex", ["app-server"], ...) is called without shell: true. Node's child_process.spawn() cannot resolve .cmd files without the shell option, resulting in ENOENT.
This is the same class of bug that was fixed in #13 for spawnSync in process.mjs, but the async spawn() call in app-server.mjs was missed.
Steps to reproduce
- Install the Codex plugin on Windows via Claude Code marketplace
- Install Codex CLI:
npm install -g @openai/codex
- Authenticate:
codex login
- Run
/codex:review in Claude Code
Expected: Review runs successfully
Actual: spawn codex ENOENT
Environment
- OS: Windows 11
- Node.js: v22.17.0
- codex-cli: 0.117.0
- codex-plugin-cc: v1.0.1
Fix
Add shell: process.platform === "win32" to the spawn() options in app-server.mjs, consistent with the approach in #13.
Bug description
On Windows, running
/codex:reviewor any command that triggersSpawnedCodexAppServerClientfails with:Root cause
codexis installed via npm as a.cmdshim on Windows. Inplugins/codex/scripts/lib/app-server.mjsline 188,spawn("codex", ["app-server"], ...)is called withoutshell: true. Node'schild_process.spawn()cannot resolve.cmdfiles without theshelloption, resulting inENOENT.This is the same class of bug that was fixed in #13 for
spawnSyncinprocess.mjs, but the asyncspawn()call inapp-server.mjswas missed.Steps to reproduce
npm install -g @openai/codexcodex login/codex:reviewin Claude CodeExpected: Review runs successfully
Actual:
spawn codex ENOENTEnvironment
Fix
Add
shell: process.platform === "win32"to thespawn()options inapp-server.mjs, consistent with the approach in #13.