diff --git a/config/rsbuild/rsbuild.common.ts b/config/rsbuild/rsbuild.common.ts index dc60840ead8b..25eef7866a76 100644 --- a/config/rsbuild/rsbuild.common.ts +++ b/config/rsbuild/rsbuild.common.ts @@ -153,6 +153,9 @@ const getSharedConfiguration = ({file = '.env', isDevServer = false}: Environmen 'victory-native': path.resolve(dirname, '../../node_modules/victory-native/src/index.ts'), // Required for @shopify/react-native-skia web support 'react-native/Libraries/Image/AssetRegistry': false, + // @sentry/react-native references the optional expo-updates module. We do not install it, + // so web/Storybook bundles should treat it as unavailable instead of failing resolution. + 'expo-updates': false, // Use legacy build of pdfjs-dist to support older browsers 'pdfjs-dist$': path.resolve(dirname, '../../node_modules/pdfjs-dist/legacy/build/pdf.mjs'), '@assets': path.resolve(dirname, '../../assets'), diff --git a/ios/Podfile.lock b/ios/Podfile.lock index e9374d07ba90..4923d03c1895 100644 --- a/ios/Podfile.lock +++ b/ios/Podfile.lock @@ -4052,7 +4052,7 @@ PODS: - ReactCommon/turbomodule/core - SocketRocket - Yoga - - RNSentry (8.2.0): + - RNSentry (8.7.0): - boost - DoubleConversion - fast_float @@ -4079,7 +4079,7 @@ PODS: - ReactCodegen - ReactCommon/turbomodule/bridging - ReactCommon/turbomodule/core - - Sentry (= 9.5.1) + - Sentry (= 9.8.0) - SocketRocket - Yoga - RNShare (11.0.2): @@ -4267,9 +4267,9 @@ PODS: - SDWebImageWebPCoder (0.14.6): - libwebp (~> 1.0) - SDWebImage/Core (~> 5.17) - - Sentry (9.5.1): - - Sentry/Core (= 9.5.1) - - Sentry/Core (9.5.1) + - Sentry (9.8.0): + - Sentry/Core (= 9.8.0) + - Sentry/Core (9.8.0) - SocketRocket (0.7.1) - SwiftUIIntrospect (1.3.0) - TrustKit (3.0.7) @@ -4813,7 +4813,7 @@ SPEC CHECKSUMS: ExpoModulesCore: 368126ccb297fd4e498aa85c8fd97ce84b9b4d91 ExpoModulesJSI: 31051e6e3d88a96cc48747eabad1d4a6a29c554e ExpoModulesWorklets: 3f847eb6ba544bd4b55d585f89b3b18f8cd73a72 - ExpoModulesWorkletsAdapter: 4ced459d91107d4f32a8decf8b7827f58153436a + ExpoModulesWorkletsAdapter: 1b0f6a2cafb55bb83d1b1c8c2375374e242eab1b ExpoStoreReview: f785057aececd9c63a113c69a82b491e5f90694e ExpoTaskManager: f9511a17a4528adb8da94efb639ad592eef8bc53 ExpoVideo: 8ebbbf65778c5f986d65fc17bb60b79e9d7624e6 @@ -4837,7 +4837,7 @@ SPEC CHECKSUMS: GTMAppAuth: f69bd07d68cd3b766125f7e072c45d7340dea0de GTMSessionFetcher: 5aea5ba6bd522a239e236100971f10cb71b96ab6 GzipSwift: 893f3e48e597a1a4f62fafcb6514220fcf8287fa - hermes-engine: a042a38ee8fd790f69526e722127b3d187cfbc52 + hermes-engine: 1e3fdb2dddfecb258afa7e3951ff331c1e29397f libavif: 84bbb62fb232c3018d6f1bab79beea87e35de7b7 libdav1d: 23581a4d8ec811ff171ed5e2e05cd27bad64c39f libwebp: 02b23773aedb6ff1fd38cec7a77b81414c6842a8 @@ -4963,7 +4963,7 @@ SPEC CHECKSUMS: RNReactNativeHapticFeedback: 5f1542065f0b24c9252bd8cf3e83bc9c548182e4 RNReanimated: 920c33f677549b725b3e4a571fa8eeda790703d0 RNScreens: 2b6107925ee4e14a9b2eb0dfb52fe25223aa64d7 - RNSentry: f73f4da92e4c20841ab16e1fa22fc289bc2f9f4e + RNSentry: 67d50593363789905dde212b2fcab30a4f8b1846 RNShare: 1c1fde2c4134b9cf220ffebbd6df9c414036d382 RNSVG: 0b9792eb17fbbc8e6d186581cb2cf712998dcc2a RNWorklets: 8598e72b87947ae2f8428a541440851eb50579c3 @@ -4971,7 +4971,7 @@ SPEC CHECKSUMS: SDWebImageAVIFCoder: afe194a084e851f70228e4be35ef651df0fc5c57 SDWebImageSVGCoder: 15a300a97ec1c8ac958f009c02220ac0402e936c SDWebImageWebPCoder: e38c0a70396191361d60c092933e22c20d5b1380 - Sentry: 7475eb7bf6a41d7505f46341706015ad2d1766b9 + Sentry: 88746bf877eff714bc45315a39ad1d1efea2cdda SocketRocket: d4aabe649be1e368d1318fdf28a022d714d65748 SwiftUIIntrospect: fee9aa07293ee280373a591e1824e8ddc869ba5d TrustKit: 1050f3ce0595f8ed775f1237b7f590e3a4f93e91 diff --git a/knip.json b/knip.json index d4521bc70b6b..f2ca7715a904 100644 --- a/knip.json +++ b/knip.json @@ -28,7 +28,13 @@ ".storybook/**/*.{js,ts,tsx}", ".github/actions/javascript/**/*.ts" ], - "ignore": [".github/actions/**/index.js", "tests/perf-test/**", "web/snippets/gib.js", "src/libs/actions/connections/FinancialForce.ts"], + "ignore": [ + ".github/actions/**/index.js", + "tests/perf-test/**", + "web/snippets/gib.js", + "src/libs/actions/connections/FinancialForce.ts", + "src/setup/telemetry/noopExpoUpdates.ts" + ], "eslint": { "config": ["config/eslint/eslint.config.mjs", "eslint.changed.config.mjs"] }, diff --git a/metro.config.js b/metro.config.js index 87d7f1e1398d..22723ca4eeee 100644 --- a/metro.config.js +++ b/metro.config.js @@ -38,6 +38,7 @@ process.env.EXPO_PUBLIC_USE_RN_FETCH = process.env.EXPO_PUBLIC_USE_RN_FETCH ?? ' const defaultConfig = getReactNativeDefaultConfig(__dirname); const expoConfig = getExpoDefaultConfig(__dirname); +const noopExpoUpdatesPath = path.resolve(__dirname, 'src/setup/telemetry/noopExpoUpdates.ts'); const isDev = process.env.ENVIRONMENT === undefined || process.env.ENVIRONMENT === 'development'; @@ -52,6 +53,11 @@ const defaultGetPolyfills = defaultConfig.serializer?.getPolyfills ?? (() => []) const config = { resolver: { assetExts: [...defaultConfig.resolver.assetExts, 'lottie'], + extraNodeModules: { + ...(defaultConfig.resolver.extraNodeModules ?? {}), + ...(expoConfig.resolver.extraNodeModules ?? {}), + 'expo-updates': noopExpoUpdatesPath, + }, sourceExts: [...defaultConfig.resolver.sourceExts, ...defaultConfig.watcher.additionalExts, 'jsx'], }, // We are merging the default config from Expo and React Native and expo one is overriding the React Native one so inlineRequires is set to false so we want to set it to true diff --git a/package-lock.json b/package-lock.json index ed76f78cd038..e1fe56da231b 100644 --- a/package-lock.json +++ b/package-lock.json @@ -53,8 +53,8 @@ "@react-ng/bounds-observer": "^0.2.1", "@rnmapbox/maps": "10.3.2", "@sbaiahmed1/react-native-biometrics": "0.15.0", - "@sentry/core": "10.39.0", - "@sentry/react-native": "8.2.0", + "@sentry/core": "10.47.0", + "@sentry/react-native": "8.7.0", "@shopify/flash-list": "2.3.0", "@shopify/react-native-skia": "^2.4.14", "@ua/react-native-airship": "26.5.0", @@ -15417,50 +15417,50 @@ } }, "node_modules/@sentry-internal/browser-utils": { - "version": "10.39.0", - "resolved": "https://registry.npmjs.org/@sentry-internal/browser-utils/-/browser-utils-10.39.0.tgz", - "integrity": "sha512-W6WODonMGiI13Az5P7jd/m2lj/JpIyuVKg7wE4X+YdlMehLspAv6I7gRE4OBSumS14ZjdaYDpD/lwtnBwKAzcA==", + "version": "10.47.0", + "resolved": "https://registry.npmjs.org/@sentry-internal/browser-utils/-/browser-utils-10.47.0.tgz", + "integrity": "sha512-bVFRAeJWMBcBCvJKIFCMJ1/yQToL4vPGqfmlnDZeypcxkqUDKQ/Y3ziLHXoDL2sx0lagcgU2vH1QhCQ67Aujjw==", "license": "MIT", "dependencies": { - "@sentry/core": "10.39.0" + "@sentry/core": "10.47.0" }, "engines": { "node": ">=18" } }, "node_modules/@sentry-internal/feedback": { - "version": "10.39.0", - "resolved": "https://registry.npmjs.org/@sentry-internal/feedback/-/feedback-10.39.0.tgz", - "integrity": "sha512-cRXmmDeOr5FzVsBNRLU4WDEuC3fhuD0XV362EWl4DI3XBGao8ukaueKcLIKic5WZx6uXimjWw/UJmDLgxeCqkg==", + "version": "10.47.0", + "resolved": "https://registry.npmjs.org/@sentry-internal/feedback/-/feedback-10.47.0.tgz", + "integrity": "sha512-pdvMmi4dQpX5S/vAAzrhHPIw3T3HjUgDNgUiCBrlp7N9/6zGO2gNPhUnNekP+CjgI/z0rvf49RLqlDenpNrMOg==", "license": "MIT", "dependencies": { - "@sentry/core": "10.39.0" + "@sentry/core": "10.47.0" }, "engines": { "node": ">=18" } }, "node_modules/@sentry-internal/replay": { - "version": "10.39.0", - "resolved": "https://registry.npmjs.org/@sentry-internal/replay/-/replay-10.39.0.tgz", - "integrity": "sha512-obZoYOrUfxIYBHkmtPpItRdE38VuzF1VIxSgZ8Mbtq/9UvCWh+eOaVWU2stN/cVu1KYuYX0nQwBvdN28L6y/JA==", + "version": "10.47.0", + "resolved": "https://registry.npmjs.org/@sentry-internal/replay/-/replay-10.47.0.tgz", + "integrity": "sha512-ScdovxP7hJxgMt70+7hFvwT02GIaIUAxdEM/YPsayZBeCoAukPW8WiwztJfoKtsfPyKJ5A6f0H3PIxTPcA9Row==", "license": "MIT", "dependencies": { - "@sentry-internal/browser-utils": "10.39.0", - "@sentry/core": "10.39.0" + "@sentry-internal/browser-utils": "10.47.0", + "@sentry/core": "10.47.0" }, "engines": { "node": ">=18" } }, "node_modules/@sentry-internal/replay-canvas": { - "version": "10.39.0", - "resolved": "https://registry.npmjs.org/@sentry-internal/replay-canvas/-/replay-canvas-10.39.0.tgz", - "integrity": "sha512-TTiX0XWCcqTqFGJjEZYObk93j/sJmXcqPzcu0cN2mIkKnnaHDY3w74SHZCshKqIr0AOQdt1HDNa36s3TCdt0Jw==", + "version": "10.47.0", + "resolved": "https://registry.npmjs.org/@sentry-internal/replay-canvas/-/replay-canvas-10.47.0.tgz", + "integrity": "sha512-A5OY8friSe6g8WAK4L8IeOPiEd9D3Ps40DzRH5j2f6SUja0t90mKMvHRcRf8zq0d4BkdB+JM7tjOkwxpuv8heA==", "license": "MIT", "dependencies": { - "@sentry-internal/replay": "10.39.0", - "@sentry/core": "10.39.0" + "@sentry-internal/replay": "10.47.0", + "@sentry/core": "10.47.0" }, "engines": { "node": ">=18" @@ -15477,16 +15477,16 @@ } }, "node_modules/@sentry/browser": { - "version": "10.39.0", - "resolved": "https://registry.npmjs.org/@sentry/browser/-/browser-10.39.0.tgz", - "integrity": "sha512-I50W/1PDJWyqgNrGufGhBYCmmO3Bb159nx2Ut2bKoVveTfgH/hLEtDyW0kHo8Fu454mW+ukyXfU4L4s+kB9aaw==", + "version": "10.47.0", + "resolved": "https://registry.npmjs.org/@sentry/browser/-/browser-10.47.0.tgz", + "integrity": "sha512-rC0agZdxKA5XWfL4VwPOr/rJMogXDqZgnVzr93YWpFn9DMZT/7LzxSJVPIJwRUjx3bFEby3PcTa3YaX7pxm1AA==", "license": "MIT", "dependencies": { - "@sentry-internal/browser-utils": "10.39.0", - "@sentry-internal/feedback": "10.39.0", - "@sentry-internal/replay": "10.39.0", - "@sentry-internal/replay-canvas": "10.39.0", - "@sentry/core": "10.39.0" + "@sentry-internal/browser-utils": "10.47.0", + "@sentry-internal/feedback": "10.47.0", + "@sentry-internal/replay": "10.47.0", + "@sentry-internal/replay-canvas": "10.47.0", + "@sentry/core": "10.47.0" }, "engines": { "node": ">=18" @@ -15943,22 +15943,22 @@ } }, "node_modules/@sentry/core": { - "version": "10.39.0", - "resolved": "https://registry.npmjs.org/@sentry/core/-/core-10.39.0.tgz", - "integrity": "sha512-xCLip2mBwCdRrvXHtVEULX0NffUTYZZBhEUGht0WFL+GNdNQ7gmBOGOczhZlrf2hgFFtDO0fs1xiP9bqq5orEQ==", + "version": "10.47.0", + "resolved": "https://registry.npmjs.org/@sentry/core/-/core-10.47.0.tgz", + "integrity": "sha512-nsYRAx3EWezDut+Zl+UwwP07thh9uY7CfSAi2whTdcJl5hu1nSp2z8bba7Vq/MGbNLnazkd3A+GITBEML924JA==", "license": "MIT", "engines": { "node": ">=18" } }, "node_modules/@sentry/react": { - "version": "10.39.0", - "resolved": "https://registry.npmjs.org/@sentry/react/-/react-10.39.0.tgz", - "integrity": "sha512-qxReWHFhDcXNGEyAlYzhR7+K70es+vXaSknTZui1q7TfQwCT1rZlLKn/K8GDpNsb35RC5QhiIphU6pKbyYgZqw==", + "version": "10.47.0", + "resolved": "https://registry.npmjs.org/@sentry/react/-/react-10.47.0.tgz", + "integrity": "sha512-ZtJV6xxF8jUVE9e3YQUG3Do0XapG1GjniyLyqMPgN6cNvs/HaRJODf7m60By+VGqcl5XArEjEPTvx8CdPUXDfA==", "license": "MIT", "dependencies": { - "@sentry/browser": "10.39.0", - "@sentry/core": "10.39.0" + "@sentry/browser": "10.47.0", + "@sentry/core": "10.47.0" }, "engines": { "node": ">=18" @@ -15968,19 +15968,22 @@ } }, "node_modules/@sentry/react-native": { - "version": "8.2.0", - "resolved": "https://registry.npmjs.org/@sentry/react-native/-/react-native-8.2.0.tgz", - "integrity": "sha512-hcYakN9AzEHdaPHYQEHhTAneTqyqJm/MZ6Wb8+UGnXIaCnMjZCTRpu17GvQMBC4qh3lafyF3OwiO16SUDHYJhQ==", + "version": "8.7.0", + "resolved": "https://registry.npmjs.org/@sentry/react-native/-/react-native-8.7.0.tgz", + "integrity": "sha512-15c7L/DW+Po2/6jmwEB+9A1F6SEKOjfUsKZ3wW059Qsksk2gkCS0eeOlkYs20L4ucnstDdDtQD846tZsaeGf7Q==", "license": "MIT", "dependencies": { - "@sentry/babel-plugin-component-annotate": "4.9.1", - "@sentry/browser": "10.39.0", - "@sentry/cli": "3.2.2", - "@sentry/core": "10.39.0", - "@sentry/react": "10.39.0", - "@sentry/types": "10.39.0" + "@sentry/babel-plugin-component-annotate": "5.1.1", + "@sentry/browser": "10.47.0", + "@sentry/cli": "3.3.5", + "@sentry/core": "10.47.0", + "@sentry/react": "10.47.0", + "@sentry/types": "10.47.0" }, "bin": { + "sentry-eas-build-on-complete": "scripts/eas-build-hook.js", + "sentry-eas-build-on-error": "scripts/eas-build-hook.js", + "sentry-eas-build-on-success": "scripts/eas-build-hook.js", "sentry-expo-upload-sourcemaps": "scripts/expo-upload-sourcemaps.js" }, "peerDependencies": { @@ -15995,18 +15998,18 @@ } }, "node_modules/@sentry/react-native/node_modules/@sentry/babel-plugin-component-annotate": { - "version": "4.9.1", - "resolved": "https://registry.npmjs.org/@sentry/babel-plugin-component-annotate/-/babel-plugin-component-annotate-4.9.1.tgz", - "integrity": "sha512-0gEoi2Lb54MFYPOmdTfxlNKxI7kCOvNV7gP8lxMXJ7nCazF5OqOOZIVshfWjDLrc0QrSV6XdVvwPV9GDn4wBMg==", + "version": "5.1.1", + "resolved": "https://registry.npmjs.org/@sentry/babel-plugin-component-annotate/-/babel-plugin-component-annotate-5.1.1.tgz", + "integrity": "sha512-x2wEpBHwsTyTF2rWsLKJlzrRF1TTIGOfX+ngdE+Yd5DBkoS58HwQv824QOviPGQRla4/ypISqAXzjdDPL/zalg==", "license": "MIT", "engines": { - "node": ">= 14" + "node": ">= 18" } }, "node_modules/@sentry/react-native/node_modules/@sentry/cli": { - "version": "3.2.2", - "resolved": "https://registry.npmjs.org/@sentry/cli/-/cli-3.2.2.tgz", - "integrity": "sha512-qmjsm9+Bq/3QGTnIfOsJdhq+8LI3imxAPbGNBpRj4R0YFk+b1ry9huRHCLgkMcRFWtPkJmGZwEq2Z7e+02QPLA==", + "version": "3.3.5", + "resolved": "https://registry.npmjs.org/@sentry/cli/-/cli-3.3.5.tgz", + "integrity": "sha512-eyLHTj0rpeCsOUX+1ZU8UEWRXy6nXvTXNdhtAt1t6YXan9gSsAexZf28zVmDcYcP8WRbK0D2JMLp7NcaQCQgEA==", "hasInstallScript": true, "license": "FSL-1.1-MIT", "dependencies": { @@ -16022,20 +16025,20 @@ "node": ">= 18" }, "optionalDependencies": { - "@sentry/cli-darwin": "3.2.2", - "@sentry/cli-linux-arm": "3.2.2", - "@sentry/cli-linux-arm64": "3.2.2", - "@sentry/cli-linux-i686": "3.2.2", - "@sentry/cli-linux-x64": "3.2.2", - "@sentry/cli-win32-arm64": "3.2.2", - "@sentry/cli-win32-i686": "3.2.2", - "@sentry/cli-win32-x64": "3.2.2" + "@sentry/cli-darwin": "3.3.5", + "@sentry/cli-linux-arm": "3.3.5", + "@sentry/cli-linux-arm64": "3.3.5", + "@sentry/cli-linux-i686": "3.3.5", + "@sentry/cli-linux-x64": "3.3.5", + "@sentry/cli-win32-arm64": "3.3.5", + "@sentry/cli-win32-i686": "3.3.5", + "@sentry/cli-win32-x64": "3.3.5" } }, "node_modules/@sentry/react-native/node_modules/@sentry/cli-darwin": { - "version": "3.2.2", - "resolved": "https://registry.npmjs.org/@sentry/cli-darwin/-/cli-darwin-3.2.2.tgz", - "integrity": "sha512-y1uglMBbo9dYqC92hTQBkuGk7SegLPo1cVwJzX0dhplJoBMuanLMhOMYd1J20qhkDdBhguflCHGf0tOzNTGWhg==", + "version": "3.3.5", + "resolved": "https://registry.npmjs.org/@sentry/cli-darwin/-/cli-darwin-3.3.5.tgz", + "integrity": "sha512-E/SIY6+j2nt6Ri9nMt78sYle3LiF6uZyz4HGmvcEMU6HXjegmAayhy0J10JST+vZTzN6VixD8sUsa5UeJiOPcg==", "license": "FSL-1.1-MIT", "optional": true, "os": [ @@ -16046,9 +16049,9 @@ } }, "node_modules/@sentry/react-native/node_modules/@sentry/cli-linux-arm": { - "version": "3.2.2", - "resolved": "https://registry.npmjs.org/@sentry/cli-linux-arm/-/cli-linux-arm-3.2.2.tgz", - "integrity": "sha512-CC7N3hjOgs3cwrW0T9hqirFVUpKO6ASjdd0JT4DQHaAn34pruv8J+OoSnj1jkrT2DHxDkNNZPOFSK05AnHr8wA==", + "version": "3.3.5", + "resolved": "https://registry.npmjs.org/@sentry/cli-linux-arm/-/cli-linux-arm-3.3.5.tgz", + "integrity": "sha512-EGuEIvC2OQyar/vu+jAQEmovTMgxpoxdx5knnzL5dLhIemjEUNqwv/sXq+m/Aj+ThqCMofcTWB2TOZXsTtl0Tw==", "cpu": [ "arm" ], @@ -16064,9 +16067,9 @@ } }, "node_modules/@sentry/react-native/node_modules/@sentry/cli-linux-arm64": { - "version": "3.2.2", - "resolved": "https://registry.npmjs.org/@sentry/cli-linux-arm64/-/cli-linux-arm64-3.2.2.tgz", - "integrity": "sha512-SIGJknEQNDw9S/8QPTl8QLVe2IEiTKH3NeeHQ/Q2XWXig1ZebJfm4iTrdu47ypszIfxHeLvQkkVrr8mRKq16xA==", + "version": "3.3.5", + "resolved": "https://registry.npmjs.org/@sentry/cli-linux-arm64/-/cli-linux-arm64-3.3.5.tgz", + "integrity": "sha512-/W7HTk2OFKD0bguTvQR1ue6pkFQWaGiqPafOSIQKyq0aGfbZhBn/Uj+IRefgMZMhJQ29xRz0y/iGRGKE+ef4Vg==", "cpu": [ "arm64" ], @@ -16082,9 +16085,9 @@ } }, "node_modules/@sentry/react-native/node_modules/@sentry/cli-linux-i686": { - "version": "3.2.2", - "resolved": "https://registry.npmjs.org/@sentry/cli-linux-i686/-/cli-linux-i686-3.2.2.tgz", - "integrity": "sha512-W2hQ2DvIlZI05j2JN/87lfeo51F24zmQOJU6Uz+fZz/mkSvpnjeWxjAvfDNVGlLxp7XSoDbhHfrLBxdIh6jMeg==", + "version": "3.3.5", + "resolved": "https://registry.npmjs.org/@sentry/cli-linux-i686/-/cli-linux-i686-3.3.5.tgz", + "integrity": "sha512-qODMEWLEeUNp3IUlwwISB37EXSo8qgMmHQuLKfxDjpIKw+7NAFfptOloqPrHkLWK3TzFr+Nv643wIKZaYrz28Q==", "cpu": [ "x86", "ia32" @@ -16101,9 +16104,9 @@ } }, "node_modules/@sentry/react-native/node_modules/@sentry/cli-linux-x64": { - "version": "3.2.2", - "resolved": "https://registry.npmjs.org/@sentry/cli-linux-x64/-/cli-linux-x64-3.2.2.tgz", - "integrity": "sha512-4mh3yvOUxO63lq3teexRvalD1mWaRVjpgL2cCMKA2wkB69lcL5nK2gkdzDUKx2y/elluVdvGPPZaqOr1bfNI0w==", + "version": "3.3.5", + "resolved": "https://registry.npmjs.org/@sentry/cli-linux-x64/-/cli-linux-x64-3.3.5.tgz", + "integrity": "sha512-DCz7lQ4PySjQ1WvWOQ/uTdwauRo1D7hSHazxZ+fUAnK/epSPM9qLkjDMlD8uM5CaLoR8+ZTs7N94vV5LZs2QpA==", "cpu": [ "x64" ], @@ -16119,9 +16122,9 @@ } }, "node_modules/@sentry/react-native/node_modules/@sentry/cli-win32-arm64": { - "version": "3.2.2", - "resolved": "https://registry.npmjs.org/@sentry/cli-win32-arm64/-/cli-win32-arm64-3.2.2.tgz", - "integrity": "sha512-TQgfkdJgd8Y/lPzDibqc5Hamg8Hl5rN1sZwX80n4r9Ly46Yzu8Bv6KUhoNL/ktAvw9Aeko6Bx54rwZnzxFZHwg==", + "version": "3.3.5", + "resolved": "https://registry.npmjs.org/@sentry/cli-win32-arm64/-/cli-win32-arm64-3.3.5.tgz", + "integrity": "sha512-VMNsHiyZcP8Ft3fcK/1zoO4L66soe1eSfXg2tglFQSc/2MYA5v1Br9B1GtjBwDIc3EmdPtFZhOGLyqIzszMxJw==", "cpu": [ "arm64" ], @@ -16135,9 +16138,9 @@ } }, "node_modules/@sentry/react-native/node_modules/@sentry/cli-win32-i686": { - "version": "3.2.2", - "resolved": "https://registry.npmjs.org/@sentry/cli-win32-i686/-/cli-win32-i686-3.2.2.tgz", - "integrity": "sha512-vAcnq0SdYuvwIdREgF5APocjW3d9Z17xLwugpaAz8wpOjCeC1iMEFWqbz5k49i4iDkDVNFRMENiVvWVSu1kEnA==", + "version": "3.3.5", + "resolved": "https://registry.npmjs.org/@sentry/cli-win32-i686/-/cli-win32-i686-3.3.5.tgz", + "integrity": "sha512-BE6aHOIpsm4jgavsvvXNcSikAr/8NSva3rk1N3BzoOLuX+dcFxBI60K1i2VzB1vsgtivJJo9YySNCi60dBgWTg==", "cpu": [ "x86", "ia32" @@ -16152,9 +16155,9 @@ } }, "node_modules/@sentry/react-native/node_modules/@sentry/cli-win32-x64": { - "version": "3.2.2", - "resolved": "https://registry.npmjs.org/@sentry/cli-win32-x64/-/cli-win32-x64-3.2.2.tgz", - "integrity": "sha512-xWPTXjSSdmoyG/0ee7A9KSfsScGHCdaXMP6ASt4bMx3yYJO7ziEoZzfJE2M6oglz+woAm0LV9+O/n7g80tixlQ==", + "version": "3.3.5", + "resolved": "https://registry.npmjs.org/@sentry/cli-win32-x64/-/cli-win32-x64-3.3.5.tgz", + "integrity": "sha512-MSU+PtBuiLjEbiPFOvxk4CI3TCagwkIg9kvJ+DrI3+pBY0Sga/dOyeWKTIgb01xSVcfjdw0UkpU52VCvzTT9ew==", "cpu": [ "x64" ], @@ -16168,12 +16171,12 @@ } }, "node_modules/@sentry/types": { - "version": "10.39.0", - "resolved": "https://registry.npmjs.org/@sentry/types/-/types-10.39.0.tgz", - "integrity": "sha512-tRPFcjnBoljGYCNXql3aJBCLcHreoqXYv3SMr6bpFGY7JIP5HryXuESkEiDI8r3yggeb3TOCjqJ9GaixzEc71g==", + "version": "10.47.0", + "resolved": "https://registry.npmjs.org/@sentry/types/-/types-10.47.0.tgz", + "integrity": "sha512-WhV/ZO/a+3pU00rjXtb6WeZFZYn0Kz3JTc8Xvp7cx/D+kQJBm6b942TGb32UvnsglALLBxRyIBG+QO2u5r6cXw==", "license": "MIT", "dependencies": { - "@sentry/core": "10.39.0" + "@sentry/core": "10.47.0" }, "engines": { "node": ">=18" diff --git a/package.json b/package.json index fe9e6bf2e75d..155108533ef6 100644 --- a/package.json +++ b/package.json @@ -127,8 +127,8 @@ "@react-ng/bounds-observer": "^0.2.1", "@rnmapbox/maps": "10.3.2", "@sbaiahmed1/react-native-biometrics": "0.15.0", - "@sentry/core": "10.39.0", - "@sentry/react-native": "8.2.0", + "@sentry/core": "10.47.0", + "@sentry/react-native": "8.7.0", "@shopify/flash-list": "2.3.0", "@shopify/react-native-skia": "^2.4.14", "@ua/react-native-airship": "26.5.0", diff --git a/patches/expo-modules-core/details.md b/patches/expo-modules-core/details.md index d1d163c6d798..2cc109eea38b 100644 --- a/patches/expo-modules-core/details.md +++ b/patches/expo-modules-core/details.md @@ -6,3 +6,10 @@ - Upstream PR/issue: https://expo.canny.io/feature-requests/p/opt-out-of-react-native-fabric-view-recycling-for-expofabricviewobjc - E/App issue: 🛑 - PR Introducing Patch: [#69649](https://github.com/Expensify/App/pull/69649) + +### [expo-modules-core+56.0.14+002+worklets-adapter-boost-header-search-path.patch](expo-modules-core+56.0.14+002+worklets-adapter-boost-header-search-path.patch) + +- Reason: Add the Boost pod directory to `ExpoModulesWorkletsAdapter` header search paths so RCT-Folly framework headers can resolve Boost preprocessor headers when building with frameworks. +- Upstream PR/issue: 🛑 +- E/App issue: 🛑 +- PR Introducing Patch: 🛑 diff --git a/patches/expo-modules-core/expo-modules-core+56.0.14+002+worklets-adapter-boost-header-search-path.patch b/patches/expo-modules-core/expo-modules-core+56.0.14+002+worklets-adapter-boost-header-search-path.patch new file mode 100644 index 000000000000..e59d830c33fe --- /dev/null +++ b/patches/expo-modules-core/expo-modules-core+56.0.14+002+worklets-adapter-boost-header-search-path.patch @@ -0,0 +1,12 @@ +diff --git a/node_modules/expo-modules-core/ExpoModulesWorkletsAdapter.podspec b/node_modules/expo-modules-core/ExpoModulesWorkletsAdapter.podspec +index 00d6d62..2e0bbc3 100644 +--- a/node_modules/expo-modules-core/ExpoModulesWorkletsAdapter.podspec ++++ b/node_modules/expo-modules-core/ExpoModulesWorkletsAdapter.podspec +@@ -60,6 +60,7 @@ Pod::Spec.new do |s| + '"${PODS_CONFIGURATION_BUILD_DIR}/React-timing/React_timing.framework/Headers"', + '"${PODS_CONFIGURATION_BUILD_DIR}/React-debug/React_debug.framework/Headers"', + '"${PODS_CONFIGURATION_BUILD_DIR}/RCT-Folly/folly.framework/Headers"', ++ '"$(PODS_ROOT)/boost"', + '"${PODS_CONFIGURATION_BUILD_DIR}/fmt/fmt.framework/Headers"', + '"$(PODS_ROOT)/DoubleConversion"', + ]) diff --git a/patches/sentry-browser/@sentry+browser+10.39.0+001+request-id-support.patch b/patches/sentry-browser/@sentry+browser+10.47.0+001+request-id-support.patch similarity index 50% rename from patches/sentry-browser/@sentry+browser+10.39.0+001+request-id-support.patch rename to patches/sentry-browser/@sentry+browser+10.47.0+001+request-id-support.patch index 0a45cd4e4794..8fde3791d606 100644 --- a/patches/sentry-browser/@sentry+browser+10.39.0+001+request-id-support.patch +++ b/patches/sentry-browser/@sentry+browser+10.47.0+001+request-id-support.patch @@ -1,68 +1,68 @@ diff --git a/node_modules/@sentry/browser/build/npm/cjs/dev/tracing/request.js b/node_modules/@sentry/browser/build/npm/cjs/dev/tracing/request.js -index 6bfc053..21d2a37 100644 +index eefbf8e..748fbfb 100644 --- a/node_modules/@sentry/browser/build/npm/cjs/dev/tracing/request.js +++ b/node_modules/@sentry/browser/build/npm/cjs/dev/tracing/request.js -@@ -227,6 +227,12 @@ function xhrCallback( - const span = spans[spanId]; - if (span && sentryXhrData.status_code !== undefined) { - core.setHttpStatus(span, sentryXhrData.status_code); -+ if (handlerData.xhr.getAllResponseHeaders().toLowerCase().includes('x-request-id')) { +@@ -229,6 +229,12 @@ function xhrCallback( + if (span) { + if (shouldCreateSpanResult && sentryXhrData.status_code !== undefined) { + core.setHttpStatus(span, sentryXhrData.status_code); ++ if (handlerData.xhr.getAllResponseHeaders().toLowerCase().includes('x-request-id')) { + const requestId = handlerData.xhr.getResponseHeader('x-request-id'); + if (requestId) { -+ span.setAttribute('request-id', requestId) ++ span.setAttribute('request-id', requestId); + } -+ } - span.end(); ++ } + span.end(); - onRequestSpanEnd?.(span, { + onRequestSpanEnd?.(span, { diff --git a/node_modules/@sentry/browser/build/npm/cjs/prod/tracing/request.js b/node_modules/@sentry/browser/build/npm/cjs/prod/tracing/request.js -index 6bfc053..21d2a37 100644 +index eefbf8e..748fbfb 100644 --- a/node_modules/@sentry/browser/build/npm/cjs/prod/tracing/request.js +++ b/node_modules/@sentry/browser/build/npm/cjs/prod/tracing/request.js -@@ -227,6 +227,12 @@ function xhrCallback( - const span = spans[spanId]; - if (span && sentryXhrData.status_code !== undefined) { - core.setHttpStatus(span, sentryXhrData.status_code); -+ if (handlerData.xhr.getAllResponseHeaders().toLowerCase().includes('x-request-id')) { +@@ -229,6 +229,12 @@ function xhrCallback( + if (span) { + if (shouldCreateSpanResult && sentryXhrData.status_code !== undefined) { + core.setHttpStatus(span, sentryXhrData.status_code); ++ if (handlerData.xhr.getAllResponseHeaders().toLowerCase().includes('x-request-id')) { + const requestId = handlerData.xhr.getResponseHeader('x-request-id'); + if (requestId) { -+ span.setAttribute('request-id', requestId) ++ span.setAttribute('request-id', requestId); + } -+ } - span.end(); ++ } + span.end(); - onRequestSpanEnd?.(span, { + onRequestSpanEnd?.(span, { diff --git a/node_modules/@sentry/browser/build/npm/esm/dev/tracing/request.js b/node_modules/@sentry/browser/build/npm/esm/dev/tracing/request.js -index 57d2ae8..063b495 100644 +index 15f9a43..7c3b557 100644 --- a/node_modules/@sentry/browser/build/npm/esm/dev/tracing/request.js +++ b/node_modules/@sentry/browser/build/npm/esm/dev/tracing/request.js -@@ -225,6 +225,12 @@ function xhrCallback( - const span = spans[spanId]; - if (span && sentryXhrData.status_code !== undefined) { - setHttpStatus(span, sentryXhrData.status_code); -+ if (handlerData.xhr.getAllResponseHeaders().toLowerCase().includes('x-request-id')) { +@@ -227,6 +227,12 @@ function xhrCallback( + if (span) { + if (shouldCreateSpanResult && sentryXhrData.status_code !== undefined) { + setHttpStatus(span, sentryXhrData.status_code); ++ if (handlerData.xhr.getAllResponseHeaders().toLowerCase().includes('x-request-id')) { + const requestId = handlerData.xhr.getResponseHeader('x-request-id'); + if (requestId) { -+ span.setAttribute('request-id', requestId) ++ span.setAttribute('request-id', requestId); + } -+ } - span.end(); ++ } + span.end(); - onRequestSpanEnd?.(span, { + onRequestSpanEnd?.(span, { diff --git a/node_modules/@sentry/browser/build/npm/esm/prod/tracing/request.js b/node_modules/@sentry/browser/build/npm/esm/prod/tracing/request.js -index 57d2ae8..063b495 100644 +index 15f9a43..7c3b557 100644 --- a/node_modules/@sentry/browser/build/npm/esm/prod/tracing/request.js +++ b/node_modules/@sentry/browser/build/npm/esm/prod/tracing/request.js -@@ -225,6 +225,12 @@ function xhrCallback( - const span = spans[spanId]; - if (span && sentryXhrData.status_code !== undefined) { - setHttpStatus(span, sentryXhrData.status_code); -+ if (handlerData.xhr.getAllResponseHeaders().toLowerCase().includes('x-request-id')) { +@@ -227,6 +227,12 @@ function xhrCallback( + if (span) { + if (shouldCreateSpanResult && sentryXhrData.status_code !== undefined) { + setHttpStatus(span, sentryXhrData.status_code); ++ if (handlerData.xhr.getAllResponseHeaders().toLowerCase().includes('x-request-id')) { + const requestId = handlerData.xhr.getResponseHeader('x-request-id'); + if (requestId) { -+ span.setAttribute('request-id', requestId) ++ span.setAttribute('request-id', requestId); + } -+ } - span.end(); ++ } + span.end(); - onRequestSpanEnd?.(span, { + onRequestSpanEnd?.(span, { diff --git a/patches/sentry-browser/details.md b/patches/sentry-browser/details.md index 195a99eeea92..47312e3a290a 100644 --- a/patches/sentry-browser/details.md +++ b/patches/sentry-browser/details.md @@ -1,8 +1,8 @@ # `@sentry/browser` patches -### [@sentry+browser+10.39.0+001+request-id-support.patch](@sentry+browser+10.39.0+001+request-id-support.patch) +### [@sentry+browser+10.47.0+001+request-id-support.patch](@sentry+browser+10.47.0+001+request-id-support.patch) Reason: improve developer experience by adding `request-id` to spans related to API calls. This takes request-id from response headers and write it to the span related to that response. With that information it is easier to connect backend request / logs with data retrieved from Sentry. - Upstream PR/issue: N/A - E/App issue: https://github.com/Expensify/App/issues/75588 -- PR Introducing Patch: https://github.com/Expensify/App/pull/79883 \ No newline at end of file +- PR Introducing Patch: https://github.com/Expensify/App/pull/79883 diff --git a/patches/sentry-core/@sentry+core+10.39.0+001+data-sentry-label-support.patch b/patches/sentry-core/@sentry+core+10.47.0+001+data-sentry-label-support.patch similarity index 98% rename from patches/sentry-core/@sentry+core+10.39.0+001+data-sentry-label-support.patch rename to patches/sentry-core/@sentry+core+10.47.0+001+data-sentry-label-support.patch index 2e0a8951c435..3791c1e786fe 100644 --- a/patches/sentry-core/@sentry+core+10.39.0+001+data-sentry-label-support.patch +++ b/patches/sentry-core/@sentry+core+10.47.0+001+data-sentry-label-support.patch @@ -1,9 +1,9 @@ diff --git a/node_modules/@sentry/core/build/cjs/utils/browser.js b/node_modules/@sentry/core/build/cjs/utils/browser.js -index 3169c25..19acc49 100644 +index 1bdc52f..71de87f 100644 --- a/node_modules/@sentry/core/build/cjs/utils/browser.js +++ b/node_modules/@sentry/core/build/cjs/utils/browser.js @@ -9,8 +9,8 @@ const DEFAULT_MAX_STRING_LENGTH = 80; - + /** * Given a child DOM element, returns a query-selector statement describing that - * and its ancestors @@ -16,7 +16,7 @@ index 3169c25..19acc49 100644 @@ -53,7 +53,47 @@ function htmlTreeAsString( currentElem = currentElem.parentNode; } - + - return out.reverse().join(separator); + const cssSelector = out.reverse().join(separator); + @@ -63,7 +63,7 @@ index 3169c25..19acc49 100644 return ''; } @@ -77,8 +117,12 @@ function _htmlElementAsString(el, keyAttrs) { - + // @ts-expect-error WINDOW has HTMLElement if (WINDOW.HTMLElement) { - // If using the component name annotation plugin, this value may be available on the DOM node @@ -77,11 +77,11 @@ index 3169c25..19acc49 100644 return elem.dataset['sentryComponent']; } diff --git a/node_modules/@sentry/core/build/esm/utils/browser.js b/node_modules/@sentry/core/build/esm/utils/browser.js -index 2ad52b0..796cac9 100644 +index 5e593f3..e024d2f 100644 --- a/node_modules/@sentry/core/build/esm/utils/browser.js +++ b/node_modules/@sentry/core/build/esm/utils/browser.js @@ -7,8 +7,8 @@ const DEFAULT_MAX_STRING_LENGTH = 80; - + /** * Given a child DOM element, returns a query-selector statement describing that - * and its ancestors @@ -94,7 +94,7 @@ index 2ad52b0..796cac9 100644 @@ -51,7 +51,47 @@ function htmlTreeAsString( currentElem = currentElem.parentNode; } - + - return out.reverse().join(separator); + const cssSelector = out.reverse().join(separator); + @@ -141,7 +141,7 @@ index 2ad52b0..796cac9 100644 return ''; } @@ -75,8 +115,12 @@ function _htmlElementAsString(el, keyAttrs) { - + // @ts-expect-error WINDOW has HTMLElement if (WINDOW.HTMLElement) { - // If using the component name annotation plugin, this value may be available on the DOM node diff --git a/patches/sentry-core/@sentry+core+10.39.0+002+request-id-support.patch b/patches/sentry-core/@sentry+core+10.47.0+002+request-id-support.patch similarity index 86% rename from patches/sentry-core/@sentry+core+10.39.0+002+request-id-support.patch rename to patches/sentry-core/@sentry+core+10.47.0+002+request-id-support.patch index c28f57144ac1..d2ab2a024cc3 100644 --- a/patches/sentry-core/@sentry+core+10.39.0+002+request-id-support.patch +++ b/patches/sentry-core/@sentry+core+10.47.0+002+request-id-support.patch @@ -1,8 +1,8 @@ diff --git a/node_modules/@sentry/core/build/esm/fetch.js b/node_modules/@sentry/core/build/esm/fetch.js -index 27c5e79..9686203 100644 +index 57426a7..29b1182 100644 --- a/node_modules/@sentry/core/build/esm/fetch.js +++ b/node_modules/@sentry/core/build/esm/fetch.js -@@ -237,7 +237,10 @@ function _addTracingHeadersToFetchRequest( +@@ -241,7 +241,10 @@ function _addTracingHeadersToFetchRequest( function endSpan(span, handlerData) { if (handlerData.response) { setHttpStatus(span, handlerData.response.status); diff --git a/patches/sentry-core/details.md b/patches/sentry-core/details.md index f3eabd538156..134555901c11 100644 --- a/patches/sentry-core/details.md +++ b/patches/sentry-core/details.md @@ -1,6 +1,6 @@ # `@sentry/core` patches -### [@sentry+core+10.39.0+001+data-sentry-label-support.patch](@sentry+core+10.39.0+001+data-sentry-label-support.patch) +### [@sentry+core+10.47.0+001+data-sentry-label-support.patch](@sentry+core+10.47.0+001+data-sentry-label-support.patch) - Reason: Enhances the `htmlTreeAsString` function to support `data-sentry-label` attributes for better element identification in Sentry spans. The patch: - Always includes `data-sentry-label` in the list of checked attributes for each DOM element @@ -12,9 +12,9 @@ - E/App issue: https://github.com/Expensify/App/issues/76128 - PR Introducing Patch: https://github.com/Expensify/App/pull/76547 -### [@sentry+core+10.39.0+002+request-id-support.patch](@sentry+core+10.39.0+002+request-id-support.patch) +### [@sentry+core+10.47.0+002+request-id-support.patch](@sentry+core+10.47.0+002+request-id-support.patch) Reason: improve developer experience by adding `request-id` to spans related to API calls. This takes request-id from response headers and write it to the span related to that response. With that information it is easier to connect backend request / logs with data retrieved from Sentry. - Upstream PR/issue: N/A - E/App issue: https://github.com/Expensify/App/issues/75588 -- PR Introducing Patch: https://github.com/Expensify/App/pull/79883 \ No newline at end of file +- PR Introducing Patch: https://github.com/Expensify/App/pull/79883 diff --git a/patches/sentry-react-native/@sentry+react-native+8.2.0.patch b/patches/sentry-react-native/@sentry+react-native+8.7.0.patch similarity index 100% rename from patches/sentry-react-native/@sentry+react-native+8.2.0.patch rename to patches/sentry-react-native/@sentry+react-native+8.7.0.patch diff --git a/patches/sentry-react-native/details.md b/patches/sentry-react-native/details.md index db6ad6726234..08bc276e8095 100644 --- a/patches/sentry-react-native/details.md +++ b/patches/sentry-react-native/details.md @@ -1,9 +1,8 @@ # `@sentry/react-native` patches -### [@sentry+react-native+8.2.0.patch](@sentry+react-native+8.2.0.patch) +### [@sentry+react-native+8.7.0.patch](@sentry+react-native+8.7.0.patch) - Reason: Fixes React Native path resolution in the Sentry Ruby script during iOS builds. The original implementation failed to locate `react-native/package.json` in our hybrid app setup. The patch changes the resolution strategy to first try resolving from the installation root (similar to react-native-svg and react-native-reanimated), and falls back to ENV variables with support for both node_modules conventions. - Upstream PR/issue: N/A (specific to our hybrid app environment) - E/App issue: N/A - PR Introducing Patch: https://github.com/Expensify/App/pull/70298 - diff --git a/src/setup/telemetry/noopExpoUpdates.ts b/src/setup/telemetry/noopExpoUpdates.ts new file mode 100644 index 000000000000..5287d89cf21b --- /dev/null +++ b/src/setup/telemetry/noopExpoUpdates.ts @@ -0,0 +1,39 @@ +/** + * Metro resolves Sentry's optional expo-updates import to this stub. Expensify does not use + * Expo Updates, so this keeps native bundles from failing resolution without adding that native dependency. + */ +type Subscription = { + remove: () => void; +}; + +const noopSubscription: Subscription = { + remove: () => {}, +}; + +const addListener = (): Subscription => noopSubscription; +const isEnabled = false; +const isEmbeddedLaunch = false; +const isEmergencyLaunch = false; +const isUsingEmbeddedAssets = false; +const updateId = null; +const channel = null; +const runtimeVersion = null; +const checkAutomatically = null; +const emergencyLaunchReason = null; +const launchDuration = null; +const createdAt = null; + +export { + addListener, + isEnabled, + isEmbeddedLaunch, + isEmergencyLaunch, + isUsingEmbeddedAssets, + updateId, + channel, + runtimeVersion, + checkAutomatically, + emergencyLaunchReason, + launchDuration, + createdAt, +};