RESOLVED FIXED Bug 67732
[Chromium] Web Inspector: Bug with console.log and popstate/hashchange events
https://bugs.webkit.org/show_bug.cgi?id=67732
Summary [Chromium] Web Inspector: Bug with console.log and popstate/hashchange events
Zach Leatherman
Reported 2011-09-07 14:12:00 PDT
Created attachment 106634 [details] Global i holds the number of times popstate has fired. If I bind a simple event handler to the popstate event with a console.log, it will execute the console.log multiple times per onpopstate event. The onpopstate event fires only once, it just triggers console.log multiple times. Looks like the same for hashchange. Chrome 14.0.835.157 beta-m
Attachments
Global i holds the number of times popstate has fired. (689 bytes, text/html)
2011-09-07 14:12 PDT, Zach Leatherman
no flags
Reduced test case (227 bytes, text/html)
2011-09-27 02:19 PDT, Yury Semikhatsky
no flags
Patch (2.83 KB, patch)
2011-09-27 05:11 PDT, Yury Semikhatsky
pfeldman: review+
Eric Seidel (no email)
Comment 1 2011-09-26 17:05:48 PDT
I'm told Darin is mr. popstate (but I could be misinformed).
Eric Seidel (no email)
Comment 2 2011-09-26 17:06:40 PDT
I see. So this isn't a popstate bug, this is an interaction with the web inspector? In which case, Pavel is your man.
Yury Semikhatsky
Comment 3 2011-09-27 00:35:14 PDT
Looks like a bug in web inspector. After navigation two original messages are printed before the actual PopStateEvent.
Yury Semikhatsky
Comment 4 2011-09-27 02:19:38 PDT
Created attachment 108817 [details] Reduced test case This is a Chromium-specific issue. The problem here is that when back button is pushed we receive OnNavigatingToPendingEntry in the browser and send Detach followed by Attach to the corresponding DevToolsAgent to make sure our front-end is connected to correct RenderViewHost. In case of navigation back to the same URL with a different fragment we probably shouldn't do this as RVH doesn't change in that case.
Yury Semikhatsky
Comment 5 2011-09-27 05:09:28 PDT
Yury Semikhatsky
Comment 6 2011-09-27 05:11:47 PDT
Yury Semikhatsky
Comment 7 2011-09-27 05:39:28 PDT
Yury Semikhatsky
Comment 8 2011-09-27 05:40:57 PDT
Chromium patch will be landed after WebKit r96100 is rolled.
Note You need to log in before you can comment on or make changes to this bug.