Summary: Crash reporting for the 7Mind React Native app: what Sentry does in the Flutter app, how pulse-app reports crashes, the options, and the recommendation Firebase Crashlytics through @pulseapp/observability with what it implies for the migration period and alerts.
Sources: tracking spike on 2026-11-16 (pulse-app branch claude/spike-tracking-907463, report apps/sevenmind/docs/spikes/tracking.md, section 4, not pushed); Flutter lib/app.dart and lib/features/core/data/services/logger/ on origin/main (4.0.11) of 7mind-mobile-apps-monorepo; pulse-app packages/observability, packages/core/src/logger.ts, apps/native/index.ts
Last updated: 2026-11-19
Recommendation
Use Firebase Crashlytics through @pulseapp/observability, as the fitness apps do. Do not keep Sentry for the React Native app and do not run both.
- The core
loggeralready forwards to Crashlytics:logger.error(message, error)records a non-fatal,logger.infoandlogger.warnbecome Crashlytics log lines,logger.debugstays on the console. - Crashlytics runs in the 7Mind Firebase projects that already exist (
mind-flutter-stg,mind-flutter-5ef1a). No new vendor;@react-native-firebase/crashlytics26.3.3 is the version the fitness apps pin. - Keeping Sentry (
@sentry/react-native) would add a dependency, source map upload in CI and a second error-reporting pattern in the repo. Running both duplicates alerts and cost.
Decision status: recorded in rn-migration-decision-log on 2026-11-06 as an example of the rule “follow pulse-app’s library choices”, source a conversation. Not separately confirmed with the 7Mind team; the 2026-11-09 kickoff did not cover crash reporting.
What the Flutter app does
sentry_flutter 9.8.0, initialised in lib/app.dart in release builds only (debug builds of both flavors have no Sentry). DSN hardcoded in the same file.
- Options:
tracesSampleRate1.0,environmentstagingorproduction, release from package info (seven_mind@<version>+<build>). NobeforeSend, no navigator observer, no HTTP integration, so tracing adds little. - Errors:
Logger.logError(203 call sites) callsSentry.captureExceptionwith the taglogType=manualand the message in the contexterror_details. - Breadcrumbs: every
Logger.logcall becomes anapp.logbreadcrumb, including every analytics event with all its properties. - User: numeric Gymondo id plus
legacy_uuidin the user data, set on every identity sync, never cleared on logout. - Alert-relevant errors: the paywall
[CRITICAL]errors (pay_wall_cubit.dart),User ID is null, cannot track content piece started(player_bloc.dart),ContentDownloadExceptionfor all download failures, and the native Android warning for MIND-817 (MainActivity.kt).
What pulse-app does
initCrashReporting({ tenant, env }) runs first in apps/native/index.ts, so later init failures are captured. It turns collection off on local, sets tenant and env as attributes, and installs the Crashlytics sink on the core logger. setCrashUser(id) follows every identity change in the auth store. The withCrashlyticsNativeSymbols config plugin uploads native symbols. apps/tv uses the same package.
Options
Crashlytics via @pulseapp/observability | Keep Sentry | Both during rollout | |
|---|---|---|---|
| Follows pulse-app | yes | no | partly |
| Shared code change | widen initCrashReporting’s tenant from TenantId to BrandId (type only); optional setCrashAttributes for legacy_uuid | none | both |
New dependency in apps/sevenmind | @react-native-firebase/crashlytics 26.3.3 | @sentry/react-native plus Expo plugin and CI source maps | both |
| Alerts | rebuild in Crashlytics | existing Sentry alerts keep working | duplicated |
| Flutter vs RN comparison during rollout | different tools, compare in App Store Connect and Play Console Android vitals | same tool on both sides | same tool, double cost |
Implications
- In
apps/sevenmind: add the dependency; callinitCrashReportingfirst inindex.ts;setCrashUser(numericId)on login and clear it on logout; copywithCrashlyticsNativeSymbols(or move it totooling/with the fitness app owners’ agreement). - Porting rule: Flutter’s
Logger.logErrorbecomeslogger.error(message, error);Logger.logbecomeslogger.infoorlogger.warn. Analytics events no longer go into crash logs, which keeps user ids and URLs out of crash reports; the event trail lives in Rudderstack. - Firebase console: Crashlytics and its Slack alerting must be enabled in both 7Mind Firebase projects by someone with access to them.
- Migration period: Flutter versions keep reporting to the Sentry project, RN versions to Crashlytics. Rebuild the alert-relevant errors above as Crashlytics alerts before the first RN rollout. Keep the Sentry project until Flutter adoption falls below an agreed level.
- Effort: about 1 to 1.5 days of code plus the console setup.
Open questions
| Question | Owner |
|---|---|
| Confirm Crashlytics instead of Sentry with the team | 7Mind mobile lead |
Who enables Crashlytics and alerting in mind-flutter-stg and mind-flutter-5ef1a | 7Mind mobile lead |
| At what Flutter adoption level the Sentry project is shut down | 7Mind mobile lead |