During page refresh, breakpoints do not work in OnUnload or BeforeUnload event handler code
Reported by
orlando....@gmail.com,
Jan 15 2018
|
||
Issue descriptionUserAgent: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/63.0.3239.132 Safari/537.36 Steps to reproduce the problem: 1. (JS) Attach an event handler function to the OnUnload or BeforeUnload events. 2. Place a breakpoint in those event handler function code. 3. Press F5 or refresh button in the page. What is the expected behavior? It executes some code, stops in the breakpoint. What went wrong? It did not stoped in the breakpoint and instead finalized the code execution and did the refresh. Did this work before? N/A Chrome version: 63.0.3239.132 Channel: stable OS Version: 10.0 Flash Version: (If you, instead of a refresh, just close the tab, the breakpoint works correctly)
,
Jan 15 2018
Could you provide sample page?
,
Jan 16 2018
I would feel embarrased if I am a paid coder asking a third one for a basic code example to test your own app. Here you are. (BTW, the devtools have too many bugs and annoyances, but it is a luck for google that firefox devtools are much much worse) (It is a pity we do not have firebug).
,
Jan 16 2018
The capture
,
Jan 17 2018
Thanks for repro. It is actually feature. As soon as you pressed reload we ignore all breakpoints before page reloaded. It is useful all the time when you have a lot of breakpoints and need to reload page to restart debugging session. Workaround: instead of pressing reload button you can navigate to the same url using omnibox then all breakpoint will work as expected.
,
Jan 17 2018
If that is the case you should notificate it in the GUI and give us an alternative way to refresh with breakpoints. Maybe a checkbox.
,
Jan 22 2018
Is going to be a fix for this bug? |
||
►
Sign in to add a comment |
||
Comment 1 by krajshree@chromium.org
, Jan 15 2018