Skip to content
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

v4 - access to original exception in beforeSend #420

Closed
dadleyy opened this issue Nov 15, 2018 · 2 comments · Fixed by #515
Closed

v4 - access to original exception in beforeSend #420

dadleyy opened this issue Nov 15, 2018 · 2 comments · Fixed by #515
Labels
feature request Request for a new feature

Comments

@dadleyy
Copy link

dadleyy commented Nov 15, 2018

Desired Behavior & Use Case

Currently in v4.x, the beforeSend callback receives a report object that does not include the original exception objects that are associated w/ the report. Having the original error instance included in the report would allow clients to leverage more sophisticated logic when determining whether or not to send the report along to the server. This would enable ember applications to leverage things like isAjaxError.

Related to #43.

@bengourley bengourley added the feature request Request for a new feature label Nov 16, 2018
@bengourley
Copy link
Contributor

This seems like something we can consider. I see how it could be useful for you.

@broofa
Copy link

broofa commented Feb 13, 2019

+1 on this. Specifically, it's not uncommon for 3rd-party libraries to put essential information about errors in ad-hoc properties. Some specific examples I've run into include:

  • @sendgrid/client: error.response.body.errors for errors returned from their service API
  • sequelize: error.original.sql for the raw SQL query, error.errors for data validation errors
  • joi: error.annotate() for validation error details
  • ajv: error.errors for validation error details

Being able to append this information to a bug report would be extremely helpful.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feature request Request for a new feature
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants