Skip to content

Windows: codex_app tools unavailable in dot-created tasks; recover after SystemRoot launcher workaround #50982

Open

Description

@windchasersky

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

Windows Desktop internal version 26.930.41038 (build 13022); MSIX package 26.930.4958.0. Bundled Codex CLI 0.160.0; Node.js v24.21.0. These were verified locally; the hosted controller version was not recorded.

What subscription do you have?

Not recorded.

What platform is your computer?

Windows Desktop. Exact Windows OS build was not recorded.

What issue are you seeing?

A task created by dot and executed on the connected Windows computer could not access codex_app tools to continue an existing user-created local thread. An ordinary user-created local thread on the same machine had working desktop thread interfaces. The delegated task initially exposed 112 tools, with no codex_app entries, including no read_thread or send_message_to_thread.

Both list_mcp_resources({server: 'codex_app'}) and list_mcp_resource_templates({server: 'codex_app'}) initially reported:

MCP startup failed: handshaking with MCP server failed: connection closed: initialize response: connection closed: initialize response

The actual executor plugin copy contained server.mjs, and it matched the installed package. This was not the missing-server-file condition described in #48314.

What steps can reproduce the bug?

Observed sequence on one Windows machine; broader reproducibility has not been established:

  1. Ask dot to start a task on the connected Windows computer and inspect that task's available tool catalog. Compare with an ordinary local user-created thread on the same computer.

  2. In the dot-created task, request resources/templates for codex_app. Observe the startup/initialize error above and the missing thread tools.

  3. After backing up the actual executor launcher, add this single line immediately after setlocal in <APPDATA>\Codex\web\Codex\executor-plugins\codex-app-tools\scripts\launch_codex_app_tools_mcp.cmd:

if not defined SystemRoot for %%I in ("%__APPDIR__%..") do set "SystemRoot=%%~fI"

The guard supplies SystemRoot only when absent, within the launcher's local environment. This is a temporary, reversible workaround, not an official fix; an update may overwrite the executor copy.

  1. In the same existing dot-created task, resources/templates then returned Mcp error: -32601: Method not found, consistent with this tools-only service not implementing resource methods rather than initialization still failing.
  2. On the next turn, the tool catalog contained 168 tools, including 56 codex_app tools. read_thread successfully read the original local thread with hostId: 'local'.
  3. With separate user authorization, the delegated task sent exactly one 'reply only' test through send_message_to_thread. A subsequent read confirmed a new completed turn, error: null, and the requested acknowledgment.

Recovery used the existing task and target thread, without creating a replacement test task or restarting the service.

What is the expected behavior?

Dot-created tasks executed on a connected Windows computer should receive working codex_app thread tools without manually editing the launcher. MCP initialization failures should expose useful diagnostics. Please investigate essential environment propagation, including SystemRoot, in the durable/dot executor launch path, and tool-catalog refresh after initialization recovers.

Additional information

Previously performed isolated checks: the configured launcher/server initialized under the normal environment. A filtered child environment without SystemRoot exited with code 134 and Assertion failed: ncrypto::CSPRNG(nullptr, 0). Adding only SystemRoot made initialization succeed; the guarded launcher also passed that filtered initialization check. These were isolated child-process tests, not a dump of the real worker MCP subprocess environment.

Uncertainty: incomplete environment inheritance is a hypothesis supported by those checks and the recovery, not a confirmed cause at a specific executor/controller layer. Shell variables do not establish MCP subprocess variables. The original MCP process environment and root binding were not directly inspected. This report does not claim all versions are affected.

Ordinary local computer control was reported working by the user. Post-workaround validation covered codex_app thread interfaces only; it does not establish that node_repl or computer-control tools recovered in the delegated task.

Potentially related reports, not confirmed duplicates or the same root cause:

Activity

  1. added
    app
    on Oct 5, 2026
  2. added
    bug
    windows-os
    mcp
    dots
    on Oct 5, 2026
  3. touchable-tom commented on Nov 14, 2026

    @touchable-tom

    Tested on a clean Microsoft Store install on Windows 11 (10.0.26300.9974) with OpenAI.Codex MSIX 26.1111.2228.0 (and OpenAI.CodexPrimaryRuntime 26.1112.737.0, bundled codex-app-tools plugin 26.1111.21308). The SystemRoot launcher workaround no longer restores codex_app in dot-created tasks on this build.

    Reproduction & Diagnostic Details (26.1111.2228.0)

    1. MSIX Virtualized Executor Paths:
      Under the Store package (OpenAI.Codex_2p2nqsd0c76g0), the executor launcher exists in two places:

      • Virtualized AppData: %LOCALAPPDATA%\Packages\OpenAI.Codex_2p2nqsd0c76g0\LocalCache\Roaming\Codex\web\Codex\executor-plugins\codex-app-tools\scripts\launch_codex_app_tools_mcp.cmd
      • Plugin cache: %USERPROFILE%\.codex\plugins\cache\openai-bundled\codex-app-tools\26.1111.21308\scripts\launch_codex_app_tools_mcp.cmd
    2. Workaround Behavior:
      Adding if not defined SystemRoot for %%I in ("%__APPDIR__%..") do set "SystemRoot=%%~fI" immediately after setlocal in both scripts does not expose codex_app in fresh dot-created tasks. Unlike 26.930 (where codex_app attempted initialization and failed handshake), the dot task reports that the server is not registered in the session at all:

      No tool namespace named codex_app is available in this session.
      (Only mcp__codex_apps__* cloud connector tools are exposed in the dot session, whereas ordinary user-created local threads on the same machine expose all 50 mcp__codex_app tools.)

    3. Host Routing & Desktop Log Telemetry:
      Desktop logs (codex-desktop-*.log) confirm the Local Work executor connection is healthy ([tpp-local-executor] Local Work executor connection observation), while dot-created tasks route to hostId=durable—which logs -32601 on catalog load and never mounts codex_app (consistent with [Windows] dot-started local tasks lack Computer Use tools while ordinary local Codex sessions work #49458 and Windows: dot lacks native tools to read or message an existing local Codex conversation #49862):

      info [electron-message-handler] Loading MCP server catalog hostId=durable
      info [AppServerConnection] response_routed ... errorCode=-32601 ... method=mcpServerStatus/list
      warning [electron-message-handler] Failed to load MCP server catalog errorMessage="unsupported app-server method: mcpServerStatus/list" ... hostId=durable
      
    4. Static config.toml Override Behavior:
      Manually declaring [mcp_servers.codex_app] in ~/.codex/config.toml pointing to the guarded launch_codex_app_tools_mcp.cmd and server.mjs does not bridge codex_app into hostId=durable sessions, and instead overrides/suppresses the Electron host's dynamic IPC injection of mcp__codex_app in hostId=local threads until removed.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    appbugdotsmcpwindows-os

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions