You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Windows: codex app-server --managed-daemon 0.157.0 opens a visible console window for each stdio MCP server started via npx / .cmd #48023
Summary
After Codex app-server 0.157.0-x86_64-pc-windows-msvc was installed (through Orca), starting the daemon opens one visible console window per stdio MCP server whose command is npx (a .cmd shim). The same config.toml ran for a week on the previous version without any windows.
Environment
Windows 11 Home 10.0.26200
Codex app-server 0.157.0-x86_64-pc-windows-msvc, launched by Orca as codex.exe app-server --listen unix:// --managed-daemon
Default terminal application: Windows Terminal 1.24.11911.0
Node.js with npx at C:\Program Files\nodejs\npx.cmd
Timeline (local time, 2026-09-25)
08:52:29 — the 0.157.0 release directory was created (auto-update)
08:54:18 — the daemon started 8 stdio MCP servers, and 11 OpenConsole.exe -Embedding processes (Windows Terminal windows) appeared in the same second
The same MCP servers had been configured and in use since 2026-09-18 with no visible windows
Config that reproduces it
TOML
Copy
[mcp_servers.hostinger-vps]
command = "npx"
args = ["--package=hostinger-api-mcp@latest", "hostinger-vps-mcp"]
(I had 8 servers like this.)
Observed process chain (one of the 8)
Copy
codex.exe app-server --managed-daemon
└─ cmd.exe /e:ON /v:OFF /d /c ""C:\Program Files\nodejs\npx.cmd" "--package=hostinger-api-mcp@latest" hostinger-vps-mcp"
├─ conhost.exe 0x4
└─ node.exe npx-cli.js ...
└─ cmd.exe /d /s /c hostinger-vps-mcp
└─ node.exe ...\hostinger-api-mcp\src\servers\vps.js
Every window was titled C:\WINDOWS\system32\cmd.exe, and each was hosted by WindowsTerminal.exe -Embedding.
Not affected
MCP servers whose command is an .exe launched directly (for example node.exe script.js, node_repl.exe) did not open windows. A plugin script that ran through cmd.exe (codex-security) opened one as well.
Expected
Stdio MCP servers start hidden, as they did on the previous version. The daemon has no console of its own, so I think it needs to create child processes with CREATE_NO_WINDOW (or an equivalent hidden startup). Otherwise every console-subsystem child, such as the cmd.exe that runs .cmd shims, gets its own new console. With Windows Terminal as the default terminal, each new console opens as a visible window.
Workaround
Remove the npx-based servers from config.toml, or point command at node.exe with the package’s JS entry point.
Configuration contains multiple stdio MCP servers launched through Python, npx.cmd, and cmd.exe.
The same configuration worked for weeks before the 0.157.0 update.
After resuming a session, many visible console windows appear in a loop. They contain commands such as: C:\Users\User\src\TQMEnterprise\mcp-servers\.venv\Scripts\python.exe -u ...
Windows reports error 2147942632 / 0x800700E8 while launching the Python MCP process.
Process inspection showed approximately 141 MCP child processes under one Codex app-server process, followed by repeated MCP startup failed ... connection closed: initialize response messages.
Downgrading the CLI to 0.153.4 eliminates the visible-console-window storm with the same MCP setup.
ACLs were checked under the normal user account; the Python executable and MCP directories have Read & Execute permissions, with no Access Denied / error 5.
Removing one MCP entry did not resolve the behavior, so this is not specific to a single MCP server.
Expected: stdio MCP child processes start hidden, without allocating visible Windows Terminal consoles, and failed starts do not enter a rapid restart loop.
Sending a message in a Git repository opens several short-lived Windows Terminal windows. Their tab titles show git.exe. A process trace captured four new OpenConsole.exe instances at a turn start. The Codex app-server daemon launched Git metadata and status commands including rev-parse HEAD, remote -v, and status --porcelain.
Steps to reproduce
Open Codex App in a Git repository on Windows with Windows Terminal set as the default terminal application.
Send a message to start a turn.
Watch for transient Git terminal windows during turn startup.
Expected behavior
Background Git checks should run without creating or focusing terminal windows.
Root cause and proposed fix
codex-rs/git-utils/src/git_process.rs starts these commands through JobObject::spawn_contained. On Windows, the job-object spawn sets CREATE_SUSPENDED but does not set CREATE_NO_WINDOW. Its fallback clears creation flags to zero, so that path can also open a console.
Proposed fix: JRBusiness/codex@67858bd. It combines CREATE_NO_WINDOW with the suspended job-object spawn and retains the no-window flag in the fallback. This is a fork commit because the repository's contribution policy does not accept external pull requests.
Verification
A local Windows launcher using CREATE_NO_WINDOW ran the same turn-start Git checks with zero new OpenConsole.exe or Windows Terminal processes in the watcher. The upstream patch itself has not been deployed in the Codex App.
just fmt passed on the proposed patch.
just test -p codex-git-utils -p codex-utils-pty passed: 63 tests on Windows.
Additional Windows reproduction: ongoing visible shell launches
This is an active usability problem, not just a brief flash at startup. The user had more than 20 visible command-line windows open and reports that roughly two more visible shells continue to launch every minute during normal use.
Managed Codex app-server 0.157.0 was installed locally on 2026-09-25 at about 17:05 MDT; the daemon started at 17:05:46.
The active session was in an unrelated repository. A globally enabled plugin contributes several stdio MCP servers, and their background processes started as Codex sessions came up even though none of those tools was requested.
Process inspection showed repeated session-start clusters at 19:48, 20:18, and 21:10 local time. One plugin MCP launch chain was: Codex app-server -> uv -> Python MCP bridge -> cmd.exe /c npx.CMD -> Node -> cmd.exe /d /s /c -> Node server. A snapshot contained 10 live cmd.exe processes from these chains.
The same snapshot had 25 OpenConsole.exe and about 50 conhost.exe processes across the machine. These process counts do not prove that every host was a visible window. There was also a separate cluster of 17 reusable MSBuild workers with console hosts, so I am not attributing all windows to MCP startup.
The user's report of continued new windows every minute has not yet been tied to one exact child process or restart path. It should be investigated as an ongoing launch/visibility problem, not dismissed as one-time MCP initialization.
Expected: Codex background commands and stdio MCP startup run without opening desktop terminal windows. An enabled plugin should not flood unrelated sessions with visible consoles. The behavior began on the day 0.157.0 was installed; the exact faulty launch path in the installed binary is not yet proven.
Additional reproduction from another Windows user after updating Codex earlier today: the visible console windows are effectively non-stop during normal VS Code/Codex work, flashing up and disappearing repeatedly rather than only at startup. Screenshots show ordinary project validation/database commands being surfaced as visible PowerShell/console windows, including:
npm exec tsc --noEmit
npm exec payload generate:types
npm exec payload migrate:status
npm exec payload migrate
The user reports this behavior was not present before today's Codex update and only noticed it after returning to Codex after working in Claude. The windows appear briefly, disappear, and new ones continue appearing. This seems consistent with the ongoing shell-launch behavior already reported here, but importantly it is not limited to MCP startup or Git metadata commands: normal npm/Payload/TypeScript tool execution is visibly spawning consoles too.
Expected: all of these non-interactive background commands should execute without opening/focusing desktop console windows.
Confirming this on Windows too. After updating to 0.157.0, Codex started opening a CMD window for almost every tool/function call. Rolling back to 0.156.1 fixed it immediately, and Codex is back to normal without --no-daemon.
Activity
github-actions commentedon Sep 25, 2026
Potential duplicates detected. Please review them and close your issue if it is a duplicate.
Powered by Codex Action
Roman-Evseev commentedon Sep 25, 2026
Additional reproduction on Windows 11:
codex resume --allC:\Users\User\src\TQMEnterprise\mcp-servers\.venv\Scripts\python.exe -u ...MCP startup failed ... connection closed: initialize responsemessages.Expected: stdio MCP child processes start hidden, without allocating visible Windows Terminal consoles, and failed starts do not enter a rapid restart loop.
JRBusiness commentedon Sep 25, 2026
Codex version
Codex App 26.915.4065.0; managed app-server daemon 0.157.0.
Platform
Windows 11 Pro, build 26200.
What happens
Sending a message in a Git repository opens several short-lived Windows Terminal windows. Their tab titles show
git.exe. A process trace captured four newOpenConsole.exeinstances at a turn start. The Codex app-server daemon launched Git metadata and status commands includingrev-parse HEAD,remote -v, andstatus --porcelain.Steps to reproduce
Expected behavior
Background Git checks should run without creating or focusing terminal windows.
Root cause and proposed fix
codex-rs/git-utils/src/git_process.rsstarts these commands throughJobObject::spawn_contained. On Windows, the job-object spawn setsCREATE_SUSPENDEDbut does not setCREATE_NO_WINDOW. Its fallback clears creation flags to zero, so that path can also open a console.Proposed fix: JRBusiness/codex@67858bd. It combines
CREATE_NO_WINDOWwith the suspended job-object spawn and retains the no-window flag in the fallback. This is a fork commit because the repository's contribution policy does not accept external pull requests.Verification
CREATE_NO_WINDOWran the same turn-start Git checks with zero newOpenConsole.exeor Windows Terminal processes in the watcher. The upstream patch itself has not been deployed in the Codex App.just fmtpassed on the proposed patch.just test -p codex-git-utils -p codex-utils-ptypassed: 63 tests on Windows.jmkinzer commentedon Sep 26, 2026
Additional Windows reproduction: ongoing visible shell launches
This is an active usability problem, not just a brief flash at startup. The user had more than 20 visible command-line windows open and reports that roughly two more visible shells continue to launch every minute during normal use.
uv-> Python MCP bridge ->cmd.exe /c npx.CMD-> Node ->cmd.exe /d /s /c-> Node server. A snapshot contained 10 livecmd.exeprocesses from these chains.OpenConsole.exeand about 50conhost.exeprocesses across the machine. These process counts do not prove that every host was a visible window. There was also a separate cluster of 17 reusable MSBuild workers with console hosts, so I am not attributing all windows to MCP startup.Expected: Codex background commands and stdio MCP startup run without opening desktop terminal windows. An enabled plugin should not flood unrelated sessions with visible consoles. The behavior began on the day 0.157.0 was installed; the exact faulty launch path in the installed binary is not yet proven.
sporeshield commentedon Sep 26, 2026
Additional reproduction from another Windows user after updating Codex earlier today: the visible console windows are effectively non-stop during normal VS Code/Codex work, flashing up and disappearing repeatedly rather than only at startup. Screenshots show ordinary project validation/database commands being surfaced as visible PowerShell/console windows, including:
npm exec tsc --noEmitnpm exec payload generate:typesnpm exec payload migrate:statusnpm exec payload migrateThe user reports this behavior was not present before today's Codex update and only noticed it after returning to Codex after working in Claude. The windows appear briefly, disappear, and new ones continue appearing. This seems consistent with the ongoing shell-launch behavior already reported here, but importantly it is not limited to MCP startup or Git metadata commands: normal npm/Payload/TypeScript tool execution is visibly spawning consoles too.
Expected: all of these non-interactive background commands should execute without opening/focusing desktop console windows.
ev4ndr0p commentedon Sep 28, 2026
Confirming this on Windows too. After updating to 0.157.0, Codex started opening a CMD window for almost every tool/function call. Rolling back to 0.156.1 fixed it immediately, and Codex is back to normal without --no-daemon.