-
Notifications
You must be signed in to change notification settings - Fork 3.5k
[ASYNCIFY] Run continuations under callUserCallback #26095
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change | ||
|---|---|---|---|---|
|
|
@@ -9587,7 +9587,7 @@ def test_embind_lib_with_asyncify(self, args): | |||
| '-sINCOMING_MODULE_JS_API=onRuntimeInitialized', | ||||
| ] | ||||
| self.cflags += args | ||||
| self.do_core_test('embind_lib_with_asyncify.cpp') | ||||
| self.do_core_test('embind_lib_with_asyncify.cpp', assert_returncode=NON_ZERO) | ||||
|
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Why does this change?
Collaborator
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. The reason is that because the asyncify continuation are now run in This test explicit has
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. But that delayed throw is handled early in the test, let delayedThrowResult = Module["delayed_throw"]();
assert(delayedThrowResult instanceof Promise);
let err = await delayedThrowResult.then(() => '', err => err.message);
assert(err === 'my message', `"${err}" doesn't contain the expected error`);The rest of the test runs after those lines, and it exits without error?
Collaborator
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. The Line 253 in 48a147b
So its kind of like the node implementation is remember the exit code even though the exception was handled further up. I don't know if this is ideal, but I imagine changing it would be very hard at this point.
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I see. Yeah, probably not worth changing. How about adding a comment in the python file, explaining why we expect the test to fail? Otherwise it is quite surprising I think.
Collaborator
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Agreed |
||||
|
|
||||
| @no_asan('asyncify stack operations confuse asan') | ||||
| @with_asyncify_and_jspi | ||||
|
|
||||
Uh oh!
There was an error while loading. Please reload this page.