Windows app: MCP settings UI shows Node_repl args that are not written to config.toml after restart
Summary
On Codex Desktop for Windows, the MCP settings UI for Node_repl can show an argument as configured, but the generated MCP config does not match the UI state after restart.
In this case, the UI shows this argument for Node_repl:
--disable-sandbox
But after restarting Codex Desktop, the generated config is reset to:
[mcp_servers.node_repl]
args = []
The UI still displays --disable-sandbox as configured, so the settings UI and the generated config.toml disagree.
This is primarily a Windows app settings persistence / UI sync bug. It is not primarily a report about the underlying Chrome or Computer Use sandbox failure.
Why this matters
For some Windows users, node_repl fails when launched through the default sandbox runner:
node_repl kernel exited unexpectedly
windows sandbox failed: runner error: CreateProcessAsUserW failed: 5
Adding --disable-sandbox to the Node_repl MCP args can work around that failure and allows node_repl-backed workflows such as the Chrome plugin to run.
However, because the settings UI value is not reliably written into the generated MCP config, this workaround cannot be persisted across app restarts.
Environment
- OS: Windows
- Codex Desktop versions observed in local logs/config:
26.608.12217/26.608.1337 - Node runtime path pattern:
C:\Users\<user>\AppData\Local\OpenAI\Codex\runtimes\cua_node\2f053e67fec2d258\bin\node_repl.exe
- Windows sandbox config:
[windows]
sandbox = "elevated"
Steps to reproduce
- Open Codex Desktop on Windows.
- Open MCP settings for
Node_repl. - Add this argument in the settings UI:
--disable-sandbox
- Save/update the MCP config.
- Restart Codex Desktop.
- Observe that the settings UI still shows
--disable-sandboxforNode_repl. - Inspect the generated config:
C:\Users\<user>\.codex\config.toml
- Inspect the launched
node_repl.execommand line.
Expected behavior
The generated config should match the settings UI:
[mcp_servers.node_repl]
args = ["--disable-sandbox"]
The launched process should include the configured argument:
node_repl.exe --disable-sandbox
Actual behavior
The settings UI still shows --disable-sandbox, but the generated config is reset to:
[mcp_servers.node_repl]
args = []
The launched process command line is only:
node_repl.exe
In one observed flow, saving/updating the UI once did not update config.toml; saving/updating again cleared the args in the generated config.
Workaround note
For users hitting the Windows Chrome / node_repl sandbox launch failure, --disable-sandbox appears to be a useful workaround for the Chrome plugin path when it is actually passed to node_repl.exe.
The bug here is that Codex Desktop's Windows MCP settings UI can show the workaround as configured while the generated config and launched MCP process do not receive it.
Additional diagnostic notes
Directly running the bundled Node runtime outside the failing MCP path works:
node.exe --version
v24.14.0
node_repl.exe --help also works and documents the relevant option:
--disable-sandbox Start the Node kernel directly even when CODEX_CLI_PATH is set
This suggests the runtime itself is present and executable; the key issue in this report is the mismatch between MCP settings UI state and generated config.toml / process args.
4 Comments
Potential duplicates detected. Please review them and close your issue if it is a duplicate.
Powered by Codex Action
I don't think this is a duplicate of the MCP/Chrome sandbox issues listed above.
We found that adding
--disable-sandboxto the MCP args can work around the Computer Use and Chrome failures themselves. The bug being reported here is different: in the Codex Windows app, the MCP args/config setting is not persisted correctly.Specifically, after setting the args in the UI, the UI can still show the expected value, but after restarting the app
config.tomlgets reset/overwritten and no longer matches the UI state. That means the workaround cannot be saved reliably across app restarts.So the issue is about the Windows app settings persistence/sync behavior for MCP args, not about whether
--disable-sandboxfixes the underlying Chrome/Computer Use launch problem.<img width="1422" height="498" alt="Image" src="https://github.com/user-attachments/assets/38d71ad6-35d8-4686-8466-499e31ba326c" />
<img width="986" height="162" alt="Image" src="https://github.com/user-attachments/assets/928020e3-228d-474d-b702-883ce57dc608" />
Additional observation from further testing on Windows:
Codex Desktop appears to reprovision the bundled
cua_noderuntime during app startup using a staging / replacement flow. I observed runtime directories being removed and temporary.stage...directories being created near:This also explains why runtime-level workarounds do not persist. For example, replacing the bundled:
with a shim that calls the original binary with
--disable-sandboxis reverted on the next Codex Desktop startup. The backup file created next to it, such as:also disappears because the runtime directory is replaced.
The same reset / non-application behavior is reproducible for custom MCP settings:
argsforNode_replare reset or not passed to the spawned processenventries such asDISABLE_SANDBOX=trueare reset or do not appear under[mcp_servers.node_repl.env]after restartcommandvalues, such as pointingNode_replto a wrapper script, are also reset back to the bundled runtime commandSo the issue seems broader than only
argsnot being persisted inconfig.toml: on Windows startup, Codex Desktop appears to regenerate both the bundled runtime and the generated MCP config from defaults. As a result, user changes tocommand,args, and customenvforNode_replare discarded or not applied to the spawned MCP process, even when the Settings UI still shows them.I’m going to close this issue and replace it with a clearer report.
The original wording here focused too much on
--disable-sandbox/argsbeing reset. After reading the MCP config behavior more carefully, the more precise issue is that bundled/plugin MCP servers are managed/generated definitions, but the Settings UI still presentscommand,args, andenvas if they were effective persistent user overrides.I’ll open a new issue focused on that UI / effective-config mismatch, and link back here so the history remains discoverable.