Computer Use 1.0.1000451 cannot load @oai/sky because nodeRepl.env is empty on macOS 26

Open
#34,471 7 comments 1 reaction 0 assignees View on GitHub

Nobody has claimed this yet.

Assessment

Difficulty
4/5
Estimated time
3-5 days
Newbie friendliness
48/100
Issue type
Bug
Clarity
Mostly clear
Activity status
Quiet
Tech stack
javascript, node.js
Domain
desktop, tooling

Research direction

Start with the plugin-owned scripts/computer-use-client.mjs and reproduce the documented setupComputerUseRuntime() bootstrap, then inspect how it reads NODE_REPL_NODE_MODULE_DIRS from nodeRepl.env. Compare that with the registered path reported by js_add_node_module_dir and the bundled @oai/sky location in the ChatGPT application. Done means the wrapper loads @oai/sky and sky.list_apps() or get_app_state() executes on macOS.

Written by the indexing model from the issue text.

Description

app bug computer-use
What version of the Codex App are you using (From “About Codex” dialog)?

Version 26.715.52143 (5591)

Computer Use plugin: 1.0.1000451

What subscription do you have?

Pro

What platform is your computer?

Darwin 25.5.0 arm64 arm

macOS 26.5.1 (25F80), Apple Silicon

What issue are you seeing?

The bundled Computer Use plugin cannot initialize. Every Computer Use operation fails before accessing the target application because the plugin wrapper cannot locate the bundled @oai/sky runtime.

The runtime is installed inside the ChatGPT application bundle, but nodeRepl.env is an empty immutable object. Consequently, computer-use-client.mjs receives no NODE_REPL_NODE_MODULE_DIRS, creates an empty search-root list, and throws:

Computer Use could not load @oai/sky from the cua_node runtime

This reproduces with sky.list_apps() and when targeting Safari or Google Chrome. The failure occurs before application permissions or UI access are evaluated.

Diagnostic output from the running Node REPL:

{
  "env": {},
  "envExtensible": false,
  "nodeReplEnvDescriptor": {
    "value": {},
    "writable": false,
    "enumerable": true,
    "configurable": false
  }
}

The required runtime does exist at:

/Applications/ChatGPT.app/Contents/Resources/cua_node/lib/node_modules/@oai/sky/dist/project/cua/sky_js/src/targets/mac/create_client.js

The plugin-owned wrapper is installed at:

$HOME/.codex/plugins/cache/openai-bundled/computer-use/1.0.1000451/scripts/computer-use-client.mjs

No PII, credentials, or access tokens are included in this report.

What steps can reproduce the bug?
  1. On an Apple Silicon Mac, install and enable the bundled Computer Use plugin.
  2. Enable its MCP server and skill.
  3. Grant the Codex/ChatGPT desktop app Screen Recording and Accessibility permissions.
  4. Restart the desktop app and open a fresh Codex task.
  5. Invoke @Computer and ask it to list the available applications, or run the documented plugin bootstrap:
if (!globalThis.sky) {
  const { setupComputerUseRuntime } = await import(
    "$HOME/.codex/plugins/cache/openai-bundled/computer-use/1.0.1000451/scripts/computer-use-client.mjs"
  );
  await setupComputerUseRuntime({ globals: globalThis });
}

await sky.list_apps();
  1. Observe the initialization error:
Computer Use could not load @oai/sky from the cua_node runtime

Troubleshooting already performed:

  • Restarted the desktop app multiple times.
  • Verified that Computer Use, its MCP server, and its skill are enabled.
  • Tested both Safari and Google Chrome.
  • Verified that the @oai/sky runtime exists in the application bundle.
  • Verified that the runtime's node_modules directory is already registered with js_add_node_module_dir.
  • Added another registered node_modules path; nodeRepl.env remained empty.
  • Confirmed that nodeRepl.env cannot be modified because it is frozen and non-writable.

Session ID: not applicable / not available.

Token-limit and context-window usage: not relevant; the failure occurs during tool runtime initialization.

What is the expected behavior?

setupComputerUseRuntime() should locate the bundled @oai/sky runtime, initialize globalThis.sky, and allow list_apps() and get_app_state() to execute.

The Node REPL should expose its registered module roots through NODE_REPL_NODE_MODULE_DIRS, or the Computer Use wrapper should obtain them through another supported Node REPL API.

Additional information

This appears related to #26190, which reports missing NODE_REPL_NODE_MODULE_DIRS and failed @oai/sky resolution on Windows. This report covers the same failure class on macOS with a newer desktop and Computer Use plugin build.

The Node REPL internally knows the module directory: calling js_add_node_module_dir with the ChatGPT-bundled cua_node/lib/node_modules directory reports that it is already registered. However, that registration is not reflected in the immutable nodeRepl.env object consumed by computer-use-client.mjs.

There is no documented workaround because the Computer Use skill requires loading @oai/sky through the plugin-owned wrapper rather than importing the package directly.

Dominant language
Rust
Stars
125k
Forks
19.5k
Avg merge
1m
Merged PRs (30d)
1k

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from openai/codex

All issues in openai/codex

Similar issues

More Rust issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.