Windows Desktop + WSL workspace: node_repl rejects /mnt/c sandboxCwd before Chrome/browser bootstrap
What version of the Codex App are you using (From “About Codex” dialog)?
Version 26.616.51431 Build 2026.6.21 ( Observed related plugin/runtime versions: - openai-bundled Chrome plugin: 26.616.51431 - Chrome extension: 1.1.5_0)
What subscription do you have?
Plus
What platform is your computer?
Microsoft Windows NT 10.0.26200.0 x64
What issue are you seeing?
Codex Desktop on Windows fails to start node_repl for a WSL workspace before any JavaScript code executes.
The workspace is opened from WSL as:
/mnt/c/Users/<user>/Documents/Codex/2026-06-22/chrome-codex
The same path maps cleanly to Windows:
C:\\Users\\<user>\\Documents\\Codex\\2026-06-22\\chrome-codex
However, calling mcp__node_repl__js fails before the provided JS code runs:
tool call failed for `node_repl/js`
Caused by:
Mcp error: -32602: js: codex/sandbox-state-meta:
sandboxCwd is not a local file URI:
file:///mnt/c/Users/<user>/Documents/Codex/2026-06-22/chrome-codex
This blocks Chrome/browser plugin bootstrap in WSL workspaces because the Chrome skill depends on node_repl.
The Chrome native host static configuration appears valid after repair:
- Chrome is running.
- Codex Chrome Extension is installed and enabled in the selected Chrome profile.
- Native messaging manifest exists.
- HKCU registry default value points to the manifest.
extension-host.exeexists.extension-host-config.jsonexists.browserClientPath,nodePath,nodeReplPath, andcodexCliPathall point to existing files.
Despite that, the browser/Chrome bootstrap cannot start because node_repl rejects the WSL-style sandboxCwd before browser code is reached.
This looks like a WSL path-to-Windows-file-URI conversion issue. The Windows-side node_repl appears to receive:
file:///mnt/c/Users/<user>/Documents/Codex/2026-06-22/chrome-codex
but likely expects a Windows-local URI such as:
file:///C:/Users/<user>/Documents/Codex/2026-06-22/chrome-codex
What steps can reproduce the bug?
- Use Codex Desktop on Windows.
- Open a WSL workspace whose path is under
/mnt/c, for example:
/mnt/c/Users/<user>/Documents/Codex/2026-06-22/chrome-codex
- Confirm the WSL path maps cleanly to a Windows path:
wslpath -w /mnt/c/Users/<user>/Documents/Codex/2026-06-22/chrome-codex
Expected output:
C:\\Users\\<user>\\Documents\\Codex\\2026-06-22\\chrome-codex
- Confirm WSL interop works:
cmd.exe /c ver
This succeeds and prints the Windows version.
- In Codex, invoke the Chrome/browser skill, or run a minimal
node_replcall such as:
nodeRepl.write("hello");
- The call fails before the JavaScript code executes:
tool call failed for node_repl/js
Caused by:
Mcp error: -32602: js: codex/sandbox-state-meta:
sandboxCwd is not a local file URI:
file:///mnt/c/Users/<user>/Documents/Codex/2026-06-22/chrome-codex
- Verify that the Chrome native host configuration is not the failing layer:
- Chrome is running.
- Codex Chrome Extension is installed and enabled.
- Native messaging manifest exists.
- HKCU native messaging registry entry points to the manifest.
extension-host.exeexists.extension-host-config.jsonexists.browserClientPath,nodePath,nodeReplPath, andcodexCliPathall point to existing files.
- Retry the browser/Chrome bootstrap.
Actual result: it still fails at node_repl startup with the same sandboxCwd error, before browser code runs.
Session id / token usage / context usage:
Not available from the UI at the time of filing.
Possibly related issues found before filing:
- #19365
- #21147
- #25280
- #25090
What is the expected behavior?
When a Codex Desktop thread uses a WSL workspace, node_repl should either receive a Windows-local file URI for /mnt/c/... paths, for example:
file:///C:/Users/<user>/Documents/Codex/2026-06-22/chrome-codex
instead of:
file:///mnt/c/Users/<user>/Documents/Codex/2026-06-22/chrome-codex
or run in the WSL/Linux context and accept Linux-local workspace paths.
The Chrome/browser plugin should be able to bootstrap from WSL workspaces when the native host configuration is valid.
Additional information
WSL uname -mprs:
Linux 6.6.114.1-microsoft-standard-WSL2 x86_64 x86_64
I initially investigated this as a Chrome extension/native host problem.
There were native host setup issues on this machine, but after manually repairing them the static checks pass:
- Manifest path:
C:\\Users\\<user>\\AppData\\Local\\OpenAI\\extension\\com.openai.codexextension.json
- Registry key:
HKCU\\Software\\Google\\Chrome\\NativeMessagingHosts\\com.openai.codexextension
- Registry default value:
C:\\Users\\<user>\\AppData\\Local\\OpenAI\\extension\\com.openai.codexextension.json
- Host path:
C:\\Users\\<user>\\.codex\\plugins\\cache\\openai-bundled\\chrome\\latest\\extension-host\\windows\\x64\\extension-host.exe
extension-host-config.jsonexists and points to existing files.
After this repair, the failure remains exactly at node_repl startup with the sandboxCwd is not a local file URI error. This suggests the remaining problem is independent of Chrome native messaging and is instead caused by WSL workspace path metadata being passed to a Windows-side runtime without conversion.
Also note: the bundled Chrome plugin package on this installation only contains the Windows host binary:
extension-host/windows/x64/extension-host.exe
No Linux/WSL native host binary was present, so installing Chrome inside WSL does not appear to be a practical workaround for this plugin.
12 Comments
Potential duplicates detected. Please review them and close your issue if it is a duplicate.
Powered by Codex Action
I put up a branch for the WSL-to-Windows
sandboxCwdpath mismatch described here:https://github.com/openai/codex/compare/main...Nicolas0315:codex/wsl-windows-mcp-sandbox-cwd?expand=1
Commit:
187047147bcf16a2f6a8fe302b8e7263482f9f90What it changes:
.exelaunched through interop, rewrites only thecodex/sandbox-state-meta.sandboxCwdvalue for that MCP call./mnt/c/...to a Windows drive file URI such asfile:///C:/..../home/...tofile://wsl.localhost/<distro>/home/....Verification:
just fmt,git diff --check, focusedcodex-coretests, existingmcp_sandbox_cwdtests,codex-mcpmetadata test, andcargo check -p codex-core -p codex-mcpall passed.cyberagent-mac-m5max: fetched the commit over SSH,git diff --check, focused tests, andcargo check -p codex-core -p codex-mcppassed.nicolas2025: fetched over SSH,git diff --check, focused tests, andcargo check -p codex-core -p codex-mcppassed; no lingering cargo/rustc/link processes.nicolas-macbook-pro: fetched over SSH andgit diff --checkpassed; cargo is not installed there.rtx5060ti: fetched over SSH andgit diff --checkpassed; Rust build is blocked by the machine's knownlink.exesetup issue (link: extra operand ...), with no lingering cargo/rustc/link processes.git merge-tree --write-tree origin/main HEADis clean against currentorigin/main(69596f0e4).I can still reproduce this on 2026-07-02 after restarting Codex Desktop.
Environment:
/mnt/c/Users/<user>/Documents/Codex/<workspace>26.623.81905A minimal
node_repl/jsinvocation fails before any JavaScript executes:The same failure blocks both:
sky.list_apps()can runbrowser-clientsetup can runBoth plugin client files are installed. This appears to remain a WSL-to-Windows
sandboxCwdURI translation issue rather than a Chrome, OpenAI login, or website issue.I can still reproduce this on 2026-07-03 after several Codex Desktop updates and a full Browser plugin reinstall/re-enable cycle.
Environment:
codex-cli 0.142.3BROWSER_USE_CODEX_APP_VERSION="26.623.81905"BROWSER_USE_AVAILABLE_BACKENDS="chrome"node_repl: enabled/home/<user>/projects/<repo>\\wsl.localhost\Ubuntu\home\<user>\projects\<repo>CODEX_HOMEpoints to the Windows Codex home:/mnt/c/Users/<user>/.codexMinimal smoke test:
Observed result in the WSL filesystem workspace:
I also tested a Windows-filesystem workspace while the Codex App agent environment was still set to WSL:
That fails before JavaScript execution as well:
Control case:
With the Codex App agent environment switched to Windows native, a Windows-filesystem test project succeeds:
Results in that control case:
nodeRepl.write('ok'): succeedshttp://127.0.0.1:8768/index.html: succeedsResult matrix:
| Agent environment | Workspace | Result |
| --- | --- | --- |
| Windows native |
C:\tmp\codex-browser-repro| Success || WSL |
/home/<user>/projects/<repo>| Fails before JS execution || WSL |
/mnt/c/Users/<user>/Documents/BrowserUseTest| Fails before JS execution |This makes the failure look broader than just a WSL-filesystem path issue. As long as the agent environment is WSL,
sandboxCwdis generated as a Linux file URI (file:///home/...orfile:///mnt/c/...) and the Windows-sidenode_repl.exerejects it before Browser Use, Chrome setup, or any JavaScript can initialize.The current best diagnosis is still a WSL-agent-to-Windows-
node_replsandbox metadata path/URI namespace mismatch.Adding another data point from Windows + WSL mode, with one extra bit of instrumentation that may help locate the failing layer.
Environment / setup:
codex-cli 0.142.4./home/<user>/projects/economics.Minimal live tool call still fails:
Observed result:
Additional proxy/bypass evidence:
I configured
[mcp_servers.node_repl]to point at a small WSL Python proxy instead of directly at the Windowsnode_repl.exe.codex mcp get node_replreports the expected proxy command:That proxy logs incoming
tools/callmetadata and rewrites WSLsandboxCwdfile URIs before forwarding to the Windows runtime. Manual/synthetic proxy tests show it does rewrite the path, for example:However, after a full Codex Desktop restart and a fresh thread, the actual
mcp__node_repl.jstool call above still fails with the originalfile:///home/...value, and the proxy trace receives no new entry from that live call.At the same time, the process tree shows both:
So the visible config says
node_replis proxied, and the proxy works in isolation, but the live exposedmcp__node_repl.jstool appears to be bound to a Desktop/app-server-owned directnode_repl.exeroute instead of the configured[mcp_servers.node_repl]command.That seems consistent with this being a Desktop Windows+WSL app-server/runtime bridge issue rather than a Chrome plugin install issue. It may also explain why config-level MCP workarounds do not fully resolve the problem: the Desktop-managed Node REPL bridge can still bypass the configured MCP server entry.
Follow-up: Computer Use is affected by the same bridge failure in this WSL session.
The Computer Use plugin files are installed, including:
But the prescribed lightweight Computer Use bootstrap/list-apps call fails before Computer Use can initialize:
Observed result:
So the issue is not Chrome-specific on this machine. In WSL agent mode, both Chrome and Computer Use are blocked at the shared
node_repl/jsbridge layer before either plugin's own client code can run.Another occurrence of this same bug (Feedback ID: 019f68a0-acfa-7be3-af89-9082ba15d05c):
Chrome fails to connect from a WSL2 workspace before reaching the extension.
node_repl/jsrejects thecodex/sandbox-state-metabefore any JS runs:Mcp error: -32602: js: codex/sandbox-state-meta:
sandboxCwd is not a local file URI:
file:///mnt/c/Users/<user>/Documents/Codex/<date>/chrome-integration-validation
Expected behavior: the desktop integration should translate the WSL path into a Windows-local URI (e.g. file:///C:/Users/<user>/Documents/Codex/<date>/chrome-integration-validation) or run the Chrome bridge inside the WSL context, consistent with what's already reported in this issue.
Still reproducible on 2026-07-21 with a newer Codex Windows/Computer Use build. This reproduction is specifically through the bundled Computer Use plugin, not only Chrome/browser use.
Environment
26.715.7063.026.715.5214310.0.26200.0x64/mnt/c/Users/<user>/Documents/Codex/2026-07-21/<workspace>C:\Users\<user>\Documents\Codex\2026-07-21\<workspace>runCodexInWindowsSubsystemForLinux = truenode_repl.exeC:\Program Files\Zen Browser\zen.exeand already running019f8465-cade-7882-9274-5f709a5d8faaMinimal reproduction
Following the bundled Computer Use skill's prescribed initialization:
The
mcp__node_repl__jscall fails before any supplied JavaScript executes:Because validation fails before execution, Computer Use cannot initialize, read its runtime documentation, call
sky.list_apps(), request app approval, capture a window, or interact with Zen. Zen itself is installed and running, and the Computer Use plugin files are present, so this is not a missing-app, missing-plugin, or browser-permission failure.This appears to be the same WSL-agent-to-Windows-
node_repl.exeURI namespace mismatch already identified here. The Windows-side runtime receives:where it likely requires:
This confirms that the issue remains present in the
26.715app/plugin release and affects the bundled Computer Use plugin before its own client code can run.Additional reproduction: still present in 26.721 and affects both Chrome and the in-app browser
Observed on 2026-07-25 with a newer Codex Desktop build than the previously reported 26.715 reproduction.
Environment
26.721.4979.026.721.4105910.0.26200.8894x646.18.33.1-microsoft-standard-WSL2/home/<user>/UNAV/Mastercmd.exe /c versucceedswslpath -w /home/<user>/UNAV/Masterresolves to\\wsl.localhost\Ubuntu-24.04\home\<user>\UNAV\Masternode_replcommand is the bundled Windowsnode_repl.exe; its Node runtime and trusted paths are also Windows paths.Minimal reproduction
A minimal Node REPL call fails before the supplied JavaScript executes:
Result:
The same pre-execution validation failure occurs when attempting to initialize:
@Chromerequest.In every case, the failure happens at the shared
node_repl/jsboundary beforebrowser-client.mjsorcomputer-use-client.mjscan execute. This means the browser backend, current page, Chrome profile, website allowlist, and Chrome native messaging layer are never reached.As a control check, launching the installed Windows Chrome executable directly from WSL with Windows interop succeeds and opens the requested URL. What remains unavailable is browser automation and inspection through the Codex bridge.
This further supports the diagnosis that the Desktop-managed Windows
node_repl.exeis receiving a Linux-localsandboxCwdURI without namespace conversion. For a native WSL path, it likely needs a UNC-style Windows URI such as:Alternatively, the Node REPL runtime needs to execute in WSL and accept
file:///home/...as local.The issue therefore remains reproducible in the
26.721release and is not limited to/mnt/c/...workspaces or to the Chrome extension specifically.Still reproducible on 2026-07-30 in a newer Windows Codex Desktop build, using a native WSL filesystem workspace.
Environment:
26.721.81911codex-cli 0.146.0-alpha.3.1codex-cli 0.146.0/home/<user>/dev/<worktree>node_repl.exeThe built-in Browser call fails before navigation or browser client initialization:
Launching the installed Windows Chrome executable directly from WSL with headless screenshot flags succeeds against the same local application in about 7.6 seconds. This confirms the local app, host alias, WSL interop, and Chrome itself are healthy; the failure remains at the Desktop-managed WSL-to-Windows Node REPL metadata boundary.
This build therefore still needs either a translated UNC-style URI for native WSL paths or a Node REPL runtime that accepts Linux-local file URIs.
This issue is still reproducible on 2026-08-05 in my WSL environment.
Codex reports the following error:
The workspace is located on the Windows filesystem and accessed through
/mnt/cfrom WSL. Codex remains configured to run under WSL.I can reproduce the same practical limitation with Codex Desktop on Windows while using WSL as the agent environment.
In my case, the Integrations UI reports that the in-app browser plugin is unavailable. Updating the Codex App did not change this. I intentionally removed the Chrome integration because it is not usable from my WSL workflow, and reinstalling the whole App is not an acceptable workaround because I need to preserve existing local conversations.
The relevant runtime configuration exposes no usable browser backend in the WSL agent environment (
BROWSER_USE_AVAILABLE_BACKENDSis empty). This makes the report's conclusion especially useful: Chrome/native-host repair is not a workaround for WSL, since the bootstrap path fails before browser code runs and the bundled Chrome host is Windows-only.A supported WSL browser backend, or correct WSL-path handling by the Windows-side runtime, would be needed. Thanks for the detailed diagnosis.