Repository navigation
Key validation example workarounds per test in config.json - #1920
Merged
bkaradzic-microsoft merged 3 commits intoOct 8, 2026
Merged
bkaradzic-microsoft merged 3 commits into
bkaradzic-microsoft merged 3 commits into
Conversation
validation_native.js carried four workarounds for bugs in the examples rather than in Babylon Native. They ran for every test. Each now has an ID and runs only for tests that list it in config.json "workarounds", so the lists double as the set of examples to fix: - wait-for-readiness: wait for utility scenes, GUI textures, and material effects (BabylonJS#1890). Without it the runner matches the browser: main-scene executeWhenReady, then renderCount frames. - undeclared-name: declare `name` for the example's direct eval (BabylonJS#1823). - prime-effect-layers: one extra frame before capture (BabylonJS#1913). - leak-cleanup: dispose stray scenes, release leaked textures, reset Draco state after the test. Unknown IDs fail config load. --list prints the IDs as a fifth column. The runner logs "Workaround '<id>' applied for '<title>'" when one changes what it does. Assignments come from three all-on runs of the 371 enabled tests (V8/D3D11), taking every test that triggered a workaround. With the final config all 371 pass. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> Copilot-Session: c46f0590-2707-466b-93c7-bb74316f385a
bkaradzic-microsoft
requested review from
bghgary
and
a balanced review from Copilot
October 8, 2026 02:06
Contributor
There was a problem hiding this comment.
🟡 Changes recommended
The undeclared-name workaround does not emit its required application log.
1 open finding
What changed in this PR
Scopes validation-runner workarounds to tests configured in the catalog.
Changes:
- Adds four validated workaround IDs with application logging.
- Assigns readiness, effect-layer, and cleanup workarounds per test.
- Updates
--listoutput and documentation.
| File | Description |
|---|---|
Documentation/AddingNewValidationTests.md |
Documents workaround configuration and behavior. |
Apps/Playground/Shared/CommandLine.cpp |
Documents the fifth TSV column. |
Apps/Playground/Scripts/validation_native.js |
Implements scoped workarounds and validation. |
Apps/Playground/Scripts/config.json |
Assigns workarounds to affected tests. |
.github/instructions/babylon-native-debugging.instructions.md |
Updates debugging guidance. |
🧠 Review effort: Balanced
Give feedback about Copilot approvals in this survey to enter a drawing for a $150 gift card.
- wait-for-import replaces the text `replace` patch on "OpenPBR Transmission Roughness vs IOR - Analytic Lights": the runner waits for loader promises (ImportMeshAsync, AppendSceneAsync, LoadAssetContainerAsync) started by createScene. - opaque-clear-alpha keeps the old clear-alpha compositing gate for the 9 tests that write alpha < 1 after an opaque clear; every other test is composited over the canvas background like the browser. - undeclared-name now logs when it is applied. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> Copilot-Session: c46f0590-2707-466b-93c7-bb74316f385a
Contributor
There was a problem hiding this comment.
🟡 Changes recommended
Tracked import rejections are swallowed, allowing rendering to continue after failed model loads.
1 open finding
1 resolved since last review
🧠 Review effort: Balanced
Give feedback about Copilot approvals in this survey to enter a drawing for a $150 gift card.
A rejected tracked import now rejects the createScene wait, so the test takes the existing failure path instead of rendering after a failed load. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> Copilot-Session: c46f0590-2707-466b-93c7-bb74316f385a
bkaradzic-microsoft
enabled auto-merge (squash)
October 8, 2026 21:41
bghgary
approved these changes
Oct 8, 2026
bkaradzic-microsoft
added a commit
that referenced
this pull request
Oct 8, 2026
Follow-up to #1920, addressing #1920 (comment). #1920 moved stray-scene disposal behind the `leak-cleanup` workaround. If a test fails before `currentScene` is assigned (for example, `wait-for-import` rejects for the OpenPBR test), the scene it created stayed registered on the reused engine and could affect later tests. - `cleanupAfterTest` disposes `engine.scenes` after every test again, as it did before #1920. - `leak-cleanup` now covers only the texture-cache release and the Draco reset. Stray scenes no longer count toward its "applied" log, because that disposal is now unconditional. - Updated the workaround description in `validation_native.js` and `Documentation/AddingNewValidationTests.md`. Validated locally on Win32 D3D11 with `Draco Mesh Compression (fallback)`, `GLTF Serializer KHR gpu instancing`, and `OpenPBR Transmission Roughness vs IOR - Analytic Lights`. Co-authored-by: Branimir Karadzic <bkaradzic@users.noreply.github.com> Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> Copilot-Session: 97f1ddbf-b571-4a6c-8cb3-411b37e0d15a
bkaradzic-microsoft
added a commit
to bkaradzic-microsoft/BabylonNative
that referenced
this pull request
Oct 9, 2026
Retain the accepted 720-scene catalog with 715 enabled scenes and five exclusions. Preserve every fixture, reference, render count and numerical gate from the pre-merge support stack. Assign validation_native.js workarounds per test as BabylonJS#1920 does: every test ran with every workaround enabled, and each test lists the ones that triggered for it, plus the assignments already upstream. 126 tests list workarounds (wait-for-import 54, wait-for-readiness 34, leak-cleanup 19, prime-effect-layers 15, opaque-clear-alpha 9); undeclared-name is unused. Scene 567 uses wait-for-import instead of its old replace patch. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> Copilot-Session: 60c2ec68-6de1-445d-9fc9-b699db737eae
bkaradzic-microsoft
added a commit
to bkaradzic-microsoft/BabylonNative
that referenced
this pull request
Oct 9, 2026
Retain the accepted 720-scene catalog with 715 enabled scenes and five exclusions. Preserve every fixture, reference, render count and numerical gate from the pre-merge support stack. Assign validation_native.js workarounds per test as BabylonJS#1920 does: every test ran with every workaround enabled, and each test lists the ones that triggered for it, plus the assignments already upstream. 126 tests list workarounds (wait-for-import 54, wait-for-readiness 34, leak-cleanup 19, prime-effect-layers 15, opaque-clear-alpha 9); undeclared-name is unused. Scene 567 uses wait-for-import instead of its old replace patch. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> Copilot-Session: 60c2ec68-6de1-445d-9fc9-b699db737eae
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.


validation_native.jshas workarounds for bugs in the examples (not in Babylon Native), and today they run for every test. This gives each one an ID and runs it only for tests that list it inconfig.json:The
workaroundslists double as the list of examples to fix.wait-for-readinessundeclared-namenameprime-effect-layersleak-cleanupwait-for-importcreateScenewithout awaiting it (was areplacepatch)opaque-clear-alphawait-for-readiness, the runner matches the browser harness: main-sceneexecuteWhenReady, thenrenderCountframes.releaseEffects, hardware scaling,OnPluginActivatedObservable.clear()).opaque-clear-alpha, translucent pixels are always composited over the canvas background, as in the browser.--listprints the IDs as a fifth TSV column.Workaround '<id>' applied for '<title>'whenever a workaround changes what it does.AddingNewValidationTests.mdand the debugging instructions.How tests were assigned
I ran the 371 enabled tests three times (V8/D3D11) with every workaround on for every test, and assigned each test the workarounds that triggered for it. Every assignment triggered in 3/3 runs except "GUI Images in Grid" (1/3).
Notes:
undeclared-namehas no current users. Excluded tests were also checked with--include-excluded, and none raisedname is not defined. The ID is kept for future use.wait-for-importandopaque-clear-alphawere assigned the same way: thereplacepatch's test, and the 9 tests that failed with the alpha gate removed.Validation
ran=371 passed=371 failed=0.