Bug 42560 - Web Inspector: show stack trace for uncaught exceptions
Summary: Web Inspector: show stack trace for uncaught exceptions
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: Yury Semikhatsky
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2010-07-19 05:55 PDT by Yury Semikhatsky
Modified: 2010-07-19 08:20 PDT (History)
8 users (show)

See Also:


Attachments
Patch (23.88 KB, patch)
2010-07-19 06:05 PDT, Yury Semikhatsky
no flags Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Yury Semikhatsky 2010-07-19 05:55:47 PDT
If you throw an exception in your javascript, the web inspector console just 
prints out the description of the extension and doesn't give the stack trace.  
This is particularly unhelpful if the exception is being thrown in a library 
many levels removed from the source of the error in your code.
Comment 1 Yury Semikhatsky 2010-07-19 06:05:14 PDT
Created attachment 61943 [details]
Patch
Comment 2 Pavel Feldman 2010-07-19 08:06:44 PDT
Comment on attachment 61943 [details]
Patch

It looks correct, however, I think we've reached the critical mass of mess in the code. Can we refactor it to make prettier?

My concern is that ScriptCallStack means two different things in different call paths: 
(1) it is used as a top frame + script state for console.log/dir/etc
(2) it is used as a stack container with no access to top frame arguments in regular console messages
Comment 3 Yury Semikhatsky 2010-07-19 08:12:19 PDT
(In reply to comment #2)
> (From update of attachment 61943 [details])
> It looks correct, however, I think we've reached the critical mass of mess in the code. Can we refactor it to make prettier?
> 
> My concern is that ScriptCallStack means two different things in different call paths: 
> (1) it is used as a top frame + script state for console.log/dir/etc
> (2) it is used as a stack container with no access to top frame arguments in regular console messages

Filed a bug for this: https://bugs.webkit.org/show_bug.cgi?id=42570
Comment 4 Yury Semikhatsky 2010-07-19 08:20:12 PDT
Comment on attachment 61943 [details]
Patch

Clearing flags on attachment: 61943

Committed r63662: <http://trac.webkit.org/changeset/63662>
Comment 5 Yury Semikhatsky 2010-07-19 08:20:22 PDT
All reviewed patches have been landed.  Closing bug.