New issue
Advanced search Search tips
Note: Color blocks (like or ) mean that a user may not be available. Tooltip shows the reason.

Issue 767393 link

Starred by 11 users

Issue metadata

Status: Fixed
Owner:
Last visit > 30 days ago
Closed: Oct 2017
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: Linux , Windows , Mac
Pri: 1
Type: Bug-Regression



Sign in to add a comment

Preview tab is not automatically parsing JSON and displaying it formatted.

Reported by philip.c...@gmail.com, Sep 21 2017

Issue description

UserAgent: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/61.0.3163.91 Safari/537.36

Steps to reproduce the problem:
1. View an XHR call in the Network Tab
2. Click Preview
3. See how it does not automatically parse the JSON to be presented formatted and pretty like it usually does.

What is the expected behavior?
The JSON should be formatted and collapsible. 

What went wrong?
The JSON is just a text blob.

Did this work before? Yes 60

Chrome version: 61.0.3163.91  Channel: stable
OS Version: 10.0
Flash Version: 

Yeah please see this https://groups.google.com/forum/#!topic/google-chrome-developer-tools/zaphAp4r8zo

That is the post I made about it and someone said file a bug so here I am.
 
dev-tools-ss-01.png
68.7 KB View Download

Comment 2 by sver...@gmail.com, Sep 21 2017

I have the same problem.
Version 61.0.3163.91 (Official Build) (64-bit)
Running on Korora 25 with kerne:  4.12.11-200.fc25.x86_64 
Labels: Needs-Bisect Needs-Triage-M61
This is also reproducible in Mac. See attached screenshots.

Though the headers has the wrong content-type (text/html) instead of the correct (application/json), in v60 it was still correctly formatted.
stable60.png
144 KB View Download
canary63.png
158 KB View Download
XHR_headers.png
124 KB View Download

Comment 5 by caseq@chromium.org, Sep 22 2017

Cc: caseq@chromium.org dgozman@chromium.org eostroukhov@chromium.org pfeldman@chromium.org
Components: -Platform>DevTools Platform>DevTools>Network
Owner: allada@chromium.org
Status: Assigned (was: Unconfirmed)
Cc: sc00335...@techmahindra.com allada@chromium.org
Labels: -Pri-2 -Needs-Bisect hasbisect-per-revision Triaged-ET OS-Linux OS-Mac Pri-1
Owner: eostroukhov@chromium.org
Able to reproduce on latest stable 61.0.3163.100, latest canary 63.0.3222.0 using windows 10, Ubuntu 14.04 and Mac 10.12.6 with the steps mentioned in original comment.

Manual Bisect Info:
================
Good Build:61.0.3143.0 
Bad Build:61.0.3144.0 

You are probably looking for a change made after 483126 (known good), but no later than 483127 (first known bad).
CHANGELOG URL:
  https://chromium.googlesource.com/chromium/src/+log/b9546a7a38d574646e91e92c12d9247378b5bb11..147b1c8545c7b989df376d455642c47e01f40c22

Review URL: https://chromium-review.googlesource.com/552820

Suspecting same from changelog.

@eostroukhov: Please confirm the bug and help in re-assigning if it is not related to your change.

Thanks!

Comment 7 by allada@chromium.org, Sep 26 2017

Owner: allada@chromium.org
Project Member

Comment 8 by bugdroid1@chromium.org, Sep 28 2017

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/2a04495525d82b290a619c4abd62067e9fa79bad

commit 2a04495525d82b290a619c4abd62067e9fa79bad
Author: Nathan Bruer <allada@chromium.org>
Date: Thu Sep 28 23:42:01 2017

[Devtools] Regression: Fixed rendering of HTML and JSON in network

* Fixed bug where network preview would not render JSON if it was
fetched and and had an error code.

* Fixed bug where network preview would try to render as  HTML
agressively if requested via XHR.

R=pfeldman,eostroukhov
BUG= 765286 , 767393 , 763921 

