From 08c42b1000d3b3e7e1f8581709a55febf985493f Mon Sep 17 00:00:00 2001 From: Gabriel Date: Thu, 2 Jul 2026 16:05:57 -0300 Subject: [PATCH] Sentry: fix - report render errors caught by tab screen error boundary --- src/navigation/tabs/TabScreenErrorFallback.tsx | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/src/navigation/tabs/TabScreenErrorFallback.tsx b/src/navigation/tabs/TabScreenErrorFallback.tsx index 3e286b81f0..b4dc0feb55 100644 --- a/src/navigation/tabs/TabScreenErrorFallback.tsx +++ b/src/navigation/tabs/TabScreenErrorFallback.tsx @@ -2,6 +2,7 @@ import React, {useState} from 'react'; import {useTranslation} from 'react-i18next'; import {Linking, ScrollView} from 'react-native'; import ErrorBoundary from 'react-native-error-boundary'; +import * as Sentry from '@sentry/react-native'; import {TouchableOpacity} from '@components/base/TouchableOpacity'; import {useNavigation} from '@react-navigation/native'; import {NativeStackScreenProps} from '@react-navigation/native-stack'; @@ -153,6 +154,14 @@ export const withErrorFallback = ( { + Sentry.captureException(err, { + level: 'error', + tags: { + errorBoundary: 'tab-screen', + screen: TabScreen.displayName || TabScreen.name || 'unknown', + }, + extra: {componentStack: stack}, + }); setError(err); setStackTrace(stack); }}>