[Windows][WSL] Mapped drive to \\wsl.localhost is incorrectly translated to /mnt/<drive>, making valid WSL workspaces inaccessible

Open 💬 0 comments Opened Aug 4, 2026 by Diozavr

What version of the Codex App are you using (From “About Codex” dialog)?

Version 26.727.51351

What subscription do you have?

Plus

What platform is your computer?

Microsoft Windows NT 10.0.22621.0 x64

What issue are you seeing?

Codex Desktop incorrectly normalizes a Windows mapped drive that points to a WSL UNC share.

Setup:

  • Windows mapped drive:

U: -> \\wsl.localhost\Ubuntu-22.04

  • Real WSL workspace:

/home/<wsl-user>/<repo>

  • Same folder through mapped drive:

U:\home\<wsl-user>\<repo>

  • Same folder through UNC:

\\wsl.localhost\Ubuntu-22.04\home\<wsl-user>\<repo>

When the workspace is selected in Codex Desktop through U:\..., Codex starts a WSL task with workspace roots that include:

/mnt/u/home/<wsl-user>/<repo>

But /mnt/u does not exist inside WSL, so the task cannot access the workspace.

Local evidence from the WSL environment:

pwd=/home/<wsl-user>/<repo>
exists /mnt/u: no
ls: cannot access '/mnt/u': No such file or directory
exists /mnt/u/home/<wsl-user>/<repo>: no
ls: cannot access '/mnt/u/home/<wsl-user>/<repo>': No such file or directory

Windows sees the mapped drive correctly:

Name        : U
Root        : U:\
DisplayRoot : \\wsl.localhost\Ubuntu-22.04

The same project works correctly when opened directly through the UNC path:

\\wsl.localhost\Ubuntu-22.04\home\<wsl-user>\<repo>

The only difference is whether the user selects the folder via the mapped drive letter U: or via the original UNC path.

What steps can reproduce the bug?

  1. On Windows, map a drive letter to a WSL distro root, for example:

``text
U: -> \\wsl.localhost\Ubuntu-22.04
``

  1. Ensure Codex Desktop is configured with Agent environment: Windows Subsystem for Linux
  1. In Codex Desktop, add/open a project by browsing through the mapped drive:

``text
U:\home\<wsl-user>\<repo>
``

  1. Start a new task.
  1. Observe that Codex attempts to use a WSL path like:

``text
/mnt/u/home/<wsl-user>/<repo>
``

  1. Inside WSL, /mnt/u does not exist, so the workspace is inaccessible. Codex usually finds out and tries to find correct folder.
  1. Restart Codex App.
  1. Project appears in grey with disabled "New chat" icon.
  1. Remove/re-add or add secondary folder the same project using the UNC path:

``text
\\wsl.localhost\Ubuntu-22.04\home\<wsl-user>\<repo>
``

  1. The project works correctly.

What is the expected behavior?

When a Windows drive letter is mapped to a WSL UNC share, Codex should not treat it as a normal Windows drive that can be translated to /mnt/<drive>.

Additional information

This looks related to existing Windows/WSL path normalization issues, but it is a distinct case:

View original on GitHub ↗