Closed Bug 1656405 Opened 5 years ago Closed 1 year ago

DevTools netmonitor should display requests for cached stylesheets

Categories

(DevTools :: Netmonitor, defect, P2)

defect

Tracking

(firefox-esr68 unaffected, firefox-esr78 unaffected, firefox79 wontfix, firefox80 wontfix, firefox81 wontfix, firefox82 fix-optional)

RESOLVED DUPLICATE of bug 1916960
Tracking Status
firefox-esr68 --- unaffected
firefox-esr78 --- unaffected
firefox79 --- wontfix
firefox80 --- wontfix
firefox81 --- wontfix
firefox82 --- fix-optional

People

(Reporter: daisuke, Unassigned)

References

(Blocks 2 open bugs, Regression)

Details

(Keywords: regression)

STRs:

ER: Netmonitor displays all stylesheets that the document has.
AR: Netmonitor does not display any stylesheets.

I investigated a bit using mozregression.
It seems this happens since https://phabricator.services.mozilla.com/D79394 was applied.
The bug is https://bugzilla.mozilla.org//show_bug.cgi?id=1599160

Since Bug 1599160 started caching stylesheet across documents, I wonder what the netmonitor should do here? If the stylesheet is effectively cached and there is no request, should we still show an entry? Maybe with a different status?

And for the record, if you check "disable cache" the stylesheets will be fetched as usual.

See Also: → 1599160

I'm not sure which behavior those cached stylesheets follow for various reload/navigation actions. Particularly F5 vs regular navigation.

For cached JS and images:

  • when navigating to the page, the requests are skipped.
  • when using F5 we will still issue a request, read the content from the cache and mark the request as cached

For the new caching mechanism of parsed stylesheets it seems that we always skip the request, even when pressing F5.

Emilio: do you know if we should try to align the caching behavior for parsed stylesheets to other resources. Which I guess would mean bypassing the cache on F5?

Flags: needinfo?(emilio)

Emilio: do you know if we should try to align the caching behavior for parsed stylesheets to other resources. Which I guess would mean bypassing the cache on F5?

That's what shift-reloading is for, isn't it? I don't think the behavior on navigation is what you describe for other resources. How were you navigating, just using back / forward buttons? If so, that hits the bfcache, which is different from a regular navigation.

I think for regular navigations all scripts and images should hit the network layer. If so, no, we don't want to move in that direction, quite the opposite actually. We have plans to unify subresource loads, but they're likely to work more like stylesheets do.

Flags: needinfo?(emilio)

Not sure what I was thinking this morning, but yes you're right we always hit the network layer.

Severity: -- → S3
Keywords: regression
Priority: -- → P2
Regressed by: 1599160
Has Regression Range: --- → yes

Set release status flags based on info from the regressing bug 1599160

A new notification from the CSS loader will be helpful here

Depends on: 1884876
Duplicate of this bug: 1884877
Summary: Netmonitor does not show any stylesheets when reloading document → DevTools netmonitor should display requests for cached stylesheets
Depends on: 1919218

I think this was effectively fixed by Bug 1916960, even though cached stylesheets now show up with a -1 B size which might be confusing. Maybe this is being addressed by Bug 1915626 though?

Status: NEW → RESOLVED
Closed: 1 year ago
Duplicate of bug: 1916960
Resolution: --- → DUPLICATE
You need to log in before you can comment on or make changes to this bug.