Bump JsRuntimeHost to cb988ba - #1848
Merged
bkaradzic-microsoft merged 1 commit intoAug 24, 2026
Merged
Conversation
Picks up three fixes that have landed on JsRuntimeHost master since the current pin (9271f13, 2026-07-28): BabylonJS#223 keep escaped handles alive when their escapable scope closes BabylonJS#225 QuickJS: report success from the napi_throw family BabylonJS#227 fix V8 N-API leaking every promise ever created Validated on Windows/x64 RelWithDebInfo against both engines whose N-API ports these fixes touch: V8 UnitTests 21/21, validation sweep ran=305 passed=305, peak 2598 MB QuickJS UnitTests 21/21, validation sweep ran=305 passed=305, peak 1910 MB The bump is behaviour-neutral on this suite; a same-tree V8 baseline on the old pin also measured 305/305 at 2558 MB, so the promise leak is not large enough to show up over 305 tests. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> Copilot-Session: 88569c10-a7ff-4373-9a58-afa9c68b8c09
Contributor
There was a problem hiding this comment.
Pull request overview
Updates the BabylonNative build to pull a newer pinned revision of the external JsRuntimeHost dependency, bringing in upstream correctness fixes (escaped handle lifetime, QuickJS napi_throw* success reporting, and a V8 N-API promise leak fix).
Changes:
- Bumps the
FetchContent_Declare(JsRuntimeHost)GIT_TAGin the top-level CMake configuration from9271f13...tocb988ba....
💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.
bkaradzic-microsoft
pushed a commit
to bkaradzic-microsoft/BabylonNative
that referenced
this pull request
Aug 24, 2026
Conflicts resolved in favour of the shotgun branch in every case: CMakeLists.txt - BabylonJS#1848 bumps JsRuntimeHost to cb988ba. shotgun points at the bkaradzic-microsoft fork's shotgun branch instead, which already contains cb988ba as an ancestor, so keeping our pin loses nothing. Polyfills/Canvas/Source/Context.h - upstream's State struct declares globalAlpha as double, but Context.cpp assigns static_cast<float>(alpha) into it and passes it straight to nvgGlobalAlpha(float). shotgun's float is consistent with both the cast and nanovg's own type. Polyfills/Canvas/Source/Context.cpp - three hunks, all cases where upstream carries an earlier revision of work that shotgun has since superseded: - fill/strokeStyle gradients: shotgun uses CanvasGradient::TryUnwrap and throws a JS TypeError when the style is neither a colour string nor a gradient; upstream's Unwrap dereferences null there. - MeasureText: upstream returns synthesised Arial metrics whenever the requested family is not loaded. shotgun instead binds the face FillText will actually use and measures that, falling back to synthesised metrics only when no face is available at all, so the metrics describe the font that gets drawn.
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.
Moves the JsRuntimeHost pin from
9271f13(2026-07-28) tocb988ba, which is current JsRuntimeHostmaster. That picks up three fixes:napi_throwfamilyValidation
Windows/x64, RelWithDebInfo, MSVC 14.44 — run against both engines whose N-API ports these fixes touch:
ran=305 passed=305 failed=0ran=305 passed=305 failed=0To be clear about what this does and does not buy: the bump is behaviour-neutral on this suite. A same-tree V8 baseline on the old pin also measured
305/305at 2558 MB, so the promise leak is not large enough to surface over 305 tests. The value here is the three correctness fixes, not a measurable win on the current suite.It does matter at larger scale. On the NativeDawn branch, whose sweep runs 632 tests, the same pin difference is the gap between the sweep completing at ~5.4 GB and aborting partway through at ~12.1 GB.