workers with { type: module} should not throw if module workers are disabled
Categories
(Core :: DOM: Workers, defect, P3)
Tracking
()
Tracking | Status | |
---|---|---|
firefox-esr102 | --- | unaffected |
firefox110 | --- | unaffected |
firefox111 | + | verified |
firefox112 | --- | verified |
People
(Reporter: yulia, Assigned: yulia)
References
Details
Attachments
(3 files)
Assignee | ||
Updated•2 years ago
|
Assignee | ||
Updated•2 years ago
|
I am not sure what the new behavior will be, but currently worker module support is detected by checking if the type
property is accessed at all.
See https://stackoverflow.com/questions/62954570/javascript-feature-detect-module-support-for-web-workers for example.
So if the new behavior will read the type
property but not throw, current implementations might assume that type: module
is supported.
Assignee | ||
Comment 2•2 years ago
|
||
Thanks for the heads up. I tested the usecase there and it does work with the changes. Let me know if you run into any issues on beta.
Assignee | ||
Comment 3•2 years ago
|
||
Assignee | ||
Comment 4•2 years ago
|
||
This patch updates several tests which were incorrectly updated with the flag caused attempts to
create modules to throw. Now accessing the type no longer happens, and should address web compat
concerns.
I was surprised by which tests were turned on, but I verified them against searchfox and the tests
that were updated as part of the workers work, and this seems correct.
Depends on D170920
Comment 6•2 years ago
|
||
Moving tracking from 1818732 to here.
:yulia, please nominate for beta uplift request when this lands in central and is good to uplift.
This week is the final beta week for 111, with the last beta build on Thursday 2022-03-02
Comment 8•2 years ago
|
||
Backed out for failures on disabled-by-permissions-policy-cross-origin.https
- backout: https://hg.mozilla.org/integration/autoland/rev/5444176cc401026bd1493a1152153114cfcde089
- push: https://treeherder.mozilla.org/jobs?repo=autoland&group_state=expanded&revision=faa460b11c9cf0310c740654e1b44174c7184b58
- failure log: https://treeherder.mozilla.org/logviewer?job_id=407189526&repo=autoland&lineNumber=22269
[task 2023-02-27T22:34:29.876Z] 22:34:29 INFO - TEST-FAIL | /web-share/disabled-by-permissions-policy-cross-origin.https.sub.html | share() is disabled explicitly by permissions policy for cross-origin iframe - assert_equals: expected "NotAllowedError" but got "Error"
[task 2023-02-27T22:34:29.876Z] 22:34:29 INFO - @https://web-platform.test:8443/web-share/disabled-by-permissions-policy-cross-origin.https.sub.html:66:20
[task 2023-02-27T22:34:29.876Z] 22:34:29 INFO - TEST-UNEXPECTED-FAIL | /web-share/disabled-by-permissions-policy-cross-origin.https.sub.html | share() not allowed, as only allowed to share with self - assert_equals: expected "NotAllowedError" but got "Error"
[task 2023-02-27T22:34:29.876Z] 22:34:29 INFO - @https://web-platform.test:8443/web-share/disabled-by-permissions-policy-cross-origin.https.sub.html:76:20
[task 2023-02-27T22:34:29.877Z] 22:34:29 INFO - ...
[task 2023-02-27T22:34:29.877Z] 22:34:29 INFO - TEST-OK | /web-share/disabled-by-permissions-policy-cross-origin.https.sub.html | took 2511ms
Comment 10•2 years ago
|
||
The bug is marked as tracked for firefox111 (beta). We have limited time to fix this, the soft freeze is in 9 days. However, the bug still has low priority and has low severity.
:jstutte, could you please increase the priority and increase the severity for this tracked bug? If you disagree with the tracking decision, please talk with the release managers.
For more information, please visit auto_nag documentation.
Assignee | ||
Comment 11•2 years ago
|
||
Comment 12•2 years ago
|
||
bugherder |
https://hg.mozilla.org/mozilla-central/rev/428c468be1f9
https://hg.mozilla.org/mozilla-central/rev/a15b3da16984
Assignee | ||
Comment 13•2 years ago
•
|
||
Comment on attachment 9319720 [details]
Bug 1818447 - Remove references to type() if modules pref is off; r=jonco
Beta/Release Uplift Approval Request
- User impact if declined: There will be web compat breakage and some sites using workers will not work.
- Is this code covered by automated tests?: Yes
- Has the fix been verified in Nightly?: No
- Needs manual test from QE?: Yes
- If yes, steps to reproduce: This website should work without breakage https://web.dilato.app (see 1818732) and this script should return "false" on beta: https://stackoverflow.com/questions/62954570/javascript-feature-detect-module-support-for-web-workers
- List of other uplifts needed: None
- Risk to taking this patch: Low
- Why is the change risky/not risky? (and alternatives if risky): There is some risk that some webcompat is still missing, but this hopefully got everything.
- String changes made/needed:
- Is Android affected?: Yes
Assignee | ||
Updated•2 years ago
|
Assignee | ||
Updated•2 years ago
|
Comment 14•2 years ago
|
||
Comment on attachment 9319720 [details]
Bug 1818447 - Remove references to type() if modules pref is off; r=jonco
Approved for 111.0b8
Comment 15•2 years ago
|
||
bugherder uplift |
https://hg.mozilla.org/releases/mozilla-beta/rev/5eae4541365b
https://hg.mozilla.org/releases/mozilla-beta/rev/a0909e1e0365
Updated•2 years ago
|
Comment 16•2 years ago
•
|
||
Reproduced the issue with 111.0b7 on Windows 10x64. The https://web.dilato.app/ webpage is not loaded and the https://stackoverflow.com/questions/62954570/javascript-feature-detect-module-support-for-web-workers script returns true
value.
The issue is verified fixed with Firefox 111.0b8 on Windows 10x64, macOS 12 and Ubuntu 20.04. The https://web.dilato.app/webpage is correctly opened and the script returns false
value.
On Firefox Nightly 112.0a1 (2023-02-03) the https://web.dilato.app/ webpage is correctly opened but the returned valued when running the script is true
. Is this the expected behavior for Nightly? Thank you in advance!
Assignee | ||
Comment 17•2 years ago
|
||
On Firefox Nightly 112.0a1 (2023-02-03) the https://web.dilato.app/ webpage is correctly opened but the returned valued when running the script is true. Is this the expected behavior for Nightly? Thank you in advance!
yes, this is expected as module workers are turned on by default on nightly for testing and fuzzing. Thanks for the QA work!
Comment 18•2 years ago
|
||
(In reply to Yulia Startsev [:yulia] from comment #17)
On Firefox Nightly 112.0a1 (2023-02-03) the https://web.dilato.app/ webpage is correctly opened but the returned valued when running the script is true. Is this the expected behavior for Nightly? Thank you in advance!
yes, this is expected as module workers are turned on by default on nightly for testing and fuzzing. Thanks for the QA work!
Thank you! Closing this per the above comments.
Description
•