WebKit Bugzilla
New
Browse
Search+
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
RESOLVED FIXED
272967
messageerror event doesn't fire on ServiceWorkerGlobalScope
https://bugs.webkit.org/show_bug.cgi?id=272967
Summary
messageerror event doesn't fire on ServiceWorkerGlobalScope
Philip Jägenstedt
Reported
2024-04-19 02:30:07 PDT
Disclaimer: I'm not totally sure about the root cause here, but something needs fixing either in WebKit, WPT, or BCD. In BCD, the messageerror event for ServiceWorkerGlobalScope is marked as partially supported in Safari, because the event never fires:
https://github.com/mdn/browser-compat-data/blob/7752b0a038a04ee47f112e696706bd53a589b0c6/api/ServiceWorkerGlobalScope.json#L617
That refers to
https://bugs.webkit.org/show_bug.cgi?id=171216
, which is closed as fixed. But from the patch it's not easy to tell if the event actually fires now or not. Turning to WPT, this test failure suggests that the event doesn't fire:
https://wpt.fyi/results/html/infrastructure/safe-passing-of-structured-data/shared-array-buffers/window-serviceworker-failure.https.html?run_id=5176510071177216&run_id=5153332145946624&run_id=5195972581261312&run_id=5076778648862720
The failure message points to this line of the test being reached:
https://github.com/web-platform-tests/wpt/blob/1cafd038c989f47a1e136844d09ca85a06f85ce0/html/infrastructure/safe-passing-of-structured-data/shared-array-buffers/resources/serviceworker-failure.js#L16C27-L16C55
So my best guess is that WebKit doesn't fire the messageerror event on ServiceWorkerGlobalScope, and instead fires a message event with data being set to null.
Attachments
Add attachment
proposed patch, testcase, etc.
Radar WebKit Bug Importer
Comment 1
2024-04-26 02:31:17 PDT
<
rdar://problem/127104436
>
Ahmad Saleem
Comment 2
2024-04-26 03:02:14 PDT
We do have following FIXME: FIXME: Add support for messageerror event when message deserialization fails.
https://searchfox.org/wubkat/rev/53d24706292c592556c5991a08e75e3066495105/Source/WebCore/workers/service/context/ServiceWorkerThread.cpp#149
youenn fablet
Comment 3
2024-05-01 01:48:48 PDT
Pull request:
https://github.com/WebKit/WebKit/pull/27974
youenn fablet
Comment 4
2024-05-01 01:49:23 PDT
Submitted web-platform-tests pull request:
https://github.com/web-platform-tests/wpt/pull/46003
EWS
Comment 5
2024-05-06 10:02:51 PDT
Committed
278408@main
(fddda893fc92): <
https://commits.webkit.org/278408@main
> Reviewed commits have been landed. Closing PR #27974 and removing active labels.
Note
You need to
log in
before you can comment on or make changes to this bug.
Top of Page
Format For Printing
XML
Clone This Bug