Node "Bus error (core dumped)" in a N-API addon in CI
A native N-API addon triggered a SIGBUS ("Bus error"), crashing Node with no JavaScript stack. This is a low-level fault - usually an ABI mismatch, a corrupted binary, or a memory-mapping issue on the runner.
What this error means
The job dies abruptly with "Bus error (core dumped)" and a non-zero exit, no JS error. It often appears right when a specific native module loads or does heavy work, and may be intermittent.
Bus error (core dumped)
# exit code 135, no JavaScript stack traceCommon causes
Native addon ABI mismatch
A binary built for a different Node ABI is loaded against the running Node, faulting at the binary boundary.
Corrupted binary or memory-mapping fault
A truncated download or a constrained/odd memory mapping on the runner causes a SIGBUS during mmap-backed access.
How to fix it
Rebuild or reinstall the native addon
Reinstall cleanly so the addon binary matches the active Node ABI.
rm -rf node_modules
npm ci
# or rebuild native modules in place
npm rebuildPin a Node version with matching prebuilds
Use a Node version the addon publishes a compatible binary for, and verify the download is intact.
- Match the Node major to the addon prebuild ABI.
- Clear caches that may hold a truncated binary.
- Re-run to confirm the crash was a transient/corruption issue.
How to prevent it
- Keep the Node ABI aligned with native addon prebuilds.
- Rebuild native modules after Node version changes.
- Latchkey self-healing managed runners auto-retry transient SIGBUS/corrupted-binary crashes and cache verified native binaries to avoid faulting downloads.