Closed Bug 1710401 Opened 3 years ago Closed 8 months ago

Performance analysis doesn't work

Categories

(DevTools :: Netmonitor, defect, P2)

defect

Tracking

(firefox-esr102 wontfix, firefox111 wontfix, firefox112 wontfix, firefox113 fixed)

RESOLVED FIXED
113 Branch
Tracking Status
firefox-esr102 --- wontfix
firefox111 --- wontfix
firefox112 --- wontfix
firefox113 --- fixed

People

(Reporter: Honza, Assigned: jdescottes)

References

(Blocks 1 open bug)

Details

(Keywords: regression, Whiteboard: [devtools:relnote])

Attachments

(6 files)

Attached image image.png

STR:

  1. Load any page e.g. google.com
  2. Open DevTools and select the Network panel
  3. Remove all requests (if any) and press the "Analyze" button

AR
The analysis are never finished, the panel says "Please wait..."

ER
See the analysis results

Works in 88 (current release), doesn't work in 90 (nightly)

Honza

QA Whiteboard: [qa-regression-triage]
Attached image devtools_0.gif

Hello Honza! I tried searching for a regression range but it seems that I can reproduce the issue on Windows 10x64 with Firefox 82.0a1 (20200827212940) as well. For me at least the issue is really intermittent. For example sometimes if I click Back and delete the requests again and click on Analyze button again it's sometimes working. Am I doing something different? Or the issue is intermittent only for me? Thank you in advance!

Flags: needinfo?(odvarko)

Thanks Alexandru for the testing and update!
You are doing it right.
I can confirm, it's behaves intermittently.

I tested with a new profile on Win10 + Firefox Nightly.

Honza

Flags: needinfo?(odvarko)

I tried again looking into this but with no luck.
I managed to reproduce the issue with 62.0a1(20180530220105) as well. I reproduced it with older builds but when I ran mozregression on the same builds or open them again the issue is not reproducing anymore. Due to intermittency, I think it's very hard to find a regression range until solid steps are found.

Flags: needinfo?(jdescottes)
Whiteboard: [devtools-triage]

The issue I can reproduce consistently comes from the requests captured in the content process.
First of all they lack a few "*Available" flags, which means the front end thinks responseHeaders and eventTimings are not available for those, and indefinitely waits for those requests to complete.

On top of that, the content-process requests override some data on the resource (eg totalTime is set to 0 at https://searchfox.org/mozilla-central/rev/f9beb753a84aa297713d1565dcd0c5e3c66e4174/devtools/server/actors/resources/network-events-content.js#126-132). But this only affects the resource, and if the network event actor itself is queried for more details, it will not return the overridden value.

Flags: needinfo?(jdescottes)
Whiteboard: [devtools-triage]

The currently attached patch fixes some of the reported issues.

STRs with google.com or lemonde.fr seem to work fine now. However cnn.com still consistently shows empty results, so I'll need to investigate a bit more.

Overall the UI is quite fragile because it waits for all the known requests to be ready:

    const ready =
      requests?.length &&
      requests.every(
        req =>
          req.contentSize !== undefined &&
          req.mimeType &&
          req.responseHeaders &&
          req.status !== undefined &&
          req.totalTime !== undefined
      );

The current patch helps flag image-cache and CSP requests as completed but some requests might still hang in an unfinished state and prevent the panel from ever displaying any data.

Attachment #9325562 - Attachment description: Bug 1710401 - [devtools] WIP: support image cached requests in netmonitor statistics panel → Bug 1710401 - [devtools] Support requests captured in the content process in statistics panel
Assignee: nobody → jdescottes
Status: NEW → ASSIGNED
Pushed by jdescottes@mozilla.com:
https://hg.mozilla.org/integration/autoland/rev/69a979156899
[devtools] Stop using resourceOverrides for content process network requests r=ochameau
https://hg.mozilla.org/integration/autoland/rev/198262a283b9
[devtools] Wait for the load event to display network statistics charts r=devtools-reviewers,ochameau
https://hg.mozilla.org/integration/autoland/rev/03dc5154a78b
[devtools] Add edge case test for netmonitor statistics panel r=ochameau,devtools-reviewers
Status: ASSIGNED → RESOLVED
Closed: 8 months ago
Resolution: --- → FIXED
Target Milestone: --- → 113 Branch
Whiteboard: [devtools:relnote]
You need to log in before you can comment on or make changes to this bug.