Change-Id: I9a160e50241e406456623469738b0694800ae586
Reviewed-on: https://chromium-review.googlesource.com/687890
Reviewed-by: Pavel Feldman <pfeldman@chromium.org>
Commit-Queue: Blaise Bruer <allada@chromium.org>
Cr-Commit-Position: refs/heads/master@{#505212}
[modify] https://crrev.com/2a04495525d82b290a619c4abd62067e9fa79bad/third_party/WebKit/LayoutTests/http/tests/devtools/network/network-choose-preview-view-expected.txt
[modify] https://crrev.com/2a04495525d82b290a619c4abd62067e9fa79bad/third_party/WebKit/LayoutTests/http/tests/devtools/network/network-choose-preview-view.html
[modify] https://crrev.com/2a04495525d82b290a619c4abd62067e9fa79bad/third_party/WebKit/Source/devtools/front_end/network/RequestPreviewView.js

Comment 9 by allada@chromium.org, Sep 29 2017

Labels: Merge-Request-62
Project Member

Comment 10 by sheriffbot@chromium.org, Sep 29 2017

Labels: -Merge-Request-62 Merge-Review-62 Hotlist-Merge-Review
This bug requires manual review: M62 has already been promoted to the beta branch, so this requires manual review
Please contact the milestone owner if you have questions.
Owners: amineer@(Android), cmasso@(iOS), bhthompson@(ChromeOS), abdulsyed@(Desktop)

For more details visit https://www.chromium.org/issue-tracking/autotriage - Your friendly Sheriffbot
allada@ - can you please provide more explanation for why this is required for M62 merge? Why can it not wait until M63? Since we're 2 weeks away from M62 stable, we're only taking critical and release blocking fixes. 
FYI re: M62 merge and a CM question
CR 767386 (dup of CR 763921) has user comments that (part of this) is already fixed in M62

This is primarily a devTools issue, developers can use Canary/Dev as a workaround.

The other developer WA is to use 'Content-Type: application/json'

CM question: Since the commit fixes 3 CRs, how are users/developers following the other CRs supposed to know to look here (767393) for the M62 Merge discussion?
#11 I am going to push to merge this issue. This is a fairly large regression for us and we would like to get it fixed asap. A large part of the web uses JSON in their XHRs and devtools will render most of them as HTML which is useless for JSON.
 Issue 770629  has been merged into this issue.
Labels: -Merge-Review-62 Merge-Approved-62
Ok Great thanks for more detail. If this has been well tested in Canary, approving merge to M62. (branch:3202)
Cc: krajshree@chromium.org
 Issue 765081  has been merged into this issue.
Project Member

Comment 17 by bugdroid1@chromium.org, Oct 3 2017

Labels: -merge-approved-62 merge-merged-3202
The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/f674b40baf2d44d1b27f33b3ed39e60b2b9169da

commit f674b40baf2d44d1b27f33b3ed39e60b2b9169da
Author: Blaise <allada@chromium.org>
Date: Tue Oct 03 20:17:01 2017

[Devtools] Regression: Fixed rendering of HTML and JSON in network

* Fixed bug where network preview would not render JSON if it was
fetched and and had an error code.

* Fixed bug where network preview would try to render as  HTML
agressively if requested via XHR.

R=pfeldman,eostroukhov
BUG= 765286 , 767393 , 763921 

(cherry picked from commit 2a04495525d82b290a619c4abd62067e9fa79bad)

Change-Id: I9a160e50241e406456623469738b0694800ae586
Reviewed-on: https://chromium-review.googlesource.com/687890
Reviewed-by: Pavel Feldman <pfeldman@chromium.org>
Commit-Queue: Blaise Bruer <allada@chromium.org>
Cr-Original-Commit-Position: refs/heads/master@{#505212}
Reviewed-on: https://chromium-review.googlesource.com/698906
Reviewed-by: Blaise Bruer <allada@chromium.org>
Cr-Commit-Position: refs/branch-heads/3202@{#561}
Cr-Branched-From: fa6a5d87adff761bc16afc5498c3f5944c1daa68-refs/heads/master@{#499098}
[modify] https://crrev.com/f674b40baf2d44d1b27f33b3ed39e60b2b9169da/third_party/WebKit/Source/devtools/front_end/network/RequestPreviewView.js

Cc: keerthan...@techmahindra.com ranjitkan@chromium.org pbomm...@chromium.org
 Issue 766229  has been merged into this issue.
Status: Fixed (was: Assigned)
Labels: TE-Verified-M62 TE-Verified-62.0.3202.45
Verified the fix on Mac 10.12.6, Win-10 and Ubuntu 14.04 using Chrome beta version #62.0.3202.45 as per the comment #0.
Attaching screen shot for reference.
Observed that JSON is formatted and collapsible as expected.
Hence, the fix is working as expected. 
Adding the verified labels.

Thanks...!!
767393.JPG
306 KB View Download

Sign in to add a comment