Closed
Bug 1490927
Opened 6 years ago
Closed 6 years ago
Network events are received twice from the backend
Categories
(DevTools :: Console, defect, P2)
DevTools
Console
Tracking
(firefox-esr60 unaffected, firefox62 unaffected, firefox63 verified, firefox64 verified)
VERIFIED
FIXED
Firefox 64
Tracking | Status | |
---|---|---|
firefox-esr60 | --- | unaffected |
firefox62 | --- | unaffected |
firefox63 | --- | verified |
firefox64 | --- | verified |
People
(Reporter: Honza, Assigned: ochameau)
References
Details
(Keywords: regression, Whiteboard: dt-fission)
Attachments
(1 file)
46 bytes,
text/x-phabricator-request
|
Honza
:
review+
pascalc
:
approval-mozilla-beta+
|
Details | Review |
All network events (both `networkEvent` and `networkEventUpdate` are received twice.
This can be tested by putting `console.log` into:
https://searchfox.org/mozilla-central/rev/de7676288a78b70d2b9927c79493adbf294faad5/devtools/shared/webconsole/client.js#138
if (!networkInfo) {
return;
}
console.log("Client._onNetworkEventUpdate " +
packet.updateType +
packet.from, packet);
networkInfo.updates.push(packet.updateType);
STR:
1) Load: http://janodvarko.cz/firebug/tests/601/Issue601.htm
2) Open the Toolbox, select the Console panel
3) Open the Browser console.
4) Press the "POST" button on the page to generate XHR
Note, that the problem does happen only if the Browser console is opened.
Honza
Reporter | ||
Comment 1•6 years ago
|
||
@ochameau: Could this be caused by bug 1444132?
Honza
Flags: needinfo?(poirot.alex)
Updated•6 years ago
|
Priority: -- → P2
Comment 2•6 years ago
|
||
Is this a regression?
Assignee | ||
Comment 3•6 years ago
|
||
When opening a web console and a browser console, we instantiate two NetworkMonitor
instances in the same process and they need independant states.
Assignee | ||
Comment 4•6 years ago
|
||
(In reply to Marco Castelluccio [:marco] from comment #2)
> Is this a regression?
Yes, from bug 1444132.
(In reply to Jan Honza Odvarko [:Honza] from comment #0)
> All network events (both `networkEvent` and `networkEventUpdate` are
> received twice.
This is a really stupid mistake... That's because we end up sharing the maps on the prototype here:
https://searchfox.org/mozilla-central/source/devtools/server/actors/network-monitor.js#14-15
_netEvents: new Map(),
_networkEventActorsByURL: new Map(),
I submitted a patch to fix that but it is quite complex to write a test against that as it involves two toolboxes.
Assignee | ||
Comment 5•6 years ago
|
||
Note that because of that, the browser console client wasn't receiving the network-event-update events while the web console was receiving duplicated.
Duplicated events doesn't seem to break anything, while the miss of events in the browser console end up making all request panels (headers, cookies, params....) empty.
It should not affect the web console unless you open the browser console or the browser toolbox.
Reporter | ||
Comment 6•6 years ago
|
||
Comment on attachment 9009662 [details]
Bug 1490927 - Stop sharing maps in NetworkMonitor between all instances. r=Honza
Jan Honza Odvarko [:Honza] has approved the revision.
Attachment #9009662 -
Flags: review+
Comment 7•6 years ago
|
||
Honza, did this have a performance impact that we should track?
Flags: needinfo?(odvarko)
Reporter | ||
Comment 8•6 years ago
|
||
It only happened if the Browser Console was opened, so less impact on average web-def user I guess.
Honza
Flags: needinfo?(odvarko)
Assignee | ||
Comment 9•6 years ago
|
||
Green try (before I addressed eslint):
https://treeherder.mozilla.org/#/jobs?repo=try&revision=709746466436fd06d4de94b29f3793461aa4641e
Comment 10•6 years ago
|
||
Pushed by apoirot@mozilla.com:
https://hg.mozilla.org/integration/autoland/rev/cce1c1845bbc
Stop sharing maps in NetworkMonitor between all instances. r=Honza
Comment 11•6 years ago
|
||
bugherder |
Status: NEW → RESOLVED
Closed: 6 years ago
status-firefox64:
--- → fixed
Resolution: --- → FIXED
Target Milestone: --- → Firefox 64
Comment 12•6 years ago
|
||
Did you want to nominate this for Beta backport?
status-firefox62:
--- → unaffected
status-firefox63:
--- → affected
status-firefox-esr60:
--- → unaffected
Flags: needinfo?(poirot.alex)
Assignee | ||
Comment 13•6 years ago
|
||
Comment on attachment 9009662 [details]
Bug 1490927 - Stop sharing maps in NetworkMonitor between all instances. r=Honza
Approval Request Comment
[Feature/Bug causing the regression]:
fix regression from bug 1444132
[User impact if declined]:
Browser console has empty panels while inspecting network events.
[Is this code covered by automated tests?]:
The browser console feature isn't covered by tests, while the one in regular web console is.
[Has the fix been verified in Nightly?]:
Not by QA.
[Needs manual test from QE? If yes, steps to reproduce]:
There is STR in comment 0.
[List of other uplifts needed for the feature/fix]:
None.
[Is the change risky?]:
No.
[Why is the change risky/not risky?]:
Fixed a naive issue and is covered by many tests in the regular web console.
[String changes made/needed]:
Flags: needinfo?(poirot.alex)
Attachment #9009662 -
Flags: approval-mozilla-beta?
Comment 14•6 years ago
|
||
Comment on attachment 9009662 [details]
Bug 1490927 - Stop sharing maps in NetworkMonitor between all instances. r=Honza
Low risk patch for a P2 devtools bug, baked on nightly for a week, uplift approved for 63 beta 12, thanks.
Attachment #9009662 -
Flags: approval-mozilla-beta? → approval-mozilla-beta+
Comment 15•6 years ago
|
||
bugherder uplift |
Updated•6 years ago
|
Flags: qe-verify+
QA Contact: nchevobbe
Updated•6 years ago
|
Assignee: poirot.alex → nobody
Updated•6 years ago
|
Assignee: nobody → poirot.alex
QA Contact: nchevobbe
Comment 16•6 years ago
|
||
Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:64.0) Gecko/20100101 Firefox/64.0
I was able to reproduce the mentioned behavior on Windows 10 x64 and Windows 7 using Nightly (20180919003800) and Beta 63.0b11 builds with the steps from comment 0. When opening the Response tab of the appropriate XHR entry additional request is received.
The issue is verified as fixed on the latest Nightly build (20181010100123) and Beta 63.0b13. When opening the Response tab of the appropriate XHR entry additional request is not received any more.
Status: RESOLVED → VERIFIED
Flags: qe-verify+
Comment 17•6 years ago
|
||
Mozilla/5.0 (X11; Linux x86_64; rv:64.0) Gecko/20100101 Firefox/64.0 20181010100123
This report had been verified on OS X 10.13.6 and Ubuntu 18.04 as well using the latest Nightly and Beta 63.0b13 builds.
Assignee | ||
Updated•6 years ago
|
Whiteboard: dt-fission
You need to log in
before you can comment on or make changes to this bug.
Description
•