Bug 178098 - Web Inspector: Network Tab - Show initially loaded resources even if network info not logged
Summary: Web Inspector: Network Tab - Show initially loaded resources even if network ...
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: Web Inspector (show other bugs)
Version: WebKit Nightly Build
Hardware: All All
: P2 Normal
Assignee: Joseph Pecoraro
URL:
Keywords: InRadar
Depends on:
Blocks:
 
Reported: 2017-10-09 15:43 PDT by Joseph Pecoraro
Modified: 2017-10-11 01:00 PDT (History)
4 users (show)

See Also:


Attachments
[IMAGE] Table - Inspector Was Open + Reload (139.67 KB, image/png)
2017-10-09 15:59 PDT, Joseph Pecoraro
no flags Details
[IMAGE] Table - Inspector Just Opened (113.63 KB, image/png)
2017-10-09 16:00 PDT, Joseph Pecoraro
no flags Details
[PATCH] Proposed Fix (6.94 KB, patch)
2017-10-09 16:00 PDT, Joseph Pecoraro
hi: review+
Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Joseph Pecoraro 2017-10-09 15:43:54 PDT
Network Tab - Show initially loaded resources even if network info not logged

When just opening Web Inspector it is often weird that the Network table is empty when the page has some resources.

Lets try including all of the page resources in the Table even though they don't have networking data.
Comment 1 Joseph Pecoraro 2017-10-09 15:44:02 PDT
<rdar://problem/34073529>
Comment 2 Joseph Pecoraro 2017-10-09 15:59:58 PDT
Created attachment 323234 [details]
[IMAGE] Table - Inspector Was Open + Reload
Comment 3 Joseph Pecoraro 2017-10-09 16:00:21 PDT
Created attachment 323235 [details]
[IMAGE] Table - Inspector Just Opened
Comment 4 Joseph Pecoraro 2017-10-09 16:00:59 PDT
Created attachment 323236 [details]
[PATCH] Proposed Fix
Comment 5 Devin Rousso 2017-10-09 17:38:41 PDT
Comment on attachment 323236 [details]
[PATCH] Proposed Fix

View in context: https://bugs.webkit.org/attachment.cgi?id=323236&action=review

r=me.  Would like to see another patch tho, specifically for the ChangeLog fixes.

> Source/WebInspectorUI/ChangeLog:12
> +        So treat hasResposne 

Oops. :P

> Source/WebInspectorUI/ChangeLog:23
> +        While this path is not taken pre-table, change this so that if it is
> +        that the resouce is not lost and is instead a pending insertion.

"so that if it is that" is a bit awkward :/

> Source/WebInspectorUI/UserInterface/Models/Resource.js:656
> +        return !isNaN(this._statusCode) || this._finished;

Will this cause problems with WI.ResourceHeadersContentView (or WI.ResourceTimelineDataGridNode)?

> Source/WebInspectorUI/UserInterface/Views/NetworkTableContentView.js:105
> +        WI.frameResourceManager.addEventListener(WI.FrameResourceManager.Event.MainFrameDidChange, this._mainFrameDidChange, this);

Can we move this to an `initialLayout()`?  The other event listeners too?
Comment 6 Joseph Pecoraro 2017-10-09 18:08:21 PDT
Comment on attachment 323236 [details]
[PATCH] Proposed Fix

View in context: https://bugs.webkit.org/attachment.cgi?id=323236&action=review

>> Source/WebInspectorUI/UserInterface/Models/Resource.js:656
>> +        return !isNaN(this._statusCode) || this._finished;
> 
> Will this cause problems with WI.ResourceHeadersContentView (or WI.ResourceTimelineDataGridNode)?

They have been updated.

>> Source/WebInspectorUI/UserInterface/Views/NetworkTableContentView.js:105
>> +        WI.frameResourceManager.addEventListener(WI.FrameResourceManager.Event.MainFrameDidChange, this._mainFrameDidChange, this);
> 
> Can we move this to an `initialLayout()`?  The other event listeners too?

That would be too late.
Comment 7 Joseph Pecoraro 2017-10-11 01:00:15 PDT
<https://trac.webkit.org/changeset/223170/webkit>