Worker is listed in Threads panel after refresh
Categories
(DevTools :: Debugger, defect, P3)
Tracking
(Not tracked)
People
(Reporter: Honza, Unassigned)
References
(Blocks 2 open bugs)
Details
Attachments
(2 files)
STR:
- Open the Toolbox select the Debugger panel
- Load http://janodvarko.cz/tests/debugger/workers/
- Click
Start Worker
in test case#2, the debugger should pause - Reload the page
- Check out the Threads panel, the worker
worker2.js
is still there => BUG
ER: the worker2.js
should not be listed in Threads panel anymore
Honza
Reporter | ||
Comment 1•5 years ago
|
||
Also note that the Watch Expressions panel is out of sync after page reload.
The Main Thread
is selected and globalVariable
expression coming from the worker2.js
shows Just a test
- it should show undefined
.
Honza
Reporter | ||
Updated•5 years ago
|
Comment 2•5 years ago
|
||
The problem here is that when reloading the debugger never detaches from the worker threads on the page. If those workers are paused then they will persist past the reload and be re-attached to, despite the fact they are associated with content that isn't being shown anymore. The best fix here is I think to detach from these dedicated workers before navigating, so that they will resume execution and terminate as expected before the debugger tries to fetch the workers again. This patch also fixes the watch expression problem, which is a similar issue --- the watch expression reducer isn't being reset after navigating.
Comment 3•5 years ago
|
||
Updated•5 years ago
|
Reporter | ||
Updated•5 years ago
|
Comment 4•3 years ago
|
||
Is the patch here still relevant?
Reporter | ||
Comment 5•3 years ago
|
||
Nicolas, can we use the path? Feels a bit obsolete (pre-fission).
Comment 6•3 years ago
|
||
I feel like it wouldn't be too hard to reuse it, but it also feels like this should be handled at the framework level, and the debugger would be notified about the workers being removed through the target command.
Updated•3 years ago
|
Comment 7•3 years ago
|
||
I closed the revision on Phabricator.
Updated•2 years ago
|
Description
•