Bug 80684 - Web Inspector: Network panel does not show responses for application/json data
Summary: Web Inspector: Network panel does not show responses for application/json data
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: Web Inspector (Deprecated) (show other bugs)
Version: 528+ (Nightly build)
Hardware: All All
: P2 Normal
Assignee: Vsevolod Vlasov
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2012-03-09 00:57 PST by Dominic Cooney
Modified: 2012-03-11 08:09 PDT (History)
11 users (show)

See Also:


Attachments
Repro. Run serve.py, open inspector network panel, load http://localhost:8000/a, look at requests b and c (1.20 KB, text/x-python-script)
2012-03-09 00:57 PST, Dominic Cooney
no flags Details
Patch (8.01 KB, patch)
2012-03-11 07:10 PDT, Vsevolod Vlasov
pfeldman: review+
Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Dominic Cooney 2012-03-09 00:57:45 PST
Created attachment 131003 [details]
Repro. Run serve.py, open inspector network panel, load http://localhost:8000/a, look at requests b and c

The Web Inspector Network panel doesn’t show anything in the preview or response tabs for responses with content type application/json.

I reproduced this in WebKit nightly Version 5.1.3 (7534.53.10, r109142) on Mac and Chrome 19.0.1061.1 (Official Build 125213) dev on Mac.

I have attached a repro:

1. Save serve.py and make it executable; run it.
2. Open the Web Inspector and click on the Network tab.
3. Navigate to http://localhost:8000
4. Compare the results for "b", which has content-type text/plain, and "c", which has content-type application/json.

I note per RFC4627 <http://www.ietf.org/rfc/rfc4627.txt> that the MIME type for JSON is application/json.
Comment 1 Vsevolod Vlasov 2012-03-11 07:10:24 PDT
Created attachment 131223 [details]
Patch
Comment 2 Pavel Feldman 2012-03-11 07:49:48 PDT
Comment on attachment 131223 [details]
Patch

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

> Source/WebCore/inspector/NetworkResourcesData.cpp:126
> +static PassRefPtr<TextResourceDecoder> createTextDecoder(const String& mimeType, const String& textEncodingName)

Please make sure the name / signature does not match / resemble the one in InspectorPageAgent.
Comment 3 Vsevolod Vlasov 2012-03-11 08:09:34 PDT
Committed r110393: <http://trac.webkit.org/changeset/110393>