Repository navigation
macOS: cua_repl does not respawn after launch.mjs/node_repl exit; createBrowserTab returns Transport closed in ~1ms #44518
Description
What version of Codex CLI is running?
codex-cli 0.153.4 (codex app-server --enable goals)
Computer Use runtime comes from ChatGPT.app 26.903.61454 (build 8378) via plugin unified-computer-use@openai-bundled (launch.mjs + bundled cua_node / node_repl). Hosts observed: 26.901.51231 and 26.903.61454.
What subscription do you have?
Logged in with ChatGPT. Exact plan not exposed by this CLI/app-server path.
Which model were you using?
Not model-dependent. Reproduced on gpt-5.6-luna because that is the long-lived thread; the failures are MCP transport / Computer Use host lifecycle.
What platform is your computer?
Darwin 25.6.0 arm64 arm (macOS 26.6.2, 25G83)
What terminal emulator and version are you using (if applicable)?
Not a TUI session. codex app-server --enable goals spawned by Paseo Desktop 0.8.0-beta.1 (bundle sh.paseo.desktop). Same plugin/cua_repl stack as Codex Computer Use.
Codex doctor report
not available (not run; this is a Computer Use MCP transport failure on a long-lived app-server)
What issue are you seeing?
Two related Computer Use failures on a long-lived app-server that we did not restart.
A. Chrome CUA works, then getState() reports no browsers while the Chrome native host is still alive.
cua.createBrowserTab("chrome", url, { sessionName }) plus Playwright waitForEvent("filechooser") + setFiles succeeded (2026-09-10 ~17:37–17:48 local, and createBrowserTab("chrome", …) again ~18:39).
Later the same process’s cua.getState() returned:
apps=[]
browsers=[]
Sky Computer Use native pipe startup failed
At that time:
- Google Chrome was still running
- native host
ChatGPT for Chrome(chrome-extension://hehggadaopoacecdllhhajmbjkdcmajg/) was still a child of Chrome js_resetdid not restorebrowsers
Plugin env:
CUA_REPL_ENABLED_SURFACES=browser,computer
Sky Apple Events were already failing for the responsible parent app. A Sky native-pipe failure appears to zero both surfaces.
B. After launch.mjs / node_repl exit, cua_repl never respawns. Every subsequent call is Transport closed in milliseconds.
The app-server stayed up (writer lock still held). Its children no longer included launch.mjs / node_repl. Next calls:
tool call error: tool call failed for `cua_repl/js_reset`
Caused by:
Transport closed
tool call error: tool call failed for `cua_repl/js`
Caused by:
Transport closed
Exact MCP item for the last createBrowserTab (URL/session name redacted):
server: cua_repl
tool: js
status: failed
error.message: tool call error: tool call failed for `cua_repl/js`
Caused by:
Transport closed
duration: { "secs": 0, "nanos": 1408875 }
Wall time printed by the tool wrapper: 0.0046 seconds.
Quitting ChatGPT.app and retrying the same createBrowserTab("chrome", …) (no getState, no js_reset) still returned Transport closed in ~1.4ms. No new CUA host appeared under the app-server. Another app-server on the same machine still had a live 26.903.61454 launch.mjs child, so Computer Use is not globally dead — only this session’s MCP stdio.
What steps can reproduce the bug?
The empty-browsers state is intermittent. The Transport closed / no-respawn path is reproducible once the bound host is gone.
-
Keep a Codex
app-serveralive for many hours withunified-computer-use/cua_replattached (do not start a new thread). -
Confirm Chrome CUA works:
let tab = await cua.createBrowserTab("chrome", "https://example.com", { sessionName: "repro" }); tab
-
Leave the session running. Optionally quit/relaunch ChatGPT.app, or let Sky native pipe fail. Call
cua.getState(). Observebrowsers=[]andSky Computer Use native pipe startup failedeven if the Chrome extension native host is still running. -
Kill or wait until this thread’s
…/unified-computer-use/*/scripts/launch.mjsand itsnode_replchildren exit. Do not kill theapp-server. -
Call
js_resetand/orcua.createBrowserTab("chrome", …)again.
Expected: Codex starts a new launch.mjs host for cua_repl, or surfaces an actionable “Computer Use host died, restart MCP” error.
Actual: Transport closed in ~1ms. pgrep -P <app-server-pid> still has no CUA child. js_reset cannot recover a dead stdio transport. Starting a different app-server can still get a fresh host.
What is the expected behavior?
getState()/createBrowserTab("chrome")should not depend on Sky native pipe when the Chrome native host is alive. IfCUA_REPL_ENABLED_SURFACESincludesbrowser, acomputerhandshake failure should not reportbrowsers=[].- If
launch.mjs/node_replexits,app-servershould respawncua_replon the next tool call (or clearly mark the MCP server as dead and restart it).js_resetshould not be the only recovery, and it should not be offered when the transport is already closed. - Long-lived sessions should not require killing
app-server(and losing the thread writer lock) to get Computer Use back.
Additional information
Related:
- macOS app update leaves pre-update node_repl host unable to authenticate to new Computer Use service #39042 — pre-update
node_replcannot authenticate;js_resetinsufficient; fresh host works. Same recovery hole for a liveapp-server. - Codex for macOS accumulates Computer Use / MCP helper processes and unreaped zombie children, causing HID lag and WindowServer/TCC stalls #25744 / Desktop app (macOS): idle node_repl visualization kernels accumulate (60–70 concurrent, ~600 MB), causing severe input lag #39816 —
node_replhelper accumulation. - Browser / computer-use fails intermittently with “transport closed” and “kernel exited unexpectedly” #25848 — intermittent
transport closed(Windows app). - Computer Use native pipe rejects signed in-app sender as unauthenticated on macOS 26.5.2 #35234 — native pipe sender not authenticated.
- [Windows 26.901.51231] unified-computer-use materialization sets CUA_REPL_ENABLED_SURFACES=browser, stripping sky trusted RPC #43498 —
CUA_REPL_ENABLED_SURFACES=browserstripping Sky (inverse coupling). - macOS app lacks Apple Events entitlement required by Codex Computer Use getpaseo/paseo#3346 — Paseo Desktop lacks
com.apple.security.automation.apple-events, so macOS attributes Paseo-spawned Sky CUA to Paseo and denies Apple Events without a prompt. That explains Sky, not Chrome CUA working then dying, and notTransport closedafter host exit.
.mcp.json for cua_repl (paths redacted to usernames):
command: /Applications/ChatGPT.app/Contents/Resources/cua_node/bin/node
args: [ "~/.codex/plugins/cache/openai-bundled/unified-computer-use/26.903.61454/scripts/launch.mjs" ]
env.CUA_REPL_ENABLED_SURFACES: browser,computer
env.CUA_REPL_NODE_REPL_PATH: /Applications/ChatGPT.app/Contents/Resources/cua_node/bin/node_repl
startup_timeout_sec: 120
tools: js, js_reset, turn_ended
Activity
limbooomaker commentedon Sep 10, 2026
Paseo-side counterpart (long-lived desktop-spawned app-server cannot recover CUA without killing the agent): getpaseo/paseo#4656