Skip to content

macOS 26.4.1: repeated Codex crashes with AppleSystemPolicy provenance errors, dyld child SIGABRT, and Array buffer allocation failures on large threads #19166

Open

Description

@fbcwimberley

Summary

Codex for Mac is repeatedly crashing on my machine. I am seeing two correlated failure modes:

  1. Shell children launched by Codex abort immediately in dyld before shell startup.
  2. Codex logs RangeError: Array buffer allocation failed while trying to serialize/send very large conversation snapshots, especially image-heavy threads.

The app bundle itself appears valid and notarized, so this does not look like a simple corrupt install.

Environment

  • Codex version: 26.417.41555 (build 1858)
  • Electron version from running process: 41.2.0
  • macOS: 26.4.1 (25E253)
  • Hardware: Apple Silicon (Mac15,3)

What I verified

  • spctl --assess --type execute -vv /Applications/Codex.app reports:
    • accepted
    • source=Notarized Developer ID
  • codesign --verify --verbose=4 /Applications/Codex.app reports:
    • valid on disk
    • satisfies its Designated Requirement

Crash evidence

Newest child-shell crash report:

  • ~/Library/Logs/DiagnosticReports/zsh-2026-04-23-120456.ips

Relevant fields from that report:

  • procName: zsh
  • parentProc: codex
  • responsibleProc: Codex
  • exception: EXC_CRASH / SIGABRT
  • stack includes:
    • ignition_halt
    • boot_boot
    • dyld4::CacheFinder::CacheFinder(...)
    • dyld4::ProcessConfig::DyldCache::DyldCache(...)

This same pattern repeats across many reports on the same date, including multiple zsh-*.ips and one bash-*.ips in ~/Library/Logs/DiagnosticReports/.

System log evidence

During the same crash window, unified logs show repeated AppleSystemPolicy / syspolicyd failures for Codex:

Time window examples:

  • around 2026-04-23 12:02:00 -0500
  • around 2026-04-23 12:05:23 -0500

Representative lines:

  • ASP: Unable to apply provenance sandbox: ..., /Applications/Codex.app/Contents/MacOS/Codex
  • Unable to initialize qtn_proc: 3
  • dispatch_mig_server returned 268435459

These entries repeat many times in a burst immediately around the crashes.

Codex app log evidence

Codex logs show snapshot serialization failures in the same session:

File:

  • ~/Library/Logs/com.openai.codex/2026/04/23/codex-desktop-b2bab1d7-487b-447c-8fa9-db2254e76d38-78328-t0-i1-164953-4.log

Representative error:

  • Failed to send message from view
  • Error invoking remote method 'codex_desktop:message-from-view': RangeError: Array buffer allocation failed

This appears while Codex is trying to send a thread snapshot / patch for a very large conversation state.

Heavy-thread correlation

The largest local session files are:

  1. ~/.codex/sessions/2026/04/21/rollout-2026-04-21T11-32-29-019db0e2-d834-7b22-ad36-2932082428a5.jsonl — 38,966,307 bytes
    • current crash log directly references this conversation
    • contains 62 embedded "type":"image" payloads
  2. ~/.codex/sessions/2026/04/20/rollout-2026-04-20T15-34-27-019dac9a-024c-7a70-949e-62fa4e7cd884.jsonl — 18,037,109 bytes
    • contains 14 embedded "type":"image" payloads
  3. ~/.codex/sessions/2026/04/22/rollout-2026-04-22T19-55-02-019db7d5-4bf3-7a42-98db-0e6a3d8f4cf2.jsonl — 15,237,908 bytes
  4. ~/.codex/sessions/2026/04/20/rollout-2026-04-20T20-47-22-019dadb8-7eb0-7d90-9e71-21b217a7fc68.jsonl — 8,504,048 bytes
    • this thread also appears in the failing snapshot log

So there seems to be a strong correlation between very large / image-heavy threads and the Array buffer allocation failed path.

Runtime memory at crash/restart window

Immediately after restart, process memory was already very high:

  • Codex main process: about 1.58 GB RSS
  • Codex Helper (Renderer): about 693 MB RSS
  • codex app-server: about 674 MB RSS

Earlier in the session I also observed a similarly high combined footprint before another crash.

Repro pattern

I can often trigger instability with some combination of:

  1. Work in a long-lived thread with many screenshots / browser automation / large tool outputs.
  2. Reopen or continue one of the largest threads.
  3. Codex starts trying to sync or snapshot that thread state.
  4. App logs RangeError: Array buffer allocation failed.
  5. Around the same time, Codex-spawned shell children (zsh, sometimes bash) begin crashing immediately in dyld.
  6. The app becomes unstable or crashes again.

Expected

  • Large threads should not crash snapshot serialization.
  • Codex child shells should launch normally.
  • AppleSystemPolicy / provenance-related failures should not cascade into repeated child-process SIGABRTs.

