codex - 💡(How to fix) Fix macOS 15.6 arm64: codex CLI installs via npm but native binary fails to execute (`spawn Unknown system error -88`) [1 comments, 2 participants]

Official PRs (…)
ON THIS PAGE

Recommended Tools

×6

Utilities matched from this issue’s tags and category — try them while you read without losing context.

GitHub issue graph ai analysis

Paste a GitHub issue URL. We fetch that issue, discover linked issues from bodies/comments/timeline, collect linked pull requests, and produce a structured English report.

The report is written in English Markdown for sharing and archival.

Helpful · Quick feedback

Loading…
GitHub stats
openai/codex#21199Fetched 2026-05-06 06:25:00
View on GitHub
Comments
1
Participants
2
Timeline
3
Reactions
0
Author
Timeline (top)
labeled ×2commented ×1

On macOS 15.6 (Apple Silicon), npm install -g @openai/codex completes, but codex --version fails immediately. The failure occurs when the Node launcher tries to spawn the native Darwin ARM64 binary.

Error Message

node:internal/child_process:440 throw new ErrnoException(err, 'spawn'); ^

Error: spawn Unknown system error -88 at ChildProcess.spawn (node:internal/child_process:440:11) at spawn (node:child_process:796:9) at file:///opt/homebrew/lib/node_modules/@openai/codex/bin/codex.js:175:15 at ModuleJob.run (node:internal/modules/esm/module_job:437:25) at async onImport.tracePromise.proto (node:internal/modules/esm/loader:639:26) at async asyncRunEntryPointWithESMLoader (node:internal/modules/run_main:101:5) { errno: -88, code: 'Unknown system error -88', syscall: 'spawn' }

Node.js v25.9.0

Root Cause

On macOS 15.6 (Apple Silicon), npm install -g @openai/codex completes, but codex --version fails immediately. The failure occurs when the Node launcher tries to spawn the native Darwin ARM64 binary.

Code Example

npm install -g @openai/codex

---

codex --version

---

node:internal/child_process:440
    throw new ErrnoException(err, 'spawn');
          ^

Error: spawn Unknown system error -88
    at ChildProcess.spawn (node:internal/child_process:440:11)
    at spawn (node:child_process:796:9)
    at file:///opt/homebrew/lib/node_modules/@openai/codex/bin/codex.js:175:15
    at ModuleJob.run (node:internal/modules/esm/module_job:437:25)
    at async onImport.tracePromise.__proto__ (node:internal/modules/esm/loader:639:26)
    at async asyncRunEntryPointWithESMLoader (node:internal/modules/run_main:101:5) {
  errno: -88,
  code: 'Unknown system error -88',
  syscall: 'spawn'
}

Node.js v25.9.0

---

file /opt/homebrew/lib/node_modules/@openai/codex/node_modules/@openai/codex-darwin-arm64/vendor/aarch64-apple-darwin/codex/codex

---

Mach-O 64-bit executable arm64

---

codesign -dv /opt/homebrew/lib/node_modules/@openai/codex/node_modules/@openai/codex-darwin-arm64/vendor/aarch64-apple-darwin/codex/codex

---

code object is not signed at all

---

spctl --assess --type execute -vv /opt/homebrew/lib/node_modules/@openai/codex/node_modules/@openai/codex-darwin-arm64/vendor/aarch64-apple-darwin/codex/codex

---

invalid or unsupported format for signature

---

xattr -l /opt/homebrew/lib/node_modules/@openai/codex/node_modules/@openai/codex-darwin-arm64/vendor/aarch64-apple-darwin/codex/codex

---

com.apple.provenance: ...

---

codesign --force --sign - /opt/homebrew/lib/node_modules/@openai/codex/node_modules/@openai/codex-darwin-arm64/vendor/aarch64-apple-darwin/codex/codex

---

main executable failed strict validation
RAW_BUFFERClick to expand / collapse

Summary

On macOS 15.6 (Apple Silicon), npm install -g @openai/codex completes, but codex --version fails immediately. The failure occurs when the Node launcher tries to spawn the native Darwin ARM64 binary.

Environment

  • macOS 15.6
  • Build: 24G84
  • Architecture: arm64
  • Kernel: Darwin 24.6.0
  • Node.js: v25.9.0
  • npm: 11.12.1

Install command

npm install -g @openai/codex

Also reproduced after rolling back to @openai/[email protected].

Reproduction

codex --version

Actual result

node:internal/child_process:440
    throw new ErrnoException(err, 'spawn');
          ^

Error: spawn Unknown system error -88
    at ChildProcess.spawn (node:internal/child_process:440:11)
    at spawn (node:child_process:796:9)
    at file:///opt/homebrew/lib/node_modules/@openai/codex/bin/codex.js:175:15
    at ModuleJob.run (node:internal/modules/esm/module_job:437:25)
    at async onImport.tracePromise.__proto__ (node:internal/modules/esm/loader:639:26)
    at async asyncRunEntryPointWithESMLoader (node:internal/modules/run_main:101:5) {
  errno: -88,
  code: 'Unknown system error -88',
  syscall: 'spawn'
}

Node.js v25.9.0

Additional diagnostics

The native binary is present and matches the machine architecture:

file /opt/homebrew/lib/node_modules/@openai/codex/node_modules/@openai/codex-darwin-arm64/vendor/aarch64-apple-darwin/codex/codex

Output:

Mach-O 64-bit executable arm64

Gatekeeper / signing checks:

codesign -dv /opt/homebrew/lib/node_modules/@openai/codex/node_modules/@openai/codex-darwin-arm64/vendor/aarch64-apple-darwin/codex/codex
code object is not signed at all
spctl --assess --type execute -vv /opt/homebrew/lib/node_modules/@openai/codex/node_modules/@openai/codex-darwin-arm64/vendor/aarch64-apple-darwin/codex/codex
invalid or unsupported format for signature

Also present in xattrs:

xattr -l /opt/homebrew/lib/node_modules/@openai/codex/node_modules/@openai/codex-darwin-arm64/vendor/aarch64-apple-darwin/codex/codex
com.apple.provenance: ...

Attempting to ad-hoc sign locally also failed:

codesign --force --sign - /opt/homebrew/lib/node_modules/@openai/codex/node_modules/@openai/codex-darwin-arm64/vendor/aarch64-apple-darwin/codex/codex
main executable failed strict validation

Notes

This is not specific to any project directory; it reproduces from the home directory as well.

It also reproduced after uninstalling, cleaning the global install, reinstalling, and then rolling back from 0.128.0 to 0.125.0.

extent analysis

TL;DR

The issue is likely due to the native binary not being properly signed, causing the Node launcher to fail when trying to spawn it, and a potential workaround is to adjust the system's security settings to allow unsigned binaries to run.

Guidance

  • The error message "Unknown system error -88" and the output from codesign and spctl commands suggest that the issue is related to the binary not being signed.
  • The presence of the com.apple.provenance xattr and the failure of ad-hoc signing attempts indicate that the system's security features are preventing the binary from running.
  • To verify the issue, try running the codex command with the --verbose flag to see if it provides more detailed error messages.
  • As a potential workaround, consider adjusting the system's security settings to allow unsigned binaries to run, such as by using the spctl command to assess the binary with the --type execute option and the --verbose flag.

Example

No code snippet is provided as it is not directly related to the issue, but the following command can be used to assess the binary:

spctl --assess --type execute -vv /opt/homebrew/lib/node_modules/@openai/codex/node_modules/@openai/codex-darwin-arm64/vendor/aarch64-apple-darwin/codex/codex

Notes

The issue seems to be specific to the macOS 15.6 (Apple Silicon) environment and the @openai/codex package. The fact that the issue reproduces after rolling back to an earlier version of the package suggests that the issue is not specific to a particular version.

Recommendation

Apply workaround: Adjust the system's security settings to allow unsigned binaries to run, as the issue is likely due to the binary not being properly signed.

Vote matrix · Quick signals

Works
Did the solution work? Tap to confirm.
Easy Fix
Was it a quick fix?
Time Saver
Did it save you time?
Blocking
Was it severely blocking?
Common Issue
Are others likely hitting this too?
Flaky / Intermittent
Is it intermittent?
Verified / Reproducible
Can you reproduce it reliably?
Loading…

Still need to ship something?

×6

Another batch ranked right after the header list — different links, same matching logic.

Back to top recommendations

TRENDING

codex - 💡(How to fix) Fix macOS 15.6 arm64: codex CLI installs via npm but native binary fails to execute (`spawn Unknown system error -88`) [1 comments, 2 participants]