Service Worker sources are sometimes missing
Categories
(DevTools :: Debugger, defect, P2)
Tracking
(firefox72 fixed)
Tracking | Status | |
---|---|---|
firefox72 | --- | fixed |
People
(Reporter: Harald, Assigned: bhackett1024)
References
Details
Attachments
(2 files)
What were you doing?
- Open Debugger on platform-status.mozilla.org/ (See
offline-worker.js
in Sources pane and in Threads) - Set a breakpoint in
offline-worker.js
afterself.addEventListener('fetch' …
- Reload
Alternatively, I had a case where the sources didn't show when the Debugger opened but when appeared on reload.
What happened?
offline-worker.js
is gone, no pausing.
What should have happened?
Workers stays there so it can actually be paused upon.
Comment 1•5 years ago
|
||
I don't see offline-worker.js. How can I repro this bug?
Honza
Assignee | ||
Comment 2•5 years ago
|
||
The devtools.debugger.features.windowless-service-workers preference needs to be set as well I think.
Comment 3•5 years ago
•
|
||
I have the pref set and I still don't see anything
Btw. I can see it in Chrome
Honza
Assignee | ||
Comment 4•5 years ago
|
||
The problem here is related to how the debugger behaves when reloading. When reloading, the debugger detaches from all threads it has attached to. After the reload it attempts to reattach to any threads it can find, but this doesn't actually do anything because detaching from a target's thread seems to leave that thread in a more or less permanently detached state.
I think the right fix here is to just not detach from threads when reloading or navigating. I don't think that detaching from the thread really does that much other than mess up future attach attempts, as the worker's target is left alone. Additionally, the debugger needs to move away from managing attaching/detaching to targets (this is the framework's responsibility), and this is a step in that direction.
It's curious that this bug manifests consistently despite us having a test that we can reload when there is a service worker and things will work.
Assignee | ||
Comment 5•5 years ago
|
||
Pushed by bhackett@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/32ee3bf157f4 Don't detach from threads in the debugger when navigating, r=jlast.
Comment 7•5 years ago
|
||
bugherder |
Updated•4 years ago
|
Comment 8•4 years ago
|
||
Confirmed issue with :72.0a1 (2019-11-07) on Windows 10.
Fix verified with 74.0a1 (2020-02-09) - Windows 10 (for now).
However, in trying to verify the fix with RC build - 73.0 I am unable to see the offline-worker.js either.
Any extra pref needed for the Release builds?
Comment 9•4 years ago
|
||
Considering Brian's note, anyone else I could get in touch with to confirm the previous comment?
Updated•2 years ago
|
Description
•