Standalone Codex CLI crashes in `exec --dangerously-bypass-approvals-and-sandbox` on macOS 15.7.7 x86_64 with V8 SetPermissions SIGTRAP

Open 💬 3 comments Opened Jun 18, 2026 by OHNope

What version of Codex CLI is running?

codex-cli 0.141.0

What subscription do you have?

Plus

Which model were you using?

gpt-5.5

What platform is your computer?

Darwin 24.6.0 x86_64 i386

What terminal emulator and version are you using (if applicable)?

iTerm2

Codex doctor report

{
  "schemaVersion": 1,
  "generatedAt": "1781774441s since unix epoch",
  "overallStatus": "ok",
  "codexVersion": "0.141.0",
  "checks": {
    "app_server.status": {
      "id": "app_server.status",
      "category": "app-server",
      "status": "ok",
      "summary": "background server is not running",
      "details": {
        "control socket": "/Users/xby/.codex/app-server-control/app-server-control.sock",
        "daemon state dir": "/Users/xby/.codex/app-server-daemon",
        "mode": "ephemeral",
        "pid file": "/Users/xby/.codex/app-server-daemon/app-server.pid (missing)",
        "settings": "/Users/xby/.codex/app-server-daemon/settings.json (missing)",
        "status": "not running",
        "update-loop pid file": "/Users/xby/.codex/app-server-daemon/app-server-updater.pid (missing)"
      },
      "remediation": null,
      "durationMs": 0
    },
    "auth.credentials": {
      "id": "auth.credentials",
      "category": "auth",
      "status": "ok",
      "summary": "auth is configured",
      "details": {
        "auth file": "/Users/xby/.codex/auth.json",
        "auth storage mode": "File",
        "stored API key": "false",
        "stored ChatGPT tokens": "true",
        "stored agent identity": "false",
        "stored auth mode": "chatgpt"
      },
      "remediation": null,
      "durationMs": 0
    },
    "config.load": {
      "id": "config.load",
      "category": "config",
      "status": "ok",
      "summary": "config loaded",
      "details": {
        "CODEX_HOME": "/Users/xby/.codex",
        "config.toml": "/Users/xby/.codex/config.toml",
        "config.toml parse": "ok",
        "cwd": "/Users/xby",
        "enabled feature flags": "shell_tool, unified_exec, shell_snapshot, terminal_resize_reflow, sqlite, hooks, enable_request_compression, multi_agent, apps, tool_suggest, plugins, in_app_browser, browser_use, browser_use_external, computer_use, plugin_sharing, image_generation, skill_mcp_dependency_install, mentions_v2, steer, guardian_approval, goals, collaboration_modes, tool_call_mcp_elicitation, personality, fast_mode, tui_app_server, remote_compaction_v2, workspace_dependencies",
        "feature flag overrides": "none",
        "feature flags enabled": "29",
        "log dir": "/Users/xby/.codex/log",
        "mcp servers": "0",
        "model": "gpt-5.5",
        "model provider": "openai",
        "sqlite home": "/Users/xby/.codex"
      },
      "remediation": null,
      "durationMs": 0
    },
    "git.environment": {
      "id": "git.environment",
      "category": "git",
      "status": "ok",
      "summary": "git version 2.54.0",
      "details": {
        "PATH git #1": "/usr/local/bin/git",
        "PATH git #2": "/usr/bin/git",
        "PATH git entries": "2",
        "git build options": "git version 2.54.0; cpu: x86_64; no commit associated with this build; sizeof-long: 8; sizeof-size_t: 8; shell-path: /bin/sh; rust: disabled; feature: fsmonitor--daemon; gettext: enabled; libcurl: 8.6.0; zlib: 1.2.12; SHA-1: SHA1_DC; SHA-256: SHA256_BLK; default-ref-format: files; default-hash: sha1",
        "git exec path": "/usr/local/opt/git/libexec/git-core",
        "git version": "git version 2.54.0",
        "repo detected": "false",
        "selected git": "/usr/local/bin/git"
      },
      "remediation": null,
      "durationMs": 42
    },
    "installation": {
      "id": "installation",
      "category": "install",
      "status": "ok",
      "summary": "installation looks consistent",
      "details": {
        "PATH codex #1": "/Users/xby/.local/bin/codex",
        "PATH codex #2": "/Users/xby/.local/bin/codex",
        "PATH codex entries": "2",
        "current executable": "/Users/xby/.local/bin/codex",
        "install context": "standalone (unix, package /Users/xby/.codex/packages/standalone/releases/0.141.0-x86_64-apple-darwin, bin /Users/xby/.codex/packages/standalone/releases/0.141.0-x86_64-apple-darwin/bin, resources /Users/xby/.codex/packages/standalone/releases/0.141.0-x86_64-apple-darwin/codex-resources, path /Users/xby/.codex/packages/standalone/releases/0.141.0-x86_64-apple-darwin/codex-path)",
        "managed by bun": "false",
        "managed by npm": "false",
        "managed package root": "not set"
      },
      "remediation": null,
      "durationMs": 8
    },
    "mcp.config": {
      "id": "mcp.config",
      "category": "mcp",
      "status": "ok",
      "summary": "no MCP servers configured",
      "details": {},
      "remediation": null,
      "durationMs": 1
    },
    "network.env": {
      "id": "network.env",
      "category": "network",
      "status": "ok",
      "summary": "network-related environment looks readable",
      "details": {
        "proxy env vars": "none"
      },
      "remediation": null,
      "durationMs": 0
    },
    "network.provider_reachability": {
      "id": "network.provider_reachability",
      "category": "reachability",
      "status": "ok",
      "summary": "active provider endpoints are reachable over HTTP",
      "details": {
        "ChatGPT base URL": "https://chatgpt.com/backend-api/ reachable (HTTP 403)",
        "reachability mode": "ChatGPT auth"
      },
      "remediation": null,
      "durationMs": 560
    },
    "network.websocket_reachability": {
      "id": "network.websocket_reachability",
      "category": "websocket",
      "status": "ok",
      "summary": "Responses WebSocket handshake succeeded",
      "details": {
        "DNS": "2 IPv4, 2 IPv6, first IPv6",
        "auth mode": "chatgpt",
        "connect timeout": "15000 ms",
        "endpoint": "wss://chatgpt.com/backend-api/<redacted>",
        "handshake result": "HTTP 101 Switching Protocols",
        "model provider": "openai",
        "models etag present": "true",
        "provider name": "OpenAI",
        "proxy env vars": "none",
        "reasoning header": "false",
        "server model present": "false",
        "supports websockets": "true",
        "wire API": "responses"
      },
      "remediation": null,
      "durationMs": 1486
    },
    "runtime.provenance": {
      "id": "runtime.provenance",
      "category": "runtime",
      "status": "ok",
      "summary": "running standalone on macos-x86_64",
      "details": {
        "commit": "unknown",
        "current executable": "/Users/xby/.local/bin/codex",
        "install method": "standalone (unix, package /Users/xby/.codex/packages/standalone/releases/0.141.0-x86_64-apple-darwin, bin /Users/xby/.codex/packages/standalone/releases/0.141.0-x86_64-apple-darwin/bin, resources /Users/xby/.codex/packages/standalone/releases/0.141.0-x86_64-apple-darwin/codex-resources, path /Users/xby/.codex/packages/standalone/releases/0.141.0-x86_64-apple-darwin/codex-path)",
        "platform": "macos-x86_64",
        "version": "0.141.0"
      },
      "remediation": null,
      "durationMs": 0
    },
    "runtime.search": {
      "id": "runtime.search",
      "category": "search",
      "status": "ok",
      "summary": "search is OK (bundled)",
      "details": {
        "search command": "/Users/xby/.codex/packages/standalone/releases/0.141.0-x86_64-apple-darwin/codex-path/rg",
        "search command readiness": "file exists",
        "search provider": "bundled"
      },
      "remediation": null,
      "durationMs": 0
    },
    "sandbox.helpers": {
      "id": "sandbox.helpers",
      "category": "sandbox",
      "status": "ok",
      "summary": "sandbox configuration is readable",
      "details": {
        "approval policy": "OnRequest",
        "codex-linux-sandbox helper": "none",
        "execve wrapper helper": "/Users/xby/.codex/tmp/arg0/codex-arg0IiYUbQ/codex-execve-wrapper",
        "filesystem sandbox": "restricted",
        "network sandbox": "restricted"
      },
      "remediation": null,
      "durationMs": 0
    },
    "state.paths": {
      "id": "state.paths",
      "category": "state",
      "status": "ok",
      "summary": "state paths and databases are inspectable",
      "details": {
        "CODEX_HOME": "/Users/xby/.codex (dir)",
        "active rollout files": "33 files, 27385836 total bytes, 829873 average bytes",
        "archived rollout files": "0 files, 0 total bytes, 0 average bytes",
        "goals DB": "/Users/xby/.codex/goals_1.sqlite (file)",
        "goals DB integrity": "ok",
        "log DB": "/Users/xby/.codex/logs_2.sqlite (file)",
        "log DB integrity": "ok",
        "log dir": "/Users/xby/.codex/log (dir)",
        "memories DB": "/Users/xby/.codex/memories_1.sqlite (file)",
        "memories DB integrity": "ok",
        "sqlite home": "/Users/xby/.codex (dir)",
        "standalone release cache": "1 entries in /Users/xby/.codex/packages/standalone/releases",
        "state DB": "/Users/xby/.codex/state_5.sqlite (file)",
        "state DB integrity": "ok"
      },
      "remediation": null,
      "durationMs": 4358
    },
    "state.rollout_db_parity": {
      "id": "state.rollout_db_parity",
      "category": "threads",
      "status": "ok",
      "summary": "rollout files and state DB thread inventory agree",
      "details": {
        "default model provider": "openai",
        "rollout DB active files": "33",
        "rollout DB active rows": "33",
        "rollout DB archive mismatches": "0",
        "rollout DB archived files": "0",
        "rollout DB archived rows": "0",
        "rollout DB duplicate DB paths": "0",
        "rollout DB duplicate rollout thread ids": "0",
        "rollout DB malformed file names": "0",
        "rollout DB missing active rows": "0",
        "rollout DB missing archived rows": "0",
        "rollout DB model providers": "openai=33",
        "rollout DB rows": "33",
        "rollout DB scan cap reached": "false",
        "rollout DB scan errors": "0",
        "rollout DB sources": "cli=32, exec=1",
        "rollout DB stale rows": "0"
      },
      "remediation": null,
      "durationMs": 874
    },
    "system.environment": {
      "id": "system.environment",
      "category": "system",
      "status": "ok",
      "summary": "OS language en-US",
      "details": {
        "EDITOR": "not set",
        "LANG": "en_US.UTF-8",
        "VISUAL": "not set",
        "os": "Mac OS 15.7.7 [64-bit]",
        "os language": "en-US",
        "os type": "Mac OS",
        "os version": "15.7.7"
      },
      "remediation": null,
      "durationMs": 10
    },
    "terminal.env": {
      "id": "terminal.env",
      "category": "terminal",
      "status": "ok",
      "summary": "terminal metadata was detected",
      "details": {
        "COLORFGBG": "15;0",
        "COLORTERM": "truecolor",
        "TERMINFO_DIRS entry": [
          "/Applications/iTerm.app/Contents/Resources/terminfo (dir)",
          "/usr/share/terminfo (dir)"
        ],
        "TERM_PROGRAM": "iTerm.app",
        "color output": "disabled (stdout is not a terminal)",
        "effective locale": "en_US.UTF-8",
        "stderr is terminal": "true",
        "stdin is terminal": "true",
        "stdout is terminal": "false",
        "terminal": "iTerm2",
        "terminal size": "80x25",
        "terminal version": "3.6.11"
      },
      "remediation": null,
      "durationMs": 2
    },
    "terminal.title": {
      "id": "terminal.title",
      "category": "title",
      "status": "ok",
      "summary": "terminal title default",
      "details": {
        "terminal title activity": "true",
        "terminal title items": "activity, project-name",
        "terminal title project source": "cwd",
        "terminal title project value": "xby",
        "terminal title source": "default"
      },
      "remediation": null,
      "durationMs": 1
    },
    "updates.status": {
      "id": "updates.status",
      "category": "updates",
      "status": "ok",
      "summary": "update configuration is locally consistent",
      "details": {
        "cached latest version": "0.141.0",
        "check for update on startup": "true",
        "last checked at": "2026-06-18T08:48:11.096710Z",
        "latest version": "0.141.0",
        "latest version status": "current version is not older",
        "update action": "standalone installer",
        "version cache": "/Users/xby/.codex/version.json"
      },
      "remediation": null,
      "durationMs": 86
    }
  }
}

