CLI v2.1.92: computer-use prebuilds missing from npm package
Description
The computer-use MCP built into Claude Code CLI fails with errors because the native prebuilt binaries are not included in the npm package.
Steps to Reproduce
- Install Claude Code CLI via npm:
npm install -g @anthropic-ai/claude-code@2.1.92 - Start
claude, enable computer-use via/mcp - Try any computer-use tool (e.g.
list_granted_applications,screenshot,left_click_drag)
Errors
Cannot read properties of undefined (reading 'checkAccessibility')— when callinglist_granted_applicationsorscreenshotCannot find module '/home/runner/code/tmp/claude-cli-external-build-2201/node_modules/@ant/computer-use-input/prebuilds/computer-use-input.node'— when callingleft_click_drag
Root Cause
The bundled cli.js references two native modules:
@ant/computer-use-swift→ resolved viaprocess.env.COMPUTER_USE_SWIFT_NODE_PATH ?? path.resolve(__dirname, "../prebuilds/computer_use.node")@ant/computer-use-input→ resolved viaprocess.env.COMPUTER_USE_INPUT_NODE_PATH ?? path.resolve(__dirname, "../prebuilds/computer-use-input.node")
However, the __dirname in the bundled code is hardcoded to the build server path (/home/runner/code/tmp/claude-cli-external-build-2201/node_modules/@ant/...), which doesn't exist on user machines.
Additionally, package.json's files field does not include prebuilds/:
"files": [
"cli.js",
"sdk-tools.d.ts",
"vendor/ripgrep/",
"vendor/audio-capture/",
"vendor/seccomp/"
]
So the npm tarball ships without the prebuilt .node binaries, making computer-use completely non-functional when installed via npm.
Environment
- macOS 15 (Darwin 25.4.0), Apple Silicon (arm64)
- Node.js v24.13.0
- Claude Code v2.1.92 installed via
npm install -g @anthropic-ai/claude-code
Expected Behavior
The prebuilds/ directory containing computer_use.node and computer-use-input.node should be included in the npm package, or downloaded at install time, so that computer-use works out of the box.
This issue has 3 comments on GitHub. Read the full discussion on GitHub ↗