WebKit Bugzilla
Attachment 360131 Details for
Bug 193832
: Web Inspector: show uncaught exception view for unhandled promise rejections
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Requests
|
Help
|
New Account
|
Log In
Remember
[x]
|
Forgot Password
Login:
[x]
[patch]
Patch
bug-193832-20190125110920.patch (text/plain), 1.97 KB, created by
Devin Rousso
on 2019-01-25 11:09:20 PST
(
hide
)
Description:
Patch
Filename:
MIME Type:
Creator:
Devin Rousso
Created:
2019-01-25 11:09:20 PST
Size:
1.97 KB
patch
obsolete
>diff --git a/Source/WebInspectorUI/ChangeLog b/Source/WebInspectorUI/ChangeLog >index 1aadbdeb19807321e0bd7438b5255ca64d18153e..da02207d5ac0fb7dccb3304e4907fb4307187834 100644 >--- a/Source/WebInspectorUI/ChangeLog >+++ b/Source/WebInspectorUI/ChangeLog >@@ -1,3 +1,13 @@ >+2019-01-25 Devin Rousso <drousso@apple.com> >+ >+ Web Inspector: show uncaught exception view for unhandled promise rejections >+ https://bugs.webkit.org/show_bug.cgi?id=193832 >+ >+ Reviewed by NOBODY (OOPS!). >+ >+ * UserInterface/Debug/UncaughtExceptionReporter.js: >+ (handleUnhandledPromiseRejection): Added. >+ > 2019-01-25 Devin Rousso <drousso@apple.com> > > Web Inspector: improve invalid Audit/Recording JSON error messages >diff --git a/Source/WebInspectorUI/UserInterface/Debug/UncaughtExceptionReporter.js b/Source/WebInspectorUI/UserInterface/Debug/UncaughtExceptionReporter.js >index 3f8c8688ca2061f05f56a3e2fc37f92e2d26b530..0283bf5f7c579654070d189cbd8d81b8c5531e71 100644 >--- a/Source/WebInspectorUI/UserInterface/Debug/UncaughtExceptionReporter.js >+++ b/Source/WebInspectorUI/UserInterface/Debug/UncaughtExceptionReporter.js >@@ -82,6 +82,16 @@ function handleUncaughtException(event) { > }); > } > >+function handleUnhandledPromiseRejection(event) { >+ handleUncaughtExceptionRecord({ >+ message: event.reason.message, >+ url: urlLastPathComponent(event.reason.sourceURL), >+ lineNumber: event.reason.line, >+ columnNumber: event.reason.column, >+ stack: event.reason.stack, >+ }); >+} >+ > function handleUncaughtExceptionRecord(exceptionRecord) { > try { > if (!WI.settings.enableUncaughtExceptionReporter.value) >@@ -288,6 +298,7 @@ Document any additional information that might be useful in resolving the proble > } > > window.addEventListener("error", handleUncaughtException); >+window.addEventListener("unhandledrejection", handleUnhandledPromiseRejection); > window.handlePromiseException = window.handleInternalException = handleError; > > })();
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Formatted Diff
|
Diff
Attachments on
bug 193832
: 360131