What issue are you seeing?

The standalone Codex CLI crashes locally with EXC_BREAKPOINT / SIGTRAP when running codex exec --dangerously-bypass-approvals-and-sandbox with a nontrivial remote-development prompt.

A trivial prompt works, but a longer prompt that causes Codex to start actual tool/code execution crashes the local Codex process. This does not appear to be an SSH failure, because the macOS crash report shows the local codex process crashing in V8 initialization.

This also does not appear to be Homebrew-specific. I reproduced it with the standalone installer:

which codex:
  /Users/xby/.local/bin/codex

file "$(which codex)":
  /Users/xby/.local/bin/codex: Mach-O 64-bit executable x86_64

The crash stack appears related to the same V8 SetPermissions / Code Mode runtime issue reported in #27358 and #28390.

What steps can reproduce the bug?

  1. Use the standalone Codex CLI on macOS 15.7.7 x86_64.
  1. Confirm the installed binary:
which codex
type -a codex
file "$(which codex)"
sw_vers
uname -a

My output:

which codex:
  /Users/xby/.local/bin/codex

type -a codex:
  codex is /Users/xby/.local/bin/codex
  codex is /Users/xby/.local/bin/codex

file "$(which codex)":
  /Users/xby/.local/bin/codex: Mach-O 64-bit executable x86_64

