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.
,
May 8 2017
@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.
,
May 16 2017
Thanks for the report. Looks like a bug in ConsoleViewMessage's tryFormatAsError(). I'll look into it.
,
May 17 2017
,
Jun 21 2017
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...
,
Jun 21 2017
@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).
,
Jun 28 2017
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.
,
Jun 29 2017
Unable to reproduce the expected behavior on TE-End, removing the Needs-Bisect label, as dev luoe@ is looking into it.
,
Dec 7 2017
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 |
|||||||
Comment 1 by kavvaru@chromium.org
, May 8 2017Components: Platform>DevTools
Labels: Needs-Bisect Needs-Feedback
Status: Untriaged (was: Unconfirmed)
97.4 KB
97.4 KB View Download