-
-
Notifications
You must be signed in to change notification settings - Fork 191
Introduce captureUnhandledException
#608
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should we also update the Monolog handler?
$this->hub->captureException($exception); |
I did thought about that, however, it's not certain that we have a unhandled exception there since a user could also just log an exception like they would use captureException, so it wouldn't be a 100% correct. WDYT? |
Fair point, so let's leave it as is. |
After switching from I'm using v3.1.0 of |
3.1.1 was just released fixing this, sorry for that! |
Thanks! Can confirm the patch fixed it. All exceptions are now reported as unhandled. Even the ones manually logged through Laravel's |
Yes, |
Currently we ask users to implement this in their error handler:
However going forward we are going to change this to:
The old way will still work but the "new way" will make sure exception are correctly marked as unhandled in the Sentry UI.
Fixes #607 (TODO: Docs PR)