-
-
Notifications
You must be signed in to change notification settings - Fork 474
fix(android): mark tombstone and ANR exits as reported when the event is dropped #6002
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
base: main
Are you sure you want to change the base?
Changes from all commits
72d9812
838fc03
ab9fa40
4d5a224
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -7,6 +7,7 @@ | |
| import io.sentry.hints.Backfillable; | ||
| import io.sentry.hints.Cached; | ||
| import io.sentry.hints.DiskFlushNotification; | ||
| import io.sentry.hints.EventDropReason; | ||
| import io.sentry.hints.TransactionEnd; | ||
| import io.sentry.logger.ILoggerBatchProcessor; | ||
| import io.sentry.logger.NoOpLoggerBatchProcessor; | ||
|
|
@@ -137,6 +138,7 @@ private boolean shouldApplyScopeData(final @NotNull CheckIn event, final @NotNul | |
| options | ||
| .getClientReportRecorder() | ||
| .recordLostEvent(DiscardReason.EVENT_PROCESSOR, DataCategory.Error); | ||
| HintUtils.setEventDropReason(hint, EventDropReason.IGNORED); | ||
| return SentryId.EMPTY_ID; | ||
| } | ||
|
|
||
|
|
@@ -150,6 +152,7 @@ private boolean shouldApplyScopeData(final @NotNull CheckIn event, final @NotNul | |
| options | ||
| .getClientReportRecorder() | ||
| .recordLostEvent(DiscardReason.EVENT_PROCESSOR, DataCategory.Error); | ||
| HintUtils.setEventDropReason(hint, EventDropReason.IGNORED); | ||
| return SentryId.EMPTY_ID; | ||
| } | ||
| } | ||
|
Comment on lines
152
to
158
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Bug: An exception in the Suggested FixDistinguish between an intentional drop (callback returns Prompt for AI Agent |
||
|
|
@@ -176,6 +179,7 @@ private boolean shouldApplyScopeData(final @NotNull CheckIn event, final @NotNul | |
| options | ||
| .getClientReportRecorder() | ||
| .recordLostEvent(DiscardReason.BEFORE_SEND, DataCategory.Error); | ||
| HintUtils.setEventDropReason(hint, EventDropReason.BEFORE_SEND); | ||
| } | ||
| } | ||
|
|
||
|
|
@@ -208,6 +212,7 @@ private boolean shouldApplyScopeData(final @NotNull CheckIn event, final @NotNul | |
| options | ||
| .getClientReportRecorder() | ||
| .recordLostEvent(DiscardReason.SAMPLE_RATE, DataCategory.Error); | ||
| HintUtils.setEventDropReason(hint, EventDropReason.SAMPLE_RATE); | ||
| // setting event as null to not be sent as its been discarded by sample rate | ||
| event = null; | ||
| } | ||
|
|
||
Uh oh!
There was an error while loading. Please reload this page.