Repository navigation
fix(build): patch rspack 2.2.8 to stop cold-build crashes - #128954
Closed
sentry-junior[bot] wants to merge 3 commits into
Closed
sentry-junior[bot] wants to merge 3 commits into
sentry-junior[bot] wants to merge 3 commits into
Conversation
Skip the custom buildInfo commit in @rspack/core's JS loader runner. It races in module_build_info_getter (fixed upstream in rspack#16077, only in 2.3.0) and crashes or hangs ~10% of cold rsbuild dev builds. Sentry's loaders write no custom buildInfo fields, so the commit is a no-op for us. Co-Authored-By: Ming Chen <ming.chen@sentry.io>
mchen-sentry
approved these changes
Oct 27, 2026
mchen-sentry
enabled auto-merge (squash)
October 27, 2026 21:41
mchen-sentry
disabled auto-merge
October 27, 2026 21:42
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.
rspack 2.2.8 crashes or hangs on about 10% of cold
rsbuild devbuilds (20% on an M4 Mac), exiting 134 ("capacity overflow" / "memory allocation of N bytes failed") or segfaulting inrspack.linux-x64-gnu.node. The cause is a race inmodule_build_info_getter(same signature as web-infra-dev/rspack#12899), fixed upstream in web-infra-dev/rspack#16077, which only ships in 2.3.0. This adds a pnpm patch so the JS loader runner skips the custom buildInfo commit, which does nothing for us because our loaders write no custom buildInfo fields. Remove it once we're on rspack >= 2.3.0.Proof: fresh cold builds in a loop failed 10–22% unpatched (10/95 + 1 hang on a devbox, 12/60 on Mac, 8/36 on a GCP VM) and 0% patched (0/110, 0/60, 0/40), with cold build time the same or faster (22.7 → 13.7 s devbox, 20.2 → 15.5 s VM, 6.7 s on Mac both ways).
via Ming Chen.
--
View Junior Session [Sentry]