Problem
Android SDK 8.35.0 introduced enableAnrFingerprinting which is enabled by default. When enabled, ANR events whose stacktraces contain only system frames (e.g. java.lang, android.os) are grouped into a single issue instead of creating many separate issues.
There is currently no way for React Native users to opt out of this behavior from JavaScript.
Solution
Expose enableAnrFingerprinting (default: true, matching Android SDK default) in the RN SDK options so users can disable it if needed:
Sentry.init({
dsn: '...',
enableAnrFingerprinting: false, // opt-out of default ANR grouping
});
This requires:
- Adding the option to the JS/TS options type
- Passing it through the native bridge to
SentryAndroidOptions
Context
Problem
Android SDK 8.35.0 introduced
enableAnrFingerprintingwhich is enabled by default. When enabled, ANR events whose stacktraces contain only system frames (e.g.java.lang,android.os) are grouped into a single issue instead of creating many separate issues.There is currently no way for React Native users to opt out of this behavior from JavaScript.
Solution
Expose
enableAnrFingerprinting(default:true, matching Android SDK default) in the RN SDK options so users can disable it if needed:This requires:
SentryAndroidOptionsContext
sentry-java8.35.0 (#4899-related)truein the Android SDK — grouping behavior changes silently for users upgrading without this option exposed