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

Issue 719204 link

Starred by 1 user

Issue metadata

Status: Archived
Owner:
Closed: Dec 2017
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: Windows
Pri: 2
Type: Bug



Sign in to add a comment

DevTools: Console.error with 'at' duplicates line in input message

Reported by cow...@bbs.darktech.org, May 7 2017

Issue description

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

Steps to reproduce the problem:
1. Invoke:

console.warn(new Error("line1\n" +
  " at line2"));
2. Developer console will show:

Error: line1
 at line2
 at line2
    at <anonymous>

What is the expected behavior?
" at line2" should only show up once

What went wrong?
" at line2" shows up twice

Did this work before? N/A 

Does this work in other browsers? N/A

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

This issue only happens when outputting an Error, and further only if the message contains the sequence " at".

Anytime I output stack-traces coming back from the server, and/or embed stack-traces in the Error message I get so much duplicate output it is hard to read.
 
Cc: kavvaru@chromium.org
Components: Platform>DevTools
Labels: Needs-Bisect Needs-Feedback
Status: Untriaged (was: Unconfirmed)
Able to reproduce the issue on windows 7 using chrome version 58.0.3029.96.
Observed at line is displayed 2 times.
This is observed from M45 builds.But in M40 its is showing different output.
cowwoc@Could you please once check the attached screen shot and confirm shall i consider this as good behaviour?Please update the thread to triage the issue from our end.

Thanks,
719204.png
97.4 KB View Download
@kavvaru,

Neither version is behaving like I expect.

Version 58 duplicates the input message.
version 45 strips newline characters from the input message.

I am expect the output message to be identical to the input message.

Comment 3 by l...@chromium.org, May 16 2017

Labels: -Needs-Feedback
Owner: l...@chromium.org
Status: Assigned (was: Untriaged)
Summary: DevTools: Console.error with 'at' duplicates line in input message (was: Console.* duplicates input message)
Thanks for the report.  Looks like a bug in ConsoleViewMessage's tryFormatAsError().  I'll look into it.

Comment 4 by ajha@chromium.org, May 17 2017

Labels: Needs-Triage-M58
Labels: Needs-Feedback
 Tested this issue on Mac 10.12.5 with chrome #43.0.2316.0 and observed the different behavior

cowwoc@ Could look into the attached screenshot and confirm that this is the expected behavior of this issue.

Thank You...
719204.png
89.1 KB View Download
@kkaluri,

While the behavior you are seeing is different than the original problem ("at line 2" is no longer duplicated) it is still not the desired behavior as the newlines are being stripped out (before the JSON output).

Comment 7 by l...@chromium.org, Jun 28 2017

Labels: -Needs-Feedback -Needs-Triage-M58
I can also confirm that this behavior is not expected.  It looks like the duplicated 'at...' isn't inserted on the frontend side.  I'll look into the V8 side.
Labels: -Needs-Bisect
Unable to reproduce the expected behavior on TE-End, removing the Needs-Bisect label, as dev luoe@ is looking into it.

Comment 9 by l...@chromium.org, Dec 7 2017

Status: Archived (was: Assigned)
After discussing with kozy@ offline, the problem lies in our parsing of the description, and there wasn't a simple solution to resolving user-generated text that looks like trace text.

This request has been open for awhile, and with our current priorities, it does not seem like it will be fixed soon.  Archiving this for now.

Sign in to add a comment