Conversation
The intermittent 'Assertion failed: (env) != nullptr' / core-dumped crash hitting nuxt generate (both in CI's verify-build and in the Cloud Build CD image) isn't flakiness in this repo's own code - it's an open Node.js core regression: node::ObjectWrap cleanup hooks were backported to the 24.x line without their registry, so any native addon using ObjectWrap (which better-sqlite3 does, even at the 12.11.1 override from #281) aborts deterministically under GC pressure on Node >=24.19.0. nodejs/node#65446 Both ci.yml and cd.yml floated on node_version: "24", which resolves to whatever the latest 24.x patch is at build time - explaining why this passed some runs and crashed others with identical dependency versions. Pinning to 24.18.1, the last version confirmed unaffected in the upstream report, removes the crash at the source rather than retrying past it. Does not touch bcgov/bcregistry-sre's shared default (still "24") - scoped to this repo's own pin. Every other app using the same shared CI/CD is exposed to the same bug and would benefit from the same fix, but changing the shared default affects all of them and is a bigger call than this PR.
This branch was successfully deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fixes the intermittent crash both #281 and #282 hit ("Assertion failed: (env) != nullptr", core dumped, exit 134) during
nuxt generate- both in CI'sverify-buildand in the Cloud Build CD image.Root cause
Not flakiness in this repo - it's an open Node.js core regression: nodejs/node#65446
node::ObjectWrapcleanup hooks were backported to the 24.x line without their registry, so any native addon usingObjectWrap(whichbetter-sqlite3does, even at the 12.11.1 version #281 already switched to) aborts deterministically under GC pressure on Node >=24.19.0. #281's version bump reduced how often it happened but couldn't fix it, since the bug is in Node itself, not the dependency.Both
ci.ymlandcd.ymlsetnode_version: "24", which resolves to whatever the latest 24.x patch is at build time - explaining why the exact same commit/dependencies passed on some runs and crashed on others.Fix
Pin to
24.18.1, the last version confirmed unaffected in the upstream report. Removes the crash at the source instead of retrying past it.Does not touch
bcgov/bcregistry-sre's shared workflow default (still"24") - every app using that shared CI/CD is exposed to the same bug, but changing the shared default affects all of them and is a bigger call than this PR. Flagging separately.Verified
verify-build (24.18.1, 11.9.0)- passes on this branch.Node version: v24.18.1, no crash, "Deploy complete" to https://yfthig-dev.web.app.