Error message property logged as [object ErrorEvent]
See original GitHub issueDo you want to request a feature or report a bug? Bug.
What is the current behavior?
Sometimes (not always) the message
property of the error is logged as [object ErrorEvent]
. I followed the standard implementation of Raven in Angular as described here: https://docs.sentry.io/clients/javascript/integrations/angular/.
What is the expected behavior? To see a normal error message.
Raven 3.17.0 Angular 4.3.1 Webpack build Not using CLI CDN version
Issue Analytics
- State:
- Created 6 years ago
- Reactions:10
- Comments:31 (17 by maintainers)
Top Results From Across the Web
How do I debug a "[object ErrorEvent] thrown" error in my ...
I'm having the same issue and the only info I have to go on is the message: An error was thrown in afterAll....
Read more >ErrorEvent - Web APIs - MDN Web Docs - Mozilla
desktop desktop
Chrome Edge
ErrorEvent Full support. Chrome10. Toggle history Full support. Edge12. Togg...
ErrorEvent() constructor Full support. Chrome16. Toggle history Full support. Edge14. Togg...
Read more >[object ErrorEvent] thrown … again
I keep seeing this error while trying to write Angular tests. ... in a try/catch and logging the error actually helps a great...
Read more >Serialization Error Handling
Error handling is defined through two methods: the Error event on ... Error += delegate(object sender, ErrorEventArgs args) { // only log an...
Read more >Analytics error codes - Firebase - Google
Error Code Cause Value
4 Event parameter value is too long Name of invalid parameter
5 Event has more than 25 parameters None
7 User property...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
Hi, I am getting a lot of these errors
[object Object]
.Angular 4 Chrome 62.0.3202 Raven-js 3.20.1
I found the issue.
ErrorEvent
is not being treated as an error by theisError
util function, which can be found here. For convenience, I’ll paste the function definition also:I did a quick test in my console to see whether or not this function would return true for an
ErrorEvent
, and it did not:isError
is used in thecaptureException
method to determine whether the exception parameter is an error or simply a message.captureException
will send exceptions to the dashboard usingcaptureMessage
if it thinks the exception is not actually an error. In this case, Raven will not compute a stack trace or “process” the exception. It just sends it off as is.Is there any reason we shouldn’t update
isError
to return true forErrorEvent
objects?