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

Fix: Capture Callback Exceptions #990

Merged
merged 18 commits into from
Sep 12, 2022
Merged

Conversation

denrase
Copy link
Collaborator

@denrase denrase commented Aug 31, 2022

📜 Description

Capture and log exceptions thrown in callbacks provided users.

💡 Motivation and Context

All exceptions should be caught and handled gracefully.

Relates to getsentry/team-mobile#21

💚 How did you test it?

Unit tests.

📝 Checklist

  • I reviewed submitted code
  • I added tests to verify changes
  • I updated the docs if needed
  • All tests passing
  • No breaking changes

@denrase denrase marked this pull request as ready for review August 31, 2022 10:12
CHANGELOG.md Outdated Show resolved Hide resolved
dart/test/hub_test.dart Outdated Show resolved Hide resolved
dart/lib/src/hub.dart Outdated Show resolved Hide resolved
@codecov-commenter
Copy link

codecov-commenter commented Sep 5, 2022

Codecov Report

Base: 89.47% // Head: 91.14% // Increases project coverage by +1.66% 🎉

Coverage data is based on head (1162126) compared to base (d90ceb9).
Patch has no changes to coverable lines.

Additional details and impacted files
@@            Coverage Diff             @@
##             main     #990      +/-   ##
==========================================
+ Coverage   89.47%   91.14%   +1.66%     
==========================================
  Files         106        9      -97     
  Lines        3326      192    -3134     
==========================================
- Hits         2976      175    -2801     
+ Misses        350       17     -333     
Impacted Files Coverage Δ
dart/lib/src/hub.dart
dart/lib/src/scope.dart
dart/lib/src/sentry.dart
dart/lib/src/transport/rate_limit.dart
dart/lib/src/protocol/dsn.dart
dart/lib/src/protocol/sentry_stack_frame.dart
dart/lib/src/transport/encode.dart
dart/lib/src/sentry_sampling_context.dart
dart/lib/src/protocol/sentry_span.dart
...t/lib/src/sentry_attachment/sentry_attachment.dart
... and 87 more

Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here.

☔ View full report at Codecov.
📢 Do you have feedback about the report comment? Let us know in this issue.

dart/lib/src/hub.dart Outdated Show resolved Hide resolved
@marandaneto
Copy link
Contributor

@denrase there's one broken test.

@denrase denrase merged commit e1e3e33 into main Sep 12, 2022
@denrase denrase deleted the fix/capture-callback-exceptions branch September 12, 2022 14:44
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants