WebKit Bugzilla
New
Browse
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
NEW
117773
DOMException toString can serialize more useful information
https://bugs.webkit.org/show_bug.cgi?id=117773
Summary
DOMException toString can serialize more useful information
Ryosuke Niwa
Reported
2013-06-18 20:15:42 PDT
Consider merging
https://chromium.googlesource.com/chromium/blink/+/4010ed524b9d6348a76567b55fbe1a756a6f35ef
DOMException toString is not correct We used to print: "Error: HIERARCHY_REQUEST_ERR: DOM Exception 3" Now we print a more useful message: "HierarchyRequestError: The operation would yield an incorrect node tree." that is: `${error.name}: ${error.message}`
Attachments
Add attachment
proposed patch, testcase, etc.
Alexey Proskuryakov
Comment 1
2013-06-19 10:08:57 PDT
So, Chromium no longer prints the exception code, yet it prints arbitrary text from exception description that may or may not be relevant to the actual reason this particular exception was raised for? I don't think that it's an improvement overall.
Timothy Hatcher
Comment 2
2013-06-19 11:27:00 PDT
I think some description is nice. I've had to search for DOM exception codes one to many times. I agree the exception code should still be in there.
Erik Arvidsson
Comment 3
2013-06-19 11:35:31 PDT
The exception code is deprecated. Use the name property instead. Most new exceptions have the code set to 0. AP: The error messages could definitely use some improvements. The long term goal was to allow the error message to be more specific based on were it was being set/thrown.
Note
You need to
log in
before you can comment on or make changes to this bug.
Top of Page
Format For Printing
XML
Clone This Bug