Actual

  • Thread snapshotting appears to hit a serialization / allocation limit.
  • Codex-spawned child shells repeatedly abort in dyld.
  • Unified logs show repeated AppleSystemPolicy provenance failures for Codex around the same time.

Notes

  • This does not appear to be a bad signature / bad notarization / corrupted app bundle on disk.
  • The issue feels like a combination of:
    • a large-thread memory/snapshot handling problem in Codex, and/or
    • a macOS 26.4.1 provenance / child-process interaction problem when Codex repeatedly launches helpers/shells.

If useful, I can provide more sanitized excerpts from the .ips report and the Codex logs.

Activity

  1. added
    bugSomething isn't working
    appIssues related to the Codex desktop app
    sessionIssues involving session (thread) management, resuming, forking, naming, archiving
    tool-callsIssues related to tool calling
    on Apr 23, 2026
  2. oschrenk commented on May 1, 2026

    @oschrenk

    I ended up here after days of having issues with my machine after installing nix/nix-darwin and seeing random hanging/freezes when using git/grep/... basic system commands now provided by nix.

    Now I believe it's a macOS issue since I also see a lot of spamming issues

    2026-05-01 10:28:47.047 E  syspolicyd[492:231b34] [com.apple.syspolicy.exec:default] dispatch_mig_server returned 268435459
    2026-05-01 10:28:47.047 E  syspolicyd[492:231783] [com.apple.syspolicy.exec:default] Unable to initialize qtn_proc: 3
    2026-05-01 10:28:47.047 E  syspolicyd[492:231783] [com.apple.syspolicy.exec:default] Unable to initialize qtn_proc: 3
    2026-05-01 10:28:47.047 E  syspolicyd[492:231783] [com.apple.syspolicy.exec:default] dispatch_mig_server returned 268435459
    2026-05-01 10:28:47.047 E  syspolicyd[492:231b34] [com.apple.syspolicy.exec:default] Unable to initialize qtn_proc: 3
    2026-05-01 10:28:47.047 E  syspolicyd[492:231b34] [com.apple.syspolicy.exec:default] Unable to initialize qtn_proc: 3
    2026-05-01 10:28:47.047 E  syspolicyd[492:231b34] [com.apple.syspolicy.exec:default] dispatch_mig_server returned 268435459
    2026-05-01 10:28:47.047 E  syspolicyd[492:231783] [com.apple.syspolicy.exec:default] Unable to initialize qtn_proc: 3
    2026-05-01 10:28:47.047 E  syspolicyd[492:231783] [com.apple.syspolicy.exec:default] Unable to initialize qtn_proc: 3
    2026-05-01 10:28:47.047 E  syspolicyd[492:231783] [com.apple.syspolicy.exec:default] dispatch_mig_server returned 268435459
    
  3. oschrenk commented on May 6, 2026

    @oschrenk

    Opened Apple Feedback assistant ticket FBB22710105 - since it seriously impacts my work

  4. rdylina commented on May 10, 2026

    @rdylina

    Adding a similar macOS signal: Codex Desktop 26.506.31421, completed 825MB local rollout. Opening it caused app-server RSS around 4.5-5GB, thread/resume 252s, then a dropped 405MB thread-stream-state-changed IPC payload over the 256MB cap. This looks consistent with large-thread snapshot serialization/allocation pressure, even though I did not see a Crashpad dump.

  5. rdylina commented on May 10, 2026

    @rdylina

    Follow-up / PR offer: I read the contribution docs and understand external PRs are invitation-only. If the team thinks this direction fits, I’d be happy to take a stab at an invited PR for the open-source app-server side.

    Conceptually, the fix I’d propose is:

    • in no case should opening a thread load the entire transcript into app-server + client state
    • open threads from metadata + the latest tail only, roughly the most recent 100-200 messages or a small byte cap, whichever comes first
    • lazy-load older chunks only when the user scrolls upward / explicitly asks for them
    • compact or summarize the old head for model context instead of treating the full durable transcript as active state
    • keep large tool outputs/artifacts behind references, not inline in normal thread state
    • add hard byte/count limits so thread/read, thread/resume, and stream-state snapshots cannot produce 100MB+ payloads
    • document that Desktop/IDE clients should use paged turns/items and never full-hydrate a completed thread just because it was clicked

    The desktop side still needs closed-code changes, but the app-server can provide the safe bounded contract and fail gracefully when a client asks for full hydration of an oversized rollout.

  6. jabedude commented on Jun 2, 2026

    @jabedude

    @oschrenk do you have more detailed/concrete steps to get into this state?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    appIssues related to the Codex desktop appbugSomething isn't workingsessionIssues involving session (thread) management, resuming, forking, naming, archivingtool-callsIssues related to tool calling

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions