[Windows] Desktop renderer crashes when selecting a project with multiple nested roots
Summary
Codex Desktop on Windows enters the full-page Oops, an error has occurred renderer fallback when the selected local project has more than one nested Windows root. The app process remains alive, but the UI is unusable and both Update ChatGPT and Try again have no effect.
This is deterministic when selecting the affected project directly or when opening an older worktree-backed task that reselects that project.
Environment
- Codex Desktop (Microsoft Store):
26.721.3404.0 - Package:
OpenAI.Codex_26.721.3404.0_x64__2p2nqsd0c76g0 - Platform: Windows 10 Home x64,
10.0.19045(build19045)
Steps to reproduce
- Have a local project whose persisted entry in
%USERPROFILE%\.codex\.codex-global-state.jsoncontains two nested Windows roots, for example:
{
"name": "ExampleProject",
"rootPaths": [
"C:\\<workspace>\\ExampleProject",
"C:\\<workspace>"
]
}
- Select that project, restart Codex Desktop with it selected, or open an existing task assigned to that project (including a Codex-managed worktree task).
- The renderer immediately falls into the generic full-page error boundary.
- Click Try again or Update ChatGPT.
- Neither action recovers the app.
Actual behavior
The main process stays alive, but the renderer shows only:
Oops, an error has occurred
Update ChatGPT | Try again
The desktop log records:
error [electron-message-handler] error boundary
errorMessage="process is not defined"
errorName=Error
name=AppRoutes
The component stack begins at the same minified renderer component on each occurrence:
at S3s (app://-/assets/app-initial-_qVLmrD6.js:8875:151178)
Expected behavior
Projects with multiple roots, including a repository root plus its parent workspace, should render normally. If a root configuration is invalid, Codex should reject or normalize it without crashing the entire application shell.
Confirmed A/B reproduction and recovery
The following was reproduced twice with backups taken before changing local state:
- With a two-root project selected, Codex failed on launch with
process is not defined/AppRoutes. - Changing only
selected-projectto an existing one-root project allowed the app to launch. - Opening an older worktree task assigned to the original two-root project reselected that project and immediately reproduced the same error screen.
- With Codex fully closed, both
.codex-global-state.jsonand.codex-global-state.json.bakwere backed up. - Only the affected project's
rootPathswas changed from two entries to its repository root alone. The project remained selected. - Codex was relaunched with that same project selected. The UI rendered normally, the older task was usable, and the fresh launch logs contained no new
process is not defined/AppRouteserror.
Confirmed local recovery shape:
{
"rootPaths": [
"C:\\<workspace>\\ExampleProject"
]
}
This is a recovery workaround, not an application-level fix. Affected users should close Codex and back up both global-state files before attempting it.
Suspected cause (hypothesis from read-only packaged-bundle inspection)
The signed renderer bundle appears to filter workspace roots by calling a path-browserify POSIX relative() operation on normalized values shaped like:
win32:c:/<workspace>/ExampleProject
win32:c:/<workspace>
Those strings are not POSIX-absolute. With two roots, the comparison reaches path-browserify path resolution, which falls back to process.cwd(). The sandboxed renderer has no Node process global, producing process is not defined.
With exactly one root, the pairwise comparison short-circuits on the self-entry, so that relative-path branch is not reached. This explains the observed one-root/two-root A/B result, but the source-level cause should be confirmed by maintainers.
Impact
- Codex Desktop becomes completely unusable on startup.
- The built-in retry/update buttons do not recover it.
- Opening a historical task can re-trigger the failure even after temporarily recovering by switching projects.
- The user must manually repair persisted state while the app is closed.
Screenshot
A screenshot of the full-page error will be attached in the first comment.
Possibly related
#32424 has the same Windows renderer exception signature after managed-worktree creation, but it was closed as resolved in an older build and does not describe this deterministic multi-root project-state trigger.
2 Comments
Potential duplicates detected. Please review them and close your issue if it is a duplicate.
Powered by Codex Action
Independent confirmation of the exact nested-root failure on a newer Windows build.
OpenAI.Codex 26.721.3996.0(x64 MSIX)2026-07-24T16:41:22Zand2026-07-24T16:55:54Z:``
``errorMessage="process is not defined"
errorName=Error
name=AppRoutes
rootPathsto the single intended project folder and restarting restored the UI. The current project state has one root, and the latest startup log contains no recurrence.I uploaded Codex diagnostics through
/feedback. Uploaded thread ID:019f951d-eefb-7a82-af7c-56350f2447e8.This is therefore reproducible on 26.721.3996.0 as well, with the same parent/child root overlap and the same one-root A/B recovery.