Repository navigation
Fix the status message for counted main loop blockers - #28177
Merged
Merged
Conversation
MainLoop.updateStatus() passed a template literal without its `$` signs
to Module.setStatus, so a page saw the text
`{message} ({expected - remaining}/{expected})` instead of, for example,
`Please wait... (1/2)`.
Fixes emscripten-core#26076
There was a problem hiding this comment.
Code Review
This pull request fixes a bug in src/lib/libeventloop.js where string interpolation syntax was incorrect, preventing the status message from correctly displaying the progress of main loop blockers. It also adds a new test test_emscripten_main_loop_blocker_status in test/test_other.py to verify that the blocker status is correctly formatted and displayed. There are no review comments, so I have no feedback to provide.
sbc100
approved these changes
Nov 5, 2026
sbc100
enabled auto-merge (squash)
November 5, 2026 16:22
The status message template now interpolates its values, so the minified JS in test_codesize_hello_dylink_all is 27 bytes smaller.
auto-merge was automatically disabled
November 5, 2026 16:50
Head branch was pushed to by a user without write access
Contributor
Author
|
Merged main and updated test_codesize_hello_dylink_all.json: with the template literal fixed, the minified JS is 27 bytes smaller, which is what the Codesize Checks job flagged. |
sbc100
enabled auto-merge (squash)
November 5, 2026 16:51
1 task
sbc100
pushed a commit
that referenced
this pull request
Nov 9, 2026
…28207) For a name that is not exported, `emscripten_get_exported_function`: - with `ASSERTIONS`, printed `No exported function found by name "{exportedFunc}"`: the template literal had no `$`, and `exportedFunc` is always undefined at that point. It now prints the name that was looked up. - on wasm64, threw `Cannot convert undefined to a BigInt`: the function fell off the end and returned `undefined`, which the pointer return wrapper passes to `BigInt`. It now returns 0. `core/test_get_exported_function.cpp` now also looks up a missing name and expects NULL, and the test checks the message in unoptimized modes (where `ASSERTIONS` is on by default). Without the fix it fails in core0 (message) and in wasm64 and wasm64_O2 (TypeError). Follow-up to #28177.
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.
MainLoop.updateStatus()passed a template literal without its$signs toModule.setStatus, so while counted main loop blockers ran, a page saw the text{message} ({expected - remaining}/{expected})instead of, for example,Please wait... (1/2).The new
other.test_emscripten_main_loop_blocker_statusruns two counted blockers with asetStatusthat prints each status. It fails without the fix.Fixes #26076