You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Crash: EXC_BREAKPOINT in ONNX Runtime 1.21.0 via Bun N-API on Apple Silicon #26132
OpenCode crashes with EXC_BREAKPOINT (SIGTRAP) approximately 90 seconds after launch. The crash originates from a worker thread interacting with ONNX Runtime 1.21.0 through Bun's N-API bridge.
Process uptime at crash: ~92 s (launched 14:25:38, crashed 14:27:10)
Loaded Native Modules
Module
Base
Size
onnxruntime_binding.node
0x104900000
147456
libonnxruntime.1.21.0.dylib
0x153F80000
~20 MB
sharp-darwin-arm64.node
0x1049E4000
180224
libvips-cpp.8.17.3.dylib
0x15228C000
~14 MB
Hypothesis
The crash address 0x0000000102fb7ee4 falls within the main .opencode binary image (base 0x100E58000, size ~60 MB), suggesting the SIGTRAP fires inside Bun's own code — likely its N-API / NAPI bridge layer — while servicing a call from onnxruntime_binding.node.
Known friction points:
Bun's N-API implementation has documented gaps vs. Node.js, particularly around threadsafe functions, reference counting, and error propagation from native modules.
ONNX Runtime 1.21.0 uses background inference threads that call back into JS via N-API threadsafe functions — a path that has historically been fragile under Bun.
The issue does not use one of the required issue templates (Bug Report, Feature Request, or Question). Please re-submit using the Bug Report template, which requires a proper Description field and steps to reproduce.
The OS version listed (macOS 26.3) appears incorrect — the current macOS release line is 15.x (Sequoia). Please verify and correct your environment information.
The report reads as AI-generated (highly structured tables, polished hypothesis section). We require authentic, user-written descriptions of what you actually experienced.
Please edit this issue to address the above within 2 hours, or it will be automatically closed.
This issue might be a duplicate of an existing issue. Please check:
Activity
github-actions commentedon May 7, 2026
This issue doesn't fully meet our contributing guidelines.
What needs to be fixed:
macOS 26.3) appears incorrect — the current macOS release line is 15.x (Sequoia). Please verify and correct your environment information.Please edit this issue to address the above within 2 hours, or it will be automatically closed.
This issue might be a duplicate of an existing issue. Please check:
trace trapcrash on macOS Apple SiliconIf you believe this was flagged incorrectly, please let a maintainer know.