A page's scroll handler runs while the debugger is paused
Categories
(DevTools :: Debugger, defect)
Tracking
(firefox-esr115 unaffected, firefox-esr140 wontfix, firefox-esr153 wontfix, firefox156 wontfix, firefox157 wontfix, firefox158 affected)
People
(Reporter: florian, Unassigned)
References
(Blocks 2 open bugs, Regression)
Details
(Keywords: regression)
With the debugger paused at a debugger statement, scrolling the page runs the page's own onscroll listener to completion instead of deferring it to the resume. Reproduced locally on a debug build with browser_dbg-scroll-run-to-completion.js un-skipped.
EventLoop.preEnter() sets document.pausedByDevTools, and since Bug 1967931 Document::IsRenderingSuppressed() deliberately returns false in that case, so that highlighters and the inspector still work on a paused page. nsRefreshDriver::Tick therefore keeps running every rendering phase for the document, including RenderingPhase::ScrollSteps, which dispatches queued scroll events to page listeners.
A fix would filter the script-running phases out of RunRenderingPhase for a document with PausedByDevTools(), and re-schedule them on resume so the events are deferred rather than dropped. Whether a resumed page gets one catch-up event is Bug 1968387's open question.
Comment 1•3 days ago
|
||
:emilio, since you are the author of the regressor, bug 1967931, could you take a look? Also, could you set the severity field?
For more information, please visit BugBot documentation.
Comment 2•3 days ago
|
||
This is expected, see also this line in the regressing bug.
We can add a knob, but my understanding is that people wanted debugger pauses to still do things like running CSS animations etc. That also runs script.
In general, I'm opposed to whack-a-mole'ing rendering phases in and out of this behavior. Either the rendering is suppressed (with all phases not running) or it isn't.
Comment 3•2 days ago
|
||
Set release status flags based on info from the regressing bug 1967931
Updated•2 days ago
|
Description
•