sw_vers:
  ProductName: macOS
  ProductVersion: 15.7.7
  BuildVersion: 24G720

uname -a:
  Darwin BoyXs-MacBook-Pro.local 24.6.0 Darwin Kernel Version 24.6.0: Tue Apr 21 20:17:54 PDT 2026; root:xnu-11417.140.69.710.16~1/RELEASE_X86_64 x86_64
  1. Run a trivial prompt:
codex exec --dangerously-bypass-approvals-and-sandbox "hi"

This works normally.

  1. Save a longer remote-development prompt:
cat > /tmp/codex-crash-prompt.txt <<'EOF'
[redacted long prompt about SSH login node constraints, remote OnDemand desktop, no rg, use find/sed, no apply_patch, remote project path, and checking whether #include <Python.h> works]
EOF
  1. Run Codex with the same mode:
codex exec --dangerously-bypass-approvals-and-sandbox "$(cat /tmp/codex-crash-prompt.txt)"
  1. The local Codex process crashes with:
zsh: trace trap  codex exec --dangerously-bypass-approvals-and-sandbox
  1. macOS generates a codex-*.ips crash report in:
~/Library/Logs/DiagnosticReports/

What is the expected behavior?

Codex should either complete the task, execute the required tool calls, or fail gracefully with an error message.

The local Codex process should not terminate with EXC_BREAKPOINT / SIGTRAP during V8 / Code Mode runtime initialization.

Additional information

Crash report excerpt:

app_name: codex
timestamp: 2026-06-18 18:16:55.00 +0900
procPath: /Users/USER/*/codex

exception:
  type: EXC_BREAKPOINT
  signal: SIGTRAP
  codes: 0x0000000000000002, 0x0000000000000000

termination:
  namespace: SIGNAL
  indicator: Trace/BPT trap: 5
  code: 5

faultingThread: 35

Faulting thread frames:

v8::base::OS::SetPermissions(void*, unsigned long, v8::base::OS::MemoryPermission)
v8::internal::CodeRange::InitReservation(v8::PageAllocator*, unsigned long, bool)
v8::internal::Heap::SetUp(v8::internal::LocalHeap*)
v8::internal::Isolate::Init(v8::internal::SnapshotData*, v8::internal::SnapshotData*, v8::internal::SnapshotData*, bool)
v8::internal::Isolate::InitWithSnapshot(v8::internal::SnapshotData*, v8::internal::SnapshotData*, v8::internal::SnapshotData*, bool)
v8::internal::Snapshot::Initialize(v8::internal::Isolate*)
v8::Isolate::Initialize(v8::Isolate*, v8::Isolate::CreateParams const&)
v8::Isolate::New(v8::Isolate::CreateParams const&)
v8::isolate::Isolate::new::h73bb8a3ceb41a1b1
std::sys::backtrace::__rust_begin_short_backtrace::h688e855f528eec0f
_pthread_start
thread_start

I also generated:

codex doctor --json > codex-doctor-redacted.json

I can attach the redacted doctor report and a sanitized .ips crash report if useful.

Notes:

  • This is not a remote SSH failure. The local Codex process itself crashes.
  • It reproduces with the standalone installer, so it does not appear to be caused by Homebrew Cask packaging alone.
  • The crash stack is in V8 initialization and appears related to #27358 / #28390.

codex-crash-sanitized.txt

View original on GitHub ↗

This issue has 3 comments on GitHub. Read the full discussion on GitHub ↗