WebKit Bugzilla
New
Browse
Search+
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
RESOLVED FIXED
130044
Web Inspector: Frontend loaded resources from cache are not hidden as expected
https://bugs.webkit.org/show_bug.cgi?id=130044
Summary
Web Inspector: Frontend loaded resources from cache are not hidden as expected
Joseph Pecoraro
Reported
2014-03-10 15:21:32 PDT
* STEPS TO REPRODUCE 1. Load page with source map resources. 2. Inspect page 3. Reload page from inspector (so that source map resources load from cache) => Source map loads show up as page loaded resources instead of getting hidden
Attachments
[PATCH] Proposed Fix
(5.01 KB, patch)
2014-03-10 15:44 PDT
,
Joseph Pecoraro
timothy
: review+
Details
Formatted Diff
Diff
[PATCH] For Landing
(4.82 KB, patch)
2014-03-10 20:37 PDT
,
Joseph Pecoraro
no flags
Details
Formatted Diff
Diff
View All
Add attachment
proposed patch, testcase, etc.
Joseph Pecoraro
Comment 1
2014-03-10 15:22:39 PDT
The issue is that when there is a cached resource load of a frontend loaded resource, WebCore send their resource load notifier delegates with a fresh ResourceRequest, losing out on the flags from the original resource request. For example: lldb> bt * frame #0: WebCore`WebCore::InspectorResourceAgent::willSendRequest ... frame #5: WebCore`WebCore::FrameLoader::loadedResourceFromMemoryCache frame #6: WebCore`WebCore::CachedResourceLoader::shouldContinueAfterNotifyingLoadedFromMemoryCache frame #7: WebCore`WebCore::CachedResourceLoader::requestResource frame #8: WebCore`WebCore::CachedResourceLoader::requestRawResource frame #9: WebCore`WebCore::DocumentThreadableLoader::loadRequest ... frame #15: WebCore`WebCore::XMLHttpRequest::send frame #16: WebCore`WebCore::XMLHttpRequest::send frame #17: WebCore`WebCore::XMLHttpRequest::sendForInspector The XHR send for inspector sets "hiddenFromInspector" on the resource request. Later in requestResource we determine we can reuse the cached resource from the cache, and go through the notifer process with a new request that only copies the URL from the original request.
Joseph Pecoraro
Comment 2
2014-03-10 15:44:45 PDT
Created
attachment 226345
[details]
[PATCH] Proposed Fix Proposed fix. Brady, can we pass this option (hiddenFromInspector) into loadedResourceFromMemoryCache in a cleaner way then this? As far as I can tell, these functions are all only used once in this path, there are no other callers.
Timothy Hatcher
Comment 3
2014-03-10 17:25:57 PDT
Comment on
attachment 226345
[details]
[PATCH] Proposed Fix View in context:
https://bugs.webkit.org/attachment.cgi?id=226345&action=review
> Source/WebCore/loader/FrameLoader.cpp:3002 > newRequest = ResourceRequest(resource->url());
It might just be best if the caller did this. That would remove the dance you have to do.
Joseph Pecoraro
Comment 4
2014-03-10 19:22:23 PDT
Comment on
attachment 226345
[details]
[PATCH] Proposed Fix View in context:
https://bugs.webkit.org/attachment.cgi?id=226345&action=review
>> Source/WebCore/loader/FrameLoader.cpp:3002 >> newRequest = ResourceRequest(resource->url()); > > It might just be best if the caller did this. That would remove the dance you have to do.
I like that idea, seeing that this is only called in one place.
Joseph Pecoraro
Comment 5
2014-03-10 20:37:42 PDT
Created
attachment 226378
[details]
[PATCH] For Landing
WebKit Commit Bot
Comment 6
2014-03-10 21:16:17 PDT
Comment on
attachment 226378
[details]
[PATCH] For Landing Clearing flags on attachment: 226378 Committed
r165427
: <
http://trac.webkit.org/changeset/165427
>
Radar WebKit Bug Importer
Comment 7
2015-11-26 21:33:02 PST
<
rdar://problem/23673692
>
Note
You need to
log in
before you can comment on or make changes to this bug.
Top of Page
Format For Printing
XML
Clone This Bug