@sentry/react-native 5.28.0 → 6.0.0-alpha.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (294) hide show
  1. package/CHANGELOG.md +113 -0
  2. package/android/build.gradle +1 -1
  3. package/dist/js/client.d.ts +5 -9
  4. package/dist/js/client.d.ts.map +1 -1
  5. package/dist/js/client.js +11 -42
  6. package/dist/js/client.js.map +1 -1
  7. package/dist/js/index.d.ts +5 -10
  8. package/dist/js/index.d.ts.map +1 -1
  9. package/dist/js/index.js +4 -21
  10. package/dist/js/index.js.map +1 -1
  11. package/dist/js/integrations/debugsymbolicator.d.ts +2 -8
  12. package/dist/js/integrations/debugsymbolicator.d.ts.map +1 -1
  13. package/dist/js/integrations/debugsymbolicator.js +1 -9
  14. package/dist/js/integrations/debugsymbolicator.js.map +1 -1
  15. package/dist/js/integrations/default.d.ts.map +1 -1
  16. package/dist/js/integrations/default.js +18 -7
  17. package/dist/js/integrations/default.js.map +1 -1
  18. package/dist/js/integrations/devicecontext.d.ts +2 -8
  19. package/dist/js/integrations/devicecontext.d.ts.map +1 -1
  20. package/dist/js/integrations/devicecontext.js +0 -9
  21. package/dist/js/integrations/devicecontext.js.map +1 -1
  22. package/dist/js/integrations/eventorigin.d.ts +2 -8
  23. package/dist/js/integrations/eventorigin.d.ts.map +1 -1
  24. package/dist/js/integrations/eventorigin.js +0 -8
  25. package/dist/js/integrations/eventorigin.js.map +1 -1
  26. package/dist/js/integrations/expocontext.d.ts +2 -8
  27. package/dist/js/integrations/expocontext.d.ts.map +1 -1
  28. package/dist/js/integrations/expocontext.js +0 -8
  29. package/dist/js/integrations/expocontext.js.map +1 -1
  30. package/dist/js/integrations/exports.d.ts +4 -0
  31. package/dist/js/integrations/exports.d.ts.map +1 -1
  32. package/dist/js/integrations/exports.js +4 -0
  33. package/dist/js/integrations/exports.js.map +1 -1
  34. package/dist/js/integrations/modulesloader.d.ts +2 -8
  35. package/dist/js/integrations/modulesloader.d.ts.map +1 -1
  36. package/dist/js/integrations/modulesloader.js +0 -8
  37. package/dist/js/integrations/modulesloader.js.map +1 -1
  38. package/dist/js/integrations/nativelinkederrors.d.ts +2 -8
  39. package/dist/js/integrations/nativelinkederrors.d.ts.map +1 -1
  40. package/dist/js/integrations/nativelinkederrors.js +0 -8
  41. package/dist/js/integrations/nativelinkederrors.js.map +1 -1
  42. package/dist/js/integrations/reactnativeerrorhandlers.d.ts +2 -8
  43. package/dist/js/integrations/reactnativeerrorhandlers.d.ts.map +1 -1
  44. package/dist/js/integrations/reactnativeerrorhandlers.js +1 -8
  45. package/dist/js/integrations/reactnativeerrorhandlers.js.map +1 -1
  46. package/dist/js/integrations/reactnativeinfo.d.ts +2 -8
  47. package/dist/js/integrations/reactnativeinfo.d.ts.map +1 -1
  48. package/dist/js/integrations/reactnativeinfo.js +0 -8
  49. package/dist/js/integrations/reactnativeinfo.js.map +1 -1
  50. package/dist/js/integrations/release.d.ts +2 -8
  51. package/dist/js/integrations/release.d.ts.map +1 -1
  52. package/dist/js/integrations/release.js +0 -8
  53. package/dist/js/integrations/release.js.map +1 -1
  54. package/dist/js/integrations/rewriteframes.js +1 -1
  55. package/dist/js/integrations/rewriteframes.js.map +1 -1
  56. package/dist/js/integrations/screenshot.d.ts +2 -8
  57. package/dist/js/integrations/screenshot.d.ts.map +1 -1
  58. package/dist/js/integrations/screenshot.js +2 -11
  59. package/dist/js/integrations/screenshot.js.map +1 -1
  60. package/dist/js/integrations/sdkinfo.d.ts +2 -8
  61. package/dist/js/integrations/sdkinfo.d.ts.map +1 -1
  62. package/dist/js/integrations/sdkinfo.js +0 -8
  63. package/dist/js/integrations/sdkinfo.js.map +1 -1
  64. package/dist/js/integrations/spotlight.d.ts +2 -10
  65. package/dist/js/integrations/spotlight.d.ts.map +1 -1
  66. package/dist/js/integrations/spotlight.js +1 -10
  67. package/dist/js/integrations/spotlight.js.map +1 -1
  68. package/dist/js/integrations/viewhierarchy.d.ts +2 -8
  69. package/dist/js/integrations/viewhierarchy.d.ts.map +1 -1
  70. package/dist/js/integrations/viewhierarchy.js +0 -8
  71. package/dist/js/integrations/viewhierarchy.js.map +1 -1
  72. package/dist/js/options.d.ts +43 -0
  73. package/dist/js/options.d.ts.map +1 -1
  74. package/dist/js/options.js.map +1 -1
  75. package/dist/js/profiling/cache.d.ts +1 -1
  76. package/dist/js/profiling/hermes.d.ts +1 -1
  77. package/dist/js/profiling/hermes.d.ts.map +1 -1
  78. package/dist/js/profiling/integration.d.ts +1 -7
  79. package/dist/js/profiling/integration.d.ts.map +1 -1
  80. package/dist/js/profiling/integration.js +39 -25
  81. package/dist/js/profiling/integration.js.map +1 -1
  82. package/dist/js/profiling/utils.js +2 -1
  83. package/dist/js/profiling/utils.js.map +1 -1
  84. package/dist/js/replay/mobilereplay.d.ts +2 -2
  85. package/dist/js/replay/mobilereplay.d.ts.map +1 -1
  86. package/dist/js/replay/mobilereplay.js.map +1 -1
  87. package/dist/js/scopeSync.d.ts +6 -0
  88. package/dist/js/scopeSync.d.ts.map +1 -0
  89. package/dist/js/scopeSync.js +60 -0
  90. package/dist/js/scopeSync.js.map +1 -0
  91. package/dist/js/sdk.d.ts +1 -20
  92. package/dist/js/sdk.d.ts.map +1 -1
  93. package/dist/js/sdk.js +20 -53
  94. package/dist/js/sdk.js.map +1 -1
  95. package/dist/js/tools/sentryMetroSerializer.js.map +1 -1
  96. package/dist/js/touchevents.d.ts +0 -1
  97. package/dist/js/touchevents.d.ts.map +1 -1
  98. package/dist/js/touchevents.js +5 -9
  99. package/dist/js/touchevents.js.map +1 -1
  100. package/dist/js/tracing/gesturetracing.d.ts +1 -6
  101. package/dist/js/tracing/gesturetracing.d.ts.map +1 -1
  102. package/dist/js/tracing/gesturetracing.js +8 -12
  103. package/dist/js/tracing/gesturetracing.js.map +1 -1
  104. package/dist/js/tracing/index.d.ts +6 -7
  105. package/dist/js/tracing/index.d.ts.map +1 -1
  106. package/dist/js/tracing/index.js +4 -7
  107. package/dist/js/tracing/index.js.map +1 -1
  108. package/dist/js/tracing/integrations/appStart.d.ts +39 -0
  109. package/dist/js/tracing/integrations/appStart.d.ts.map +1 -0
  110. package/dist/js/tracing/integrations/appStart.js +301 -0
  111. package/dist/js/tracing/integrations/appStart.js.map +1 -0
  112. package/dist/js/tracing/integrations/nativeFrames.d.ts +20 -0
  113. package/dist/js/tracing/integrations/nativeFrames.d.ts.map +1 -0
  114. package/dist/js/tracing/integrations/nativeFrames.js +256 -0
  115. package/dist/js/tracing/integrations/nativeFrames.js.map +1 -0
  116. package/dist/js/tracing/integrations/stalltracking.d.ts +31 -0
  117. package/dist/js/tracing/integrations/stalltracking.d.ts.map +1 -0
  118. package/dist/js/tracing/integrations/stalltracking.js +236 -0
  119. package/dist/js/tracing/integrations/stalltracking.js.map +1 -0
  120. package/dist/js/tracing/integrations/userInteraction.d.ts +11 -0
  121. package/dist/js/tracing/integrations/userInteraction.d.ts.map +1 -0
  122. package/dist/js/tracing/integrations/userInteraction.js +70 -0
  123. package/dist/js/tracing/integrations/userInteraction.js.map +1 -0
  124. package/dist/js/tracing/onSpanEndUtils.d.ts +17 -0
  125. package/dist/js/tracing/onSpanEndUtils.d.ts.map +1 -0
  126. package/dist/js/tracing/onSpanEndUtils.js +112 -0
  127. package/dist/js/tracing/onSpanEndUtils.js.map +1 -0
  128. package/dist/js/tracing/origin.d.ts +2 -0
  129. package/dist/js/tracing/origin.d.ts.map +1 -0
  130. package/dist/js/tracing/origin.js +2 -0
  131. package/dist/js/tracing/origin.js.map +1 -0
  132. package/dist/js/tracing/reactnativenavigation.d.ts +21 -39
  133. package/dist/js/tracing/reactnativenavigation.d.ts.map +1 -1
  134. package/dist/js/tracing/reactnativenavigation.js +98 -87
  135. package/dist/js/tracing/reactnativenavigation.js.map +1 -1
  136. package/dist/js/tracing/reactnativeprofiler.d.ts.map +1 -1
  137. package/dist/js/tracing/reactnativeprofiler.js +6 -13
  138. package/dist/js/tracing/reactnativeprofiler.js.map +1 -1
  139. package/dist/js/tracing/reactnativetracing.d.ts +44 -160
  140. package/dist/js/tracing/reactnativetracing.d.ts.map +1 -1
  141. package/dist/js/tracing/reactnativetracing.js +51 -481
  142. package/dist/js/tracing/reactnativetracing.js.map +1 -1
  143. package/dist/js/tracing/reactnavigation.d.ts +18 -63
  144. package/dist/js/tracing/reactnavigation.d.ts.map +1 -1
  145. package/dist/js/tracing/reactnavigation.js +197 -218
  146. package/dist/js/tracing/reactnavigation.js.map +1 -1
  147. package/dist/js/tracing/semanticAttributes.d.ts +12 -0
  148. package/dist/js/tracing/semanticAttributes.d.ts.map +1 -0
  149. package/dist/js/tracing/semanticAttributes.js +12 -0
  150. package/dist/js/tracing/semanticAttributes.js.map +1 -0
  151. package/dist/js/tracing/span.d.ts +52 -0
  152. package/dist/js/tracing/span.d.ts.map +1 -0
  153. package/dist/js/tracing/span.js +82 -0
  154. package/dist/js/tracing/span.js.map +1 -0
  155. package/dist/js/tracing/timetodisplay.d.ts.map +1 -1
  156. package/dist/js/tracing/timetodisplay.js +16 -29
  157. package/dist/js/tracing/timetodisplay.js.map +1 -1
  158. package/dist/js/tracing/timetodisplaynative.d.ts.map +1 -1
  159. package/dist/js/tracing/timetodisplaynative.js +5 -3
  160. package/dist/js/tracing/timetodisplaynative.js.map +1 -1
  161. package/dist/js/tracing/types.d.ts +2 -9
  162. package/dist/js/tracing/types.d.ts.map +1 -1
  163. package/dist/js/tracing/types.js.map +1 -1
  164. package/dist/js/tracing/utils.d.ts +23 -12
  165. package/dist/js/tracing/utils.d.ts.map +1 -1
  166. package/dist/js/tracing/utils.js +48 -52
  167. package/dist/js/tracing/utils.js.map +1 -1
  168. package/dist/js/transports/encodePolyfill.d.ts +3 -0
  169. package/dist/js/transports/encodePolyfill.d.ts.map +1 -0
  170. package/dist/js/transports/encodePolyfill.js +13 -0
  171. package/dist/js/transports/encodePolyfill.js.map +1 -0
  172. package/dist/js/transports/native.d.ts +2 -2
  173. package/dist/js/transports/native.d.ts.map +1 -1
  174. package/dist/js/transports/native.js +2 -1
  175. package/dist/js/transports/native.js.map +1 -1
  176. package/dist/js/utils/fill.d.ts +7 -0
  177. package/dist/js/utils/fill.d.ts.map +1 -0
  178. package/dist/js/utils/fill.js +9 -0
  179. package/dist/js/utils/fill.js.map +1 -0
  180. package/dist/js/utils/normalize.d.ts.map +1 -1
  181. package/dist/js/utils/normalize.js +8 -5
  182. package/dist/js/utils/normalize.js.map +1 -1
  183. package/dist/js/utils/rnlibraries.d.ts.map +1 -1
  184. package/dist/js/utils/rnlibraries.js +6 -0
  185. package/dist/js/utils/rnlibraries.js.map +1 -1
  186. package/dist/js/utils/rnlibrariesinterface.d.ts +3 -0
  187. package/dist/js/utils/rnlibrariesinterface.d.ts.map +1 -1
  188. package/dist/js/utils/rnlibrariesinterface.js.map +1 -1
  189. package/dist/js/utils/span.d.ts +19 -0
  190. package/dist/js/utils/span.d.ts.map +1 -0
  191. package/dist/js/utils/span.js +29 -0
  192. package/dist/js/utils/span.js.map +1 -0
  193. package/dist/js/vendor/react-native/index.d.ts +5 -1
  194. package/dist/js/vendor/react-native/index.d.ts.map +1 -1
  195. package/dist/js/vendor/react-native/index.js.map +1 -1
  196. package/dist/js/version.d.ts +1 -1
  197. package/dist/js/version.d.ts.map +1 -1
  198. package/dist/js/version.js +1 -1
  199. package/dist/js/version.js.map +1 -1
  200. package/dist/js/wrapper.d.ts.map +1 -1
  201. package/dist/js/wrapper.js +1 -0
  202. package/dist/js/wrapper.js.map +1 -1
  203. package/package.json +12 -13
  204. package/ts3.8/dist/js/client.d.ts +5 -9
  205. package/ts3.8/dist/js/index.d.ts +5 -10
  206. package/ts3.8/dist/js/integrations/debugsymbolicator.d.ts +2 -8
  207. package/ts3.8/dist/js/integrations/devicecontext.d.ts +2 -8
  208. package/ts3.8/dist/js/integrations/eventorigin.d.ts +2 -8
  209. package/ts3.8/dist/js/integrations/expocontext.d.ts +2 -8
  210. package/ts3.8/dist/js/integrations/exports.d.ts +4 -0
  211. package/ts3.8/dist/js/integrations/modulesloader.d.ts +2 -8
  212. package/ts3.8/dist/js/integrations/nativelinkederrors.d.ts +2 -8
  213. package/ts3.8/dist/js/integrations/reactnativeerrorhandlers.d.ts +2 -8
  214. package/ts3.8/dist/js/integrations/reactnativeinfo.d.ts +2 -8
  215. package/ts3.8/dist/js/integrations/release.d.ts +2 -8
  216. package/ts3.8/dist/js/integrations/screenshot.d.ts +2 -8
  217. package/ts3.8/dist/js/integrations/sdkinfo.d.ts +2 -8
  218. package/ts3.8/dist/js/integrations/spotlight.d.ts +2 -10
  219. package/ts3.8/dist/js/integrations/viewhierarchy.d.ts +2 -8
  220. package/ts3.8/dist/js/options.d.ts +43 -0
  221. package/ts3.8/dist/js/profiling/cache.d.ts +1 -1
  222. package/ts3.8/dist/js/profiling/hermes.d.ts +1 -1
  223. package/ts3.8/dist/js/profiling/integration.d.ts +1 -7
  224. package/ts3.8/dist/js/replay/mobilereplay.d.ts +2 -2
  225. package/ts3.8/dist/js/scopeSync.d.ts +6 -0
  226. package/ts3.8/dist/js/sdk.d.ts +1 -20
  227. package/ts3.8/dist/js/touchevents.d.ts +0 -1
  228. package/ts3.8/dist/js/tracing/gesturetracing.d.ts +1 -6
  229. package/ts3.8/dist/js/tracing/index.d.ts +6 -7
  230. package/ts3.8/dist/js/tracing/integrations/appStart.d.ts +39 -0
  231. package/ts3.8/dist/js/tracing/integrations/nativeFrames.d.ts +20 -0
  232. package/ts3.8/dist/js/tracing/integrations/stalltracking.d.ts +31 -0
  233. package/ts3.8/dist/js/tracing/integrations/userInteraction.d.ts +11 -0
  234. package/ts3.8/dist/js/tracing/onSpanEndUtils.d.ts +17 -0
  235. package/ts3.8/dist/js/tracing/origin.d.ts +2 -0
  236. package/ts3.8/dist/js/tracing/reactnativenavigation.d.ts +21 -39
  237. package/ts3.8/dist/js/tracing/reactnativetracing.d.ts +44 -160
  238. package/ts3.8/dist/js/tracing/reactnavigation.d.ts +18 -63
  239. package/ts3.8/dist/js/tracing/semanticAttributes.d.ts +12 -0
  240. package/ts3.8/dist/js/tracing/span.d.ts +52 -0
  241. package/ts3.8/dist/js/tracing/types.d.ts +2 -9
  242. package/ts3.8/dist/js/tracing/utils.d.ts +23 -12
  243. package/ts3.8/dist/js/transports/encodePolyfill.d.ts +3 -0
  244. package/ts3.8/dist/js/transports/native.d.ts +2 -2
  245. package/ts3.8/dist/js/utils/fill.d.ts +7 -0
  246. package/ts3.8/dist/js/utils/rnlibrariesinterface.d.ts +3 -0
  247. package/ts3.8/dist/js/utils/span.d.ts +19 -0
  248. package/ts3.8/dist/js/vendor/react-native/index.d.ts +5 -1
  249. package/ts3.8/dist/js/version.d.ts +1 -1
  250. package/dist/js/integrations/index.d.ts +0 -16
  251. package/dist/js/integrations/index.d.ts.map +0 -1
  252. package/dist/js/integrations/index.js +0 -17
  253. package/dist/js/integrations/index.js.map +0 -1
  254. package/dist/js/scope.d.ts +0 -54
  255. package/dist/js/scope.d.ts.map +0 -1
  256. package/dist/js/scope.js +0 -89
  257. package/dist/js/scope.js.map +0 -1
  258. package/dist/js/tracing/addTracingExtensions.d.ts +0 -8
  259. package/dist/js/tracing/addTracingExtensions.d.ts.map +0 -1
  260. package/dist/js/tracing/addTracingExtensions.js +0 -66
  261. package/dist/js/tracing/addTracingExtensions.js.map +0 -1
  262. package/dist/js/tracing/nativeframes.d.ts +0 -60
  263. package/dist/js/tracing/nativeframes.d.ts.map +0 -1
  264. package/dist/js/tracing/nativeframes.js +0 -210
  265. package/dist/js/tracing/nativeframes.js.map +0 -1
  266. package/dist/js/tracing/reactnavigationv4.d.ts +0 -92
  267. package/dist/js/tracing/reactnavigationv4.d.ts.map +0 -1
  268. package/dist/js/tracing/reactnavigationv4.js +0 -229
  269. package/dist/js/tracing/reactnavigationv4.js.map +0 -1
  270. package/dist/js/tracing/routingInstrumentation.d.ts +0 -52
  271. package/dist/js/tracing/routingInstrumentation.d.ts.map +0 -1
  272. package/dist/js/tracing/routingInstrumentation.js +0 -36
  273. package/dist/js/tracing/routingInstrumentation.js.map +0 -1
  274. package/dist/js/tracing/stalltracking.d.ts +0 -99
  275. package/dist/js/tracing/stalltracking.d.ts.map +0 -1
  276. package/dist/js/tracing/stalltracking.js +0 -286
  277. package/dist/js/tracing/stalltracking.js.map +0 -1
  278. package/dist/js/tracing/transaction.d.ts +0 -11
  279. package/dist/js/tracing/transaction.d.ts.map +0 -1
  280. package/dist/js/tracing/transaction.js +0 -37
  281. package/dist/js/tracing/transaction.js.map +0 -1
  282. package/dist/js/transports/TextEncoder.d.ts +0 -3
  283. package/dist/js/transports/TextEncoder.d.ts.map +0 -1
  284. package/dist/js/transports/TextEncoder.js +0 -12
  285. package/dist/js/transports/TextEncoder.js.map +0 -1
  286. package/ts3.8/dist/js/integrations/index.d.ts +0 -16
  287. package/ts3.8/dist/js/scope.d.ts +0 -54
  288. package/ts3.8/dist/js/tracing/addTracingExtensions.d.ts +0 -8
  289. package/ts3.8/dist/js/tracing/nativeframes.d.ts +0 -60
  290. package/ts3.8/dist/js/tracing/reactnavigationv4.d.ts +0 -92
  291. package/ts3.8/dist/js/tracing/routingInstrumentation.d.ts +0 -52
  292. package/ts3.8/dist/js/tracing/stalltracking.d.ts +0 -99
  293. package/ts3.8/dist/js/tracing/transaction.d.ts +0 -11
  294. package/ts3.8/dist/js/transports/TextEncoder.d.ts +0 -3
@@ -1,10 +1,4 @@
1
- import type { Integration, IntegrationClass, IntegrationFnResult } from '@sentry/types';
1
+ import type { Integration } from '@sentry/types';
2
2
  /** Load device context from native. */
3
- export declare const deviceContextIntegration: () => IntegrationFnResult;
4
- /**
5
- * Load device context from native.
6
- *
7
- * @deprecated Use `deviceContextIntegration()` instead.
8
- */
9
- export declare const DeviceContext: IntegrationClass<Integration>;
3
+ export declare const deviceContextIntegration: () => Integration;
10
4
  //# sourceMappingURL=devicecontext.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"devicecontext.d.ts","sourceRoot":"","sources":["../../../src/js/integrations/devicecontext.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAS,WAAW,EAAE,gBAAgB,EAAE,mBAAmB,EAAE,MAAM,eAAe,CAAC;AAU/F,uCAAuC;AACvC,eAAO,MAAM,wBAAwB,QAAO,mBAQ3C,CAAC;AAEF;;;;GAIG;AAEH,eAAO,MAAM,aAAa,+BAGQ,CAAC"}
1
+ {"version":3,"file":"devicecontext.d.ts","sourceRoot":"","sources":["../../../src/js/integrations/devicecontext.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAS,WAAW,EAAE,MAAM,eAAe,CAAC;AAUxD,uCAAuC;AACvC,eAAO,MAAM,wBAAwB,QAAO,WAQ3C,CAAC"}
@@ -1,6 +1,4 @@
1
1
  import { __awaiter } from "tslib";
2
- /* eslint-disable complexity */
3
- import { convertIntegrationFnToClass } from '@sentry/core';
4
2
  import { logger, severityLevelFromString } from '@sentry/utils';
5
3
  import { AppState } from 'react-native';
6
4
  import { breadcrumbFromObject } from '../breadcrumb';
@@ -16,13 +14,6 @@ export const deviceContextIntegration = () => {
16
14
  processEvent,
17
15
  };
18
16
  };
19
- /**
20
- * Load device context from native.
21
- *
22
- * @deprecated Use `deviceContextIntegration()` instead.
23
- */
24
- // eslint-disable-next-line deprecation/deprecation
25
- export const DeviceContext = convertIntegrationFnToClass(INTEGRATION_NAME, deviceContextIntegration);
26
17
  function processEvent(event) {
27
18
  var _a;
28
19
  return __awaiter(this, void 0, void 0, function* () {
@@ -1 +1 @@
1
- {"version":3,"file":"devicecontext.js","sourceRoot":"","sources":["../../../src/js/integrations/devicecontext.ts"],"names":[],"mappings":";AAAA,+BAA+B;AAC/B,OAAO,EAAE,2BAA2B,EAAE,MAAM,cAAc,CAAC;AAE3D,OAAO,EAAE,MAAM,EAAE,uBAAuB,EAAE,MAAM,eAAe,CAAC;AAChE,OAAO,EAAE,QAAQ,EAAE,MAAM,cAAc,CAAC;AAExC,OAAO,EAAE,oBAAoB,EAAE,MAAM,eAAe,CAAC;AAErD,OAAO,EAAE,MAAM,EAAE,MAA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AC,MAAM,CAAC,aAAa,CAAC,CAAC;YAC5D,CAAC,CAAC,MAAM,CAAC,aAAa,CAAC,CAAC,GAAG,CAAC,oBAAoB,CAAC;YACjD,CAAC,CAAC,SAAS,CAAC;QACd,IAAI,iBAAiB,EAAE;YACrB,KAAK,CAAC,WAAW,GAAG,iBAAiB,CAAC;SACvC;QAED,OAAO,KAAK,CAAC;;CACd","sourcesContent":["/* eslint-disable complexity */\nimport { convertIntegrationFnToClass } from '@sentry/core';\nimport type { Event, Integration, IntegrationClass, IntegrationFnResult } from '@sentry/types';\nimport { logger, severityLevelFromString } from '@sentry/utils';\nimport { AppState } from 'react-native';\n\nimport { breadcrumbFromObject } from '../breadcrumb';\nimport type { NativeDeviceContextsResponse } from '../NativeRNSentry';\nimport { NATIVE } from '../wrapper';\n\nconst INTEGRATION_NAME = 'DeviceContext';\n\n/** Load device context from native. */\nexport const deviceContextIntegration = (): IntegrationFnResult => {\n return {\n name: INTEGRATION_NAME,\n setupOnce: () => {\n /* noop */\n },\n processEvent,\n };\n};\n\n/**\n * Load device context from native.\n *\n * @deprecated Use `deviceContextIntegration()` instead.\n */\n// eslint-disable-next-line deprecation/deprecation\nexport const DeviceContext = convertIntegrationFnToClass(\n INTEGRATION_NAME,\n deviceContextIntegration,\n) as IntegrationClass<Integration>;\n\nasync function processEvent(event: Event): Promise<Event> {\n let native: NativeDeviceContextsResponse | null = null;\n try {\n native = await NATIVE.fetchNativeDeviceContexts();\n } catch (e) {\n logger.log(`Failed to get device context from native: ${e}`);\n }\n\n if (!native) {\n return event;\n }\n\n const nativeUser = native.user;\n if (!event.user && nativeUser) {\n event.user = nativeUser;\n }\n\n let nativeContexts = native.contexts;\n if (AppState.currentState !== 'unknown') {\n nativeContexts = nativeContexts || {};\n nativeContexts.app = {\n ...nativeContexts.app,\n in_foreground: AppState.currentState === 'active',\n };\n }\n if (nativeContexts) {\n event.contexts = { ...nativeContexts, ...event.contexts };\n if (nativeContexts.app) {\n event.contexts.app = { ...nativeContexts.app, ...event.contexts.app };\n }\n }\n\n const nativeTags = native.tags;\n if (nativeTags) {\n event.tags = { ...nativeTags, ...event.tags };\n }\n\n const nativeExtra = native.extra;\n if (nativeExtra) {\n event.extra = { ...nativeExtra, ...event.extra };\n }\n\n const nativeFingerprint = native.fingerprint;\n if (nativeFingerprint) {\n event.fingerprint = (event.fingerprint ?? []).concat(\n nativeFingerprint.filter(item => (event.fingerprint ?? []).indexOf(item) < 0),\n );\n }\n\n const nativeLevel = typeof native['level'] === 'string' ? severityLevelFromString(native['level']) : undefined;\n if (!event.level && nativeLevel) {\n event.level = nativeLevel;\n }\n\n const nativeEnvironment = native['environment'];\n if (!event.environment && nativeEnvironment) {\n event.environment = nativeEnvironment;\n }\n\n const nativeBreadcrumbs = Array.isArray(native['breadcrumbs'])\n ? native['breadcrumbs'].map(breadcrumbFromObject)\n : undefined;\n if (nativeBreadcrumbs) {\n event.breadcrumbs = nativeBreadcrumbs;\n }\n\n return event;\n}\n"]}
1
+ {"version":3,"file":"devicecontext.js","sourceRoot":"","sources":["../../../src/js/integrations/devicecontext.ts"],"names":[],"mappings":";AAEA,OAAO,EAAE,MAAM,EAAE,uBAAuB,EAAE,MAAM,eAAe,CAAC;AAChE,OAAO,EAAE,QAAQ,EAAE,MAAM,cAAc,CAAC;AAExC,OAAO,EAAE,oBAAoB,EAAE,MAAM,eAAe,CAAC;AAErD,OAAO,EAAE,MAAM,EAAE,MAAM,YAAY,CAAC;AAEpC,MAAM,gBAAgB,GAAG,eAAe,CAAC;AAEzC,uCAAuC;AACvC,MAAM,CAAC,MAAM,wBAAwB,GAAG,GAAgB,EAAE;IACxD,OAAO;QACL,IAAI,EAAE,gBAAgB;QACtB,SAAS,EAAE,GAAG,EAAE;YACd,UAAU;QACZ,CAAC;QACD,YAAY;KACb,CAAC;AACJ,CAAC,CAAC;AAEF,SAAe,YAAY,CAAC,KAAY;;;QACtC,IAAI,MAAM,GAAwC,IAAI,CAAC;QACvD,IAAI;YACF,MAAM,G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,iBAAiB,EAAE;YACrB,KAAK,CAAC,WAAW,GAAG,CAAC,MAAA,KAAK,CAAC,WAAW,mCAAI,EAAE,CAAC,CAAC,MAAM,CAClD,iBAAiB,CAAC,MAAM,CAAC,IAAI,CAAC,EAAE,WAAC,OAAA,CAAC,MAAA,KAAK,CAAC,WAAW,mCAAI,EAAE,CAAC,CAAC,OAAO,CAAC,IAAI,CAAC,GAAG,CAAC,CAAA,EAAA,CAAC,CAC9E,CAAC;SACH;QAED,MAAM,WAAW,GAAG,OAAO,MAAM,CAAC,OAAO,CAAC,KAAK,QAAQ,CAAC,CAAC,CAAC,uBAAuB,CAAC,MAAM,CAAC,OAAO,CAAC,CAAC,CAAC,CAAC,CAAC,SAAS,CAAC;QAC/G,IAAI,CAAC,KAAK,CAAC,KAAK,IAAI,WAAW,EAAE;YAC/B,KAAK,CAAC,KAAK,GAAG,WAAW,CAAC;SAC3B;QAED,MAAM,iBAAiB,GAAG,MAAM,CAAC,aAAa,CAAC,CAAC;QAChD,IAAI,CAAC,KAAK,CAAC,WAAW,IAAI,iBAAiB,EAAE;YAC3C,KAAK,CAAC,WAAW,GAAG,iBAAiB,CAAC;SACvC;QAED,MAAM,iBAAiB,GAAG,KAAK,CAAC,OAAO,CAAC,MAAM,CAAC,aAAa,CAAC,CAAC;YAC5D,CAAC,CAAC,MAAM,CAAC,aAAa,CAAC,CAAC,GAAG,CAAC,oBAAoB,CAAC;YACjD,CAAC,CAAC,SAAS,CAAC;QACd,IAAI,iBAAiB,EAAE;YACrB,KAAK,CAAC,WAAW,GAAG,iBAAiB,CAAC;SACvC;QAED,OAAO,KAAK,CAAC;;CACd","sourcesContent":["/* eslint-disable complexity */\nimport type { Event, Integration } from '@sentry/types';\nimport { logger, severityLevelFromString } from '@sentry/utils';\nimport { AppState } from 'react-native';\n\nimport { breadcrumbFromObject } from '../breadcrumb';\nimport type { NativeDeviceContextsResponse } from '../NativeRNSentry';\nimport { NATIVE } from '../wrapper';\n\nconst INTEGRATION_NAME = 'DeviceContext';\n\n/** Load device context from native. */\nexport const deviceContextIntegration = (): Integration => {\n return {\n name: INTEGRATION_NAME,\n setupOnce: () => {\n /* noop */\n },\n processEvent,\n };\n};\n\nasync function processEvent(event: Event): Promise<Event> {\n let native: NativeDeviceContextsResponse | null = null;\n try {\n native = await NATIVE.fetchNativeDeviceContexts();\n } catch (e) {\n logger.log(`Failed to get device context from native: ${e}`);\n }\n\n if (!native) {\n return event;\n }\n\n const nativeUser = native.user;\n if (!event.user && nativeUser) {\n event.user = nativeUser;\n }\n\n let nativeContexts = native.contexts;\n if (AppState.currentState !== 'unknown') {\n nativeContexts = nativeContexts || {};\n nativeContexts.app = {\n ...nativeContexts.app,\n in_foreground: AppState.currentState === 'active',\n };\n }\n if (nativeContexts) {\n event.contexts = { ...nativeContexts, ...event.contexts };\n if (nativeContexts.app) {\n event.contexts.app = { ...nativeContexts.app, ...event.contexts.app };\n }\n }\n\n const nativeTags = native.tags;\n if (nativeTags) {\n event.tags = { ...nativeTags, ...event.tags };\n }\n\n const nativeExtra = native.extra;\n if (nativeExtra) {\n event.extra = { ...nativeExtra, ...event.extra };\n }\n\n const nativeFingerprint = native.fingerprint;\n if (nativeFingerprint) {\n event.fingerprint = (event.fingerprint ?? []).concat(\n nativeFingerprint.filter(item => (event.fingerprint ?? []).indexOf(item) < 0),\n );\n }\n\n const nativeLevel = typeof native['level'] === 'string' ? severityLevelFromString(native['level']) : undefined;\n if (!event.level && nativeLevel) {\n event.level = nativeLevel;\n }\n\n const nativeEnvironment = native['environment'];\n if (!event.environment && nativeEnvironment) {\n event.environment = nativeEnvironment;\n }\n\n const nativeBreadcrumbs = Array.isArray(native['breadcrumbs'])\n ? native['breadcrumbs'].map(breadcrumbFromObject)\n : undefined;\n if (nativeBreadcrumbs) {\n event.breadcrumbs = nativeBreadcrumbs;\n }\n\n return event;\n}\n"]}
@@ -1,10 +1,4 @@
1
- import type { Integration, IntegrationClass, IntegrationFnResult } from '@sentry/types';
1
+ import type { Integration } from '@sentry/types';
2
2
  /** Default EventOrigin instrumentation */
3
- export declare const eventOriginIntegration: () => IntegrationFnResult;
4
- /**
5
- * Default EventOrigin instrumentation
6
- *
7
- * @deprecated Use `eventOriginIntegration()` instead.
8
- */
9
- export declare const EventOrigin: IntegrationClass<Integration>;
3
+ export declare const eventOriginIntegration: () => Integration;
10
4
  //# sourceMappingURL=eventorigin.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"eventorigin.d.ts","sourceRoot":"","sources":["../../../src/js/integrations/eventorigin.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAS,WAAW,EAAE,gBAAgB,EAAE,mBAAmB,EAAE,MAAM,eAAe,CAAC;AAI/F,0CAA0C;AAC1C,eAAO,MAAM,sBAAsB,QAAO,mBAezC,CAAC;AAEF;;;;GAIG;AAEH,eAAO,MAAM,WAAW,+BAGU,CAAC"}
1
+ {"version":3,"file":"eventorigin.d.ts","sourceRoot":"","sources":["../../../src/js/integrations/eventorigin.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAS,WAAW,EAAE,MAAM,eAAe,CAAC;AAIxD,0CAA0C;AAC1C,eAAO,MAAM,sBAAsB,QAAO,WAezC,CAAC"}
@@ -1,4 +1,3 @@
1
- import { convertIntegrationFnToClass } from '@sentry/core';
2
1
  const INTEGRATION_NAME = 'EventOrigin';
3
2
  /** Default EventOrigin instrumentation */
4
3
  export const eventOriginIntegration = () => {
@@ -16,11 +15,4 @@ export const eventOriginIntegration = () => {
16
15
  },
17
16
  };
18
17
  };
19
- /**
20
- * Default EventOrigin instrumentation
21
- *
22
- * @deprecated Use `eventOriginIntegration()` instead.
23
- */
24
- // eslint-disable-next-line deprecation/deprecation
25
- export const EventOrigin = convertIntegrationFnToClass(INTEGRATION_NAME, eventOriginIntegration);
26
18
  //# sourceMappingURL=eventorigin.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"eventorigin.js","sourceRoot":"","sources":["../../../src/js/integrations/eventorigin.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,2BAA2B,EAAE,MAAM,cAAc,CAAC;AAG3D,MAAM,gBAAgB,GAAG,aAAa,CAAC;AAEvC,0CAA0C;AAC1C,MAAM,CAAC,MAAM,sBAAsB,GAAG,GAAwB,EAAE;IAC9D,OAAO;QACL,IAAI,EAAE,gBAAgB;QACtB,SAAS,EAAE,GAAG,EAAE;YACd,OAAO;QACT,CAAC;QACD,YAAY,EAAE,CAAC,KAAY,EAAE,EAAE;;YAC7B,KAAK,CAAC,IAAI,GAAG,MAAA,KAAK,CAAC,IAAI,mCAAI,EAAE,CAAC;YAE9B,KAAK,CAAC,IAAI,CAAC,cAAc,CAAC,GAAG,YAAY,CAAC;YAC1C,KAAK,CAAC,IAAI,CAAC,mBAAmB,CAAC,GAAG,YAAY,CAAC;YAE/C,OAAO,KAAK,CAAC;QACf,CAAC;KACF,CAAC;AACJ,CAAC,CAAC;AAEF;;;;GAIG;AACH,mDAAmD;AACnD,MAAM,CAAC,MAAM,WAAW,GAAG,2BAA2B,CACpD,gBAAgB,EAChB,sBAAsB,CACU,CAAC","sourcesContent":["import { convertIntegrationFnToClass } from '@sentry/core';\nimport type { Event, Integration, IntegrationClass, IntegrationFnResult } from '@sentry/types';\n\nconst INTEGRATION_NAME = 'EventOrigin';\n\n/** Default EventOrigin instrumentation */\nexport const eventOriginIntegration = (): IntegrationFnResult => {\n return {\n name: INTEGRATION_NAME,\n setupOnce: () => {\n // noop\n },\n processEvent: (event: Event) => {\n event.tags = event.tags ?? {};\n\n event.tags['event.origin'] = 'javascript';\n event.tags['event.environment'] = 'javascript';\n\n return event;\n },\n };\n};\n\n/**\n * Default EventOrigin instrumentation\n *\n * @deprecated Use `eventOriginIntegration()` instead.\n */\n// eslint-disable-next-line deprecation/deprecation\nexport const EventOrigin = convertIntegrationFnToClass(\n INTEGRATION_NAME,\n eventOriginIntegration,\n) as IntegrationClass<Integration>;\n"]}
1
+ {"version":3,"file":"eventorigin.js","sourceRoot":"","sources":["../../../src/js/integrations/eventorigin.ts"],"names":[],"mappings":"AAEA,MAAM,gBAAgB,GAAG,aAAa,CAAC;AAEvC,0CAA0C;AAC1C,MAAM,CAAC,MAAM,sBAAsB,GAAG,GAAgB,EAAE;IACtD,OAAO;QACL,IAAI,EAAE,gBAAgB;QACtB,SAAS,EAAE,GAAG,EAAE;YACd,OAAO;QACT,CAAC;QACD,YAAY,EAAE,CAAC,KAAY,EAAE,EAAE;;YAC7B,KAAK,CAAC,IAAI,GAAG,MAAA,KAAK,CAAC,IAAI,mCAAI,EAAE,CAAC;YAE9B,KAAK,CAAC,IAAI,CAAC,cAAc,CAAC,GAAG,YAAY,CAAC;YAC1C,KAAK,CAAC,IAAI,CAAC,mBAAmB,CAAC,GAAG,YAAY,CAAC;YAE/C,OAAO,KAAK,CAAC;QACf,CAAC;KACF,CAAC;AACJ,CAAC,CAAC","sourcesContent":["import type { Event, Integration } from '@sentry/types';\n\nconst INTEGRATION_NAME = 'EventOrigin';\n\n/** Default EventOrigin instrumentation */\nexport const eventOriginIntegration = (): Integration => {\n return {\n name: INTEGRATION_NAME,\n setupOnce: () => {\n // noop\n },\n processEvent: (event: Event) => {\n event.tags = event.tags ?? {};\n\n event.tags['event.origin'] = 'javascript';\n event.tags['event.environment'] = 'javascript';\n\n return event;\n },\n };\n};\n"]}
@@ -1,10 +1,4 @@
1
- import type { Integration, IntegrationClass, IntegrationFnResult } from '@sentry/types';
1
+ import type { Integration } from '@sentry/types';
2
2
  /** Load device context from expo modules. */
3
- export declare const expoContextIntegration: () => IntegrationFnResult;
4
- /**
5
- * Load device context from expo modules.
6
- *
7
- * @deprecated Use `expoContextIntegration()` instead.
8
- */
9
- export declare const ExpoContext: IntegrationClass<Integration>;
3
+ export declare const expoContextIntegration: () => Integration;
10
4
  //# sourceMappingURL=expocontext.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"expocontext.d.ts","sourceRoot":"","sources":["../../../src/js/integrations/expocontext.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAGV,WAAW,EACX,gBAAgB,EAChB,mBAAmB,EAEpB,MAAM,eAAe,CAAC;AAMvB,6CAA6C;AAC7C,eAAO,MAAM,sBAAsB,QAAO,mBAQzC,CAAC;AAEF;;;;GAIG;AAEH,eAAO,MAAM,WAAW,+BAGU,CAAC"}
1
+ {"version":3,"file":"expocontext.d.ts","sourceRoot":"","sources":["../../../src/js/integrations/expocontext.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAwB,WAAW,EAAa,MAAM,eAAe,CAAC;AAMlF,6CAA6C;AAC7C,eAAO,MAAM,sBAAsB,QAAO,WAQzC,CAAC"}
@@ -1,4 +1,3 @@
1
- import { convertIntegrationFnToClass } from '@sentry/core';
2
1
  import { getExpoDevice } from '../utils/expomodules';
3
2
  const INTEGRATION_NAME = 'ExpoContext';
4
3
  /** Load device context from expo modules. */
@@ -11,13 +10,6 @@ export const expoContextIntegration = () => {
11
10
  processEvent,
12
11
  };
13
12
  };
14
- /**
15
- * Load device context from expo modules.
16
- *
17
- * @deprecated Use `expoContextIntegration()` instead.
18
- */
19
- // eslint-disable-next-line deprecation/deprecation
20
- export const ExpoContext = convertIntegrationFnToClass(INTEGRATION_NAME, expoContextIntegration);
21
13
  function processEvent(event) {
22
14
  const expoDeviceContext = getExpoDeviceContext();
23
15
  if (expoDeviceContext) {
@@ -1 +1 @@
1
- {"version":3,"file":"expocontext.js","sourceRoot":"","sources":["../../../src/js/integrations/expocontext.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,2BAA2B,EAAE,MAAM,cAAc,CAAC;AAU3D,OAAO,EAAE,aAAa,EAAE,MAAM,sBAAsB,CAAC;AAErD,MAAM,gBAAgB,GAAG,aAAa,CAAC;AAEvC,6CAA6C;AAC7C,MAAM,CAAC,MAAM,sBAAsB,GAAG,GAAwB,EAAE;IAC9D,OAAO;QACL,IAAI,EAAE,gBAAgB;QACtB,SAAS,EAAE,GAAG,EAAE;YACd,OAAO;QACT,CAAC;QACD,YAAY;KACb,C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AAO;QACL,KAAK,EAAE,UAAU,CAAC,SAAS;QAC3B,OAAO,EAAE,UAAU,CAAC,SAAS;QAC7B,IAAI,EAAE,UAAU,CAAC,MAAM;KACxB,CAAC;AACJ,CAAC","sourcesContent":["import { convertIntegrationFnToClass } from '@sentry/core';\nimport type {\n DeviceContext,\n Event,\n Integration,\n IntegrationClass,\n IntegrationFnResult,\n OsContext,\n} from '@sentry/types';\n\nimport { getExpoDevice } from '../utils/expomodules';\n\nconst INTEGRATION_NAME = 'ExpoContext';\n\n/** Load device context from expo modules. */\nexport const expoContextIntegration = (): IntegrationFnResult => {\n return {\n name: INTEGRATION_NAME,\n setupOnce: () => {\n // noop\n },\n processEvent,\n };\n};\n\n/**\n * Load device context from expo modules.\n *\n * @deprecated Use `expoContextIntegration()` instead.\n */\n// eslint-disable-next-line deprecation/deprecation\nexport const ExpoContext = convertIntegrationFnToClass(\n INTEGRATION_NAME,\n expoContextIntegration,\n) as IntegrationClass<Integration>;\n\nfunction processEvent(event: Event): Event {\n const expoDeviceContext = getExpoDeviceContext();\n if (expoDeviceContext) {\n event.contexts = event.contexts || {};\n event.contexts.device = { ...expoDeviceContext, ...event.contexts.device };\n }\n\n const expoOsContext = getExpoOsContext();\n if (expoOsContext) {\n event.contexts = event.contexts || {};\n event.contexts.os = { ...expoOsContext, ...event.contexts.os };\n }\n\n return event;\n}\n\n/**\n * Returns the Expo Device context if present\n */\nfunction getExpoDeviceContext(): DeviceContext | undefined {\n const expoDevice = getExpoDevice();\n\n if (!expoDevice) {\n return undefined;\n }\n\n return {\n name: expoDevice.deviceName,\n simulator: !expoDevice?.isDevice,\n model: expoDevice.modelName,\n manufacturer: expoDevice.manufacturer,\n memory_size: expoDevice.totalMemory,\n };\n}\n\n/**\n * Returns the Expo OS context if present\n */\nfunction getExpoOsContext(): OsContext | undefined {\n const expoDevice = getExpoDevice();\n\n if (!expoDevice) {\n return undefined;\n }\n\n return {\n build: expoDevice.osBuildId,\n version: expoDevice.osVersion,\n name: exp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U,CAAC,SAAS;QAC3B,YAAY,EAAE,UAAU,CAAC,YAAY;QACrC,WAAW,EAAE,UAAU,CAAC,WAAW;KACpC,CAAC;AACJ,CAAC;AAED;;GAEG;AACH,SAAS,gBAAgB;IACvB,MAAM,UAAU,GAAG,aAAa,EAAE,CAAC;IAEnC,IAAI,CAAC,UAAU,EAAE;QACf,OAAO,SAAS,CAAC;KAClB;IAED,OAAO;QACL,KAAK,EAAE,UAAU,CAAC,SAAS;QAC3B,OAAO,EAAE,UAAU,CAAC,SAAS;QAC7B,IAAI,EAAE,UAAU,CAAC,MAAM;KACxB,CAAC;AACJ,CAAC","sourcesContent":["import type { DeviceContext, Event, Integration, OsContext } from '@sentry/types';\n\nimport { getExpoDevice } from '../utils/expomodules';\n\nconst INTEGRATION_NAME = 'ExpoContext';\n\n/** Load device context from expo modules. */\nexport const expoContextIntegration = (): Integration => {\n return {\n name: INTEGRATION_NAME,\n setupOnce: () => {\n // noop\n },\n processEvent,\n };\n};\n\nfunction processEvent(event: Event): Event {\n const expoDeviceContext = getExpoDeviceContext();\n if (expoDeviceContext) {\n event.contexts = event.contexts || {};\n event.contexts.device = { ...expoDeviceContext, ...event.contexts.device };\n }\n\n const expoOsContext = getExpoOsContext();\n if (expoOsContext) {\n event.contexts = event.contexts || {};\n event.contexts.os = { ...expoOsContext, ...event.contexts.os };\n }\n\n return event;\n}\n\n/**\n * Returns the Expo Device context if present\n */\nfunction getExpoDeviceContext(): DeviceContext | undefined {\n const expoDevice = getExpoDevice();\n\n if (!expoDevice) {\n return undefined;\n }\n\n return {\n name: expoDevice.deviceName,\n simulator: !expoDevice?.isDevice,\n model: expoDevice.modelName,\n manufacturer: expoDevice.manufacturer,\n memory_size: expoDevice.totalMemory,\n };\n}\n\n/**\n * Returns the Expo OS context if present\n */\nfunction getExpoOsContext(): OsContext | undefined {\n const expoDevice = getExpoDevice();\n\n if (!expoDevice) {\n return undefined;\n }\n\n return {\n build: expoDevice.osBuildId,\n version: expoDevice.osVersion,\n name: expoDevice.osName,\n };\n}\n"]}
@@ -13,5 +13,9 @@ export { viewHierarchyIntegration } from './viewhierarchy';
13
13
  export { expoContextIntegration } from './expocontext';
14
14
  export { spotlightIntegration } from './spotlight';
15
15
  export { mobileReplayIntegration } from '../replay/mobilereplay';
16
+ export { appStartIntegration } from '../tracing/integrations/appStart';
17
+ export { nativeFramesIntegration } from '../tracing/integrations/nativeFrames';
18
+ export { stallTrackingIntegration } from '../tracing/integrations/stalltracking';
19
+ export { userInteractionIntegration } from '../tracing/integrations/userInteraction';
16
20
  export { breadcrumbsIntegration, browserApiErrorsIntegration, dedupeIntegration, functionToStringIntegration, globalHandlersIntegration as browserGlobalHandlersIntegration, httpClientIntegration, httpContextIntegration, inboundFiltersIntegration, linkedErrorsIntegration as browserLinkedErrorsIntegration, rewriteFramesIntegration, replayIntegration as browserReplayIntegration, } from '@sentry/react';
17
21
  //# sourceMappingURL=exports.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"exports.d.ts","sourceRoot":"","sources":["../../../src/js/integrations/exports.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,4BAA4B,EAAE,MAAM,qBAAqB,CAAC;AACnE,OAAO,EAAE,wBAAwB,EAAE,MAAM,iBAAiB,CAAC;AAC3D,OAAO,EAAE,mCAAmC,EAAE,MAAM,4BAA4B,CAAC;AACjF,OAAO,EAAE,6BAA6B,EAAE,MAAM,sBAAsB,CAAC;AACrE,OAAO,EAAE,wBAAwB,EAAE,MAAM,WAAW,CAAC;AACrD,OAAO,EAAE,sBAAsB,EAAE,MAAM,eAAe,CAAC;AACvD,OAAO,EAAE,kBAAkB,EAAE,MAAM,WAAW,CAAC;AAC/C,OAAO,EAAE,0BAA0B,EAAE,MAAM,mBAAmB,CAAC;AAC/D,OAAO,EAAE,wBAAwB,EAAE,MAAM,iBAAiB,CAAC;AAC3D,OAAO,EAAE,0BAA0B,EAAE,MAAM,0BAA0B,CAAC;AACtE,OAAO,EAAE,qBAAqB,EAAE,MAA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,OAAO,EAAE,oBAAoB,EAAE,MAAM,aAAa,CAAC;AACnD,OAAO,EAAE,uBAAuB,EAAE,MAAM,wBAAwB,CAAC;AACjE,OAAO,EAAE,mBAAmB,EAAE,MAAM,kCAAkC,CAAC;AACvE,OAAO,EAAE,uBAAuB,EAAE,MAAM,sCAAsC,CAAC;AAC/E,OAAO,EAAE,wBAAwB,EAAE,MAAM,uCAAuC,CAAC;AACjF,OAAO,EAAE,0BAA0B,EAAE,MAAM,yCAAyC,CAAC;AAErF,OAAO,EACL,sBAAsB,EACtB,2BAA2B,EAC3B,iBAAiB,EACjB,2BAA2B,EAC3B,yBAAyB,IAAI,gCAAgC,EAC7D,qBAAqB,EACrB,sBAAsB,EACtB,yBAAyB,EACzB,uBAAuB,IAAI,8BAA8B,EACzD,wBAAwB,EACxB,iBAAiB,IAAI,wBAAwB,GAC9C,MAAM,eAAe,CAAC"}
@@ -13,5 +13,9 @@ export { viewHierarchyIntegration } from './viewhierarchy';
13
13
  export { expoContextIntegration } from './expocontext';
14
14
  export { spotlightIntegration } from './spotlight';
15
15
  export { mobileReplayIntegration } from '../replay/mobilereplay';
16
+ export { appStartIntegration } from '../tracing/integrations/appStart';
17
+ export { nativeFramesIntegration } from '../tracing/integrations/nativeFrames';
18
+ export { stallTrackingIntegration } from '../tracing/integrations/stalltracking';
19
+ export { userInteractionIntegration } from '../tracing/integrations/userInteraction';
16
20
  export { breadcrumbsIntegration, browserApiErrorsIntegration, dedupeIntegration, functionToStringIntegration, globalHandlersIntegration as browserGlobalHandlersIntegration, httpClientIntegration, httpContextIntegration, inboundFiltersIntegration, linkedErrorsIntegration as browserLinkedErrorsIntegration, rewriteFramesIntegration, replayIntegration as browserReplayIntegration, } from '@sentry/react';
17
21
  //# sourceMappingURL=exports.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"exports.js","sourceRoot":"","sources":["../../../src/js/integrations/exports.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,4BAA4B,EAAE,MAAM,qBAAqB,CAAC;AACnE,OAAO,EAAE,wBAAwB,EAAE,MAAM,iBAAiB,CAAC;AAC3D,OAAO,EAAE,mCAAmC,EAAE,MAAM,4BAA4B,CAAC;AACjF,OAAO,EAAE,6BAA6B,EAAE,MAAM,sBAAsB,CAAC;AACrE,OAAO,EAAE,wBAAwB,EAAE,MAAM,WAAW,CAAC;AACrD,OAAO,EAAE,sBAAsB,EAAE,MAAM,eAAe,CAAC;AACvD,OAAO,EAAE,kBAAkB,EAAE,MAAM,WAAW,CAAC;AAC/C,OAAO,EAAE,0BAA0B,EAAE,MAAM,mBAAmB,CAAC;AAC/D,OAAO,EAAE,wBAAwB,EAAE,MAAM,iBAAiB,CAAC;AAC3D,OAAO,EAAE,0BAA0B,EAAE,MAAM,0BAA0B,CAAC;AACtE,OAAO,EAAE,qBAAqB,EAAE,MAAM,cAAc,CAAC;AACrD,OAAO,EAAE,wBAAwB,EAAE,MAAM,iBAAiB,CAAC;AAC3D,OAAO,EAAE,sBAAsB,EAAE,MAAM,eAAe,CAAC;AACvD,OAAO,EAAE,oBAAoB,EAAE,MAAM,aAAa,CAAC;AACnD,OAAO,EAAE,uBAAuB,EAAE,MAAM,wBAAwB,CAAC;AAEjE,OAAO,EACL,sBAAsB,EACtB,2BAA2B,EAC3B,iBAAiB,EACjB,2BAA2B,EAC3B,yBAAyB,IAAI,gCAAgC,EAC7D,qBAAqB,EACrB,sBAAsB,EACtB,yBAAyB,EACzB,uBAAuB,IAAI,8BAA8B,EACzD,wBAAwB,EACxB,iBAAiB,IAAI,wBAAwB,GAC9C,MAAM,eAAe,CAAC","sourcesContent":["export { debugSymbolicatorIntegration } from './debugsymbolicator';\nexport { deviceContextIntegration } from './devicecontext';\nexport { reactNativeErrorHandlersIntegration } from './reactnativeerrorhandlers';\nexport { nativeLinkedErrorsIntegration } from './nativelinkederrors';\nexport { nativeReleaseIntegration } from './release';\nexport { eventOriginIntegration } from './eventorigin';\nexport { sdkInfoIntegration } from './sdkinfo';\nexport { reactNativeInfoIntegration } from './reactnativeinfo';\nexport { modulesLoaderIntegration } from './modulesloader';\nexport { hermesProfilingIntegration } from '../profiling/integration';\nexport { screenshotIntegration } from './screenshot';\nexport { viewHierarchyIntegration } from './viewhierarchy';\nexport { expoContextIntegration } from './expocontext';\nexport { spotlightIntegration } from './spotlight';\nexport { mobileReplayIntegration } from '../replay/mobilereplay';\n\nexport {\n breadcrumbsIntegration,\n browserApiErrorsIntegration,\n dedupeIntegration,\n functionToStringIntegration,\n globalHandlersIntegration as browserGlobalHandlersIntegration,\n httpClientIntegration,\n httpContextIntegration,\n inboundFiltersIntegration,\n linkedErrorsIntegration as browserLinkedErrorsIntegration,\n rewriteFramesIntegration,\n replayIntegration as browserReplayIntegration,\n} from '@sentry/react';\n"]}
1
+ {"version":3,"file":"exports.js","sourceRoot":"","sources":["../../../src/js/integrations/exports.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,4BAA4B,EAAE,MAAM,qBAAqB,CAAC;AACnE,OAAO,EAAE,wBAAwB,EAAE,MAAM,iBAAiB,CAAC;AAC3D,OAAO,EAAE,mCAAmC,EAAE,MAAM,4BAA4B,CAAC;AACjF,OAAO,EAAE,6BAA6B,EAAE,MAAM,sBAAsB,CAAC;AACrE,OAAO,EAAE,wBAAwB,EAAE,MAAM,WAAW,CAAC;AACrD,OAAO,EAAE,sBAAsB,EAAE,MAAM,eAAe,CAAC;AACvD,OAAO,EAAE,kBAAkB,EAAE,MAAM,WAAW,CAAC;AAC/C,OAAO,EAAE,0BAA0B,EAAE,MAAM,mBAAmB,CAAC;AAC/D,OAAO,EAAE,wBAAwB,EAAE,MAAM,iBAAiB,CAAC;AAC3D,OAAO,EAAE,0BAA0B,EAAE,MAAM,0BAA0B,CAAC;AACtE,OAAO,EAAE,qBAAqB,EAAE,MAAM,cAAc,CAAC;AACrD,OAAO,EAAE,wBAAwB,EAAE,MAAM,iBAAiB,CAAC;AAC3D,OAAO,EAAE,sBAAsB,EAAE,MAAM,eAAe,CAAC;AACvD,OAAO,EAAE,oBAAoB,EAAE,MAAM,aAAa,CAAC;AACnD,OAAO,EAAE,uBAAuB,EAAE,MAAM,wBAAwB,CAAC;AACjE,OAAO,EAAE,mBAAmB,EAAE,MAAM,kCAAkC,CAAC;AACvE,OAAO,EAAE,uBAAuB,EAAE,MAAM,sCAAsC,CAAC;AAC/E,OAAO,EAAE,wBAAwB,EAAE,MAAM,uCAAuC,CAAC;AACjF,OAAO,EAAE,0BAA0B,EAAE,MAAM,yCAAyC,CAAC;AAErF,OAAO,EACL,sBAAsB,EACtB,2BAA2B,EAC3B,iBAAiB,EACjB,2BAA2B,EAC3B,yBAAyB,IAAI,gCAAgC,EAC7D,qBAAqB,EACrB,sBAAsB,EACtB,yBAAyB,EACzB,uBAAuB,IAAI,8BAA8B,EACzD,wBAAwB,EACxB,iBAAiB,IAAI,wBAAwB,GAC9C,MAAM,eAAe,CAAC","sourcesContent":["export { debugSymbolicatorIntegration } from './debugsymbolicator';\nexport { deviceContextIntegration } from './devicecontext';\nexport { reactNativeErrorHandlersIntegration } from './reactnativeerrorhandlers';\nexport { nativeLinkedErrorsIntegration } from './nativelinkederrors';\nexport { nativeReleaseIntegration } from './release';\nexport { eventOriginIntegration } from './eventorigin';\nexport { sdkInfoIntegration } from './sdkinfo';\nexport { reactNativeInfoIntegration } from './reactnativeinfo';\nexport { modulesLoaderIntegration } from './modulesloader';\nexport { hermesProfilingIntegration } from '../profiling/integration';\nexport { screenshotIntegration } from './screenshot';\nexport { viewHierarchyIntegration } from './viewhierarchy';\nexport { expoContextIntegration } from './expocontext';\nexport { spotlightIntegration } from './spotlight';\nexport { mobileReplayIntegration } from '../replay/mobilereplay';\nexport { appStartIntegration } from '../tracing/integrations/appStart';\nexport { nativeFramesIntegration } from '../tracing/integrations/nativeFrames';\nexport { stallTrackingIntegration } from '../tracing/integrations/stalltracking';\nexport { userInteractionIntegration } from '../tracing/integrations/userInteraction';\n\nexport {\n breadcrumbsIntegration,\n browserApiErrorsIntegration,\n dedupeIntegration,\n functionToStringIntegration,\n globalHandlersIntegration as browserGlobalHandlersIntegration,\n httpClientIntegration,\n httpContextIntegration,\n inboundFiltersIntegration,\n linkedErrorsIntegration as browserLinkedErrorsIntegration,\n rewriteFramesIntegration,\n replayIntegration as browserReplayIntegration,\n} from '@sentry/react';\n"]}
@@ -1,10 +1,4 @@
1
- import type { Integration, IntegrationClass, IntegrationFnResult } from '@sentry/types';
1
+ import type { Integration } from '@sentry/types';
2
2
  /** Loads runtime JS modules from prepared file. */
3
- export declare const modulesLoaderIntegration: () => IntegrationFnResult;
4
- /**
5
- * Loads runtime JS modules from prepared file.
6
- *
7
- * @deprecated Use `modulesLoaderIntegration()` instead.
8
- */
9
- export declare const ModulesLoader: IntegrationClass<Integration>;
3
+ export declare const modulesLoaderIntegration: () => Integration;
10
4
  //# sourceMappingURL=modulesloader.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"modulesloader.d.ts","sourceRoot":"","sources":["../../../src/js/integrations/modulesloader.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAS,WAAW,EAAE,gBAAgB,EAAE,mBAAmB,EAAE,MAAM,eAAe,CAAC;AAO/F,mDAAmD;AACnD,eAAO,MAAM,wBAAwB,QAAO,mBAQ3C,CAAC;AAEF;;;;GAIG;AAEH,eAAO,MAAM,aAAa,+BAGQ,CAAC"}
1
+ {"version":3,"file":"modulesloader.d.ts","sourceRoot":"","sources":["../../../src/js/integrations/modulesloader.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAS,WAAW,EAAE,MAAM,eAAe,CAAC;AAOxD,mDAAmD;AACnD,eAAO,MAAM,wBAAwB,QAAO,WAQ3C,CAAC"}
@@ -1,5 +1,4 @@
1
1
  import { __awaiter } from "tslib";
2
- import { convertIntegrationFnToClass } from '@sentry/core';
3
2
  import { logger } from '@sentry/utils';
4
3
  import { NATIVE } from '../wrapper';
5
4
  const INTEGRATION_NAME = 'ModulesLoader';
@@ -13,13 +12,6 @@ export const modulesLoaderIntegration = () => {
13
12
  processEvent: createProcessEvent(),
14
13
  };
15
14
  };
16
- /**
17
- * Loads runtime JS modules from prepared file.
18
- *
19
- * @deprecated Use `modulesLoaderIntegration()` instead.
20
- */
21
- // eslint-disable-next-line deprecation/deprecation
22
- export const ModulesLoader = convertIntegrationFnToClass(INTEGRATION_NAME, modulesLoaderIntegration);
23
15
  function createProcessEvent() {
24
16
  let isSetup = false;
25
17
  let modules = null;
@@ -1 +1 @@
1
- {"version":3,"file":"modulesloader.js","sourceRoot":"","sources":["../../../src/js/integrations/modulesloader.ts"],"names":[],"mappings":";AAAA,OAAO,EAAE,2BAA2B,EAAE,MAAM,cAAc,CAAC;AAE3D,OAAO,EAAE,MAAM,EAAE,MAAM,eAAe,CAAC;AAEvC,OAAO,EAAE,MAAM,EAAE,MAAM,YAAY,CAAC;AAEpC,MAAM,gBAAgB,GAAG,eAAe,CAAC;AAEzC,mDAAmD;AACnD,MAAM,CAAC,MAAM,wBAAwB,GAAG,GAAwB,EAAE;IAChE,OAAO;QACL,IAAI,EAAE,gBAAgB;QACtB,SAAS,EAAE,GAAG,EAAE;YACd,OAAO;QACT,CAAC;QACD,YAAY,EAAE,kBAAkB,EAAE;KACnC,CAAC;AACJ,CAAC,CAAC;AAEF;;;;GAIG;AACH,mDAAmD;AACnD,MAAM,CAAC,MAAM,aAAa,GAAG,2BAA2B,CACtD,gBAAgB,EAChB,wBAAwB,CACQ,CAAC;AAEnC,SAAS,kBAAkB;IACzB,IAAI,OAAO,GAAG,KAAK,CAAC;IACpB,IAAI,OAAO,GAAkC,IAAI,CAAC;IAElD,OAAO,CAAO,KAAY,EAAE,EAAE;QAC5B,IAAI,CAAC,OAAO,EAAE;YACZ,IAAI;gBACF,OAAO,GAAG,MAAM,MAAM,CAAC,YAAY,EAAE,CAAC;aACvC;YAAC,OAAO,CAAC,EAAE;gBACV,MAAM,CAAC,GAAG,CAAC,sCAAsC,CAAC,EAAE,CAAC,CAAC;aACvD;YACD,OAAO,GAAG,IAAI,CAAC;SAChB;QACD,IAAI,OAAO,EAAE;YACX,KAAK,CAAC,OAAO,mCACR,OAAO,GACP,KAAK,CAAC,OAAO,CACjB,CAAC;SACH;QACD,OAAO,KAAK,CAAC;IACf,CAAC,CAAA,CAAC;AACJ,CAAC","sourcesContent":["import { convertIntegrationFnToClass } from '@sentry/core';\nimport type { Event, Integration, IntegrationClass, IntegrationFnResult } from '@sentry/types';\nimport { logger } from '@sentry/utils';\n\nimport { NATIVE } from '../wrapper';\n\nconst INTEGRATION_NAME = 'ModulesLoader';\n\n/** Loads runtime JS modules from prepared file. */\nexport const modulesLoaderIntegration = (): IntegrationFnResult => {\n return {\n name: INTEGRATION_NAME,\n setupOnce: () => {\n // noop\n },\n processEvent: createProcessEvent(),\n };\n};\n\n/**\n * Loads runtime JS modules from prepared file.\n *\n * @deprecated Use `modulesLoaderIntegration()` instead.\n */\n// eslint-disable-next-line deprecation/deprecation\nexport const ModulesLoader = convertIntegrationFnToClass(\n INTEGRATION_NAME,\n modulesLoaderIntegration,\n) as IntegrationClass<Integration>;\n\nfunction createProcessEvent(): (event: Event) => Promise<Event> {\n let isSetup = false;\n let modules: Record<string, string> | null = null;\n\n return async (event: Event) => {\n if (!isSetup) {\n try {\n modules = await NATIVE.fetchModules();\n } catch (e) {\n logger.log(`Failed to get modules from native: ${e}`);\n }\n isSetup = true;\n }\n if (modules) {\n event.modules = {\n ...modules,\n ...event.modules,\n };\n }\n return event;\n };\n}\n"]}
1
+ {"version":3,"file":"modulesloader.js","sourceRoot":"","sources":["../../../src/js/integrations/modulesloader.ts"],"names":[],"mappings":";AACA,OAAO,EAAE,MAAM,EAAE,MAAM,eAAe,CAAC;AAEvC,OAAO,EAAE,MAAM,EAAE,MAAM,YAAY,CAAC;AAEpC,MAAM,gBAAgB,GAAG,eAAe,CAAC;AAEzC,mDAAmD;AACnD,MAAM,CAAC,MAAM,wBAAwB,GAAG,GAAgB,EAAE;IACxD,OAAO;QACL,IAAI,EAAE,gBAAgB;QACtB,SAAS,EAAE,GAAG,EAAE;YACd,OAAO;QACT,CAAC;QACD,YAAY,EAAE,kBAAkB,EAAE;KACnC,CAAC;AACJ,CAAC,CAAC;AAEF,SAAS,kBAAkB;IACzB,IAAI,OAAO,GAAG,KAAK,CAAC;IACpB,IAAI,OAAO,GAAkC,IAAI,CAAC;IAElD,OAAO,CAAO,KAAY,EAAE,EAAE;QAC5B,IAAI,CAAC,OAAO,EAAE;YACZ,IAAI;gBACF,OAAO,GAAG,MAAM,MAAM,CAAC,YAAY,EAAE,CAAC;aACvC;YAAC,OAAO,CAAC,EAAE;gBACV,MAAM,CAAC,GAAG,CAAC,sCAAsC,CAAC,EAAE,CAAC,CAAC;aACvD;YACD,OAAO,GAAG,IAAI,CAAC;SAChB;QACD,IAAI,OAAO,EAAE;YACX,KAAK,CAAC,OAAO,mCACR,OAAO,GACP,KAAK,CAAC,OAAO,CACjB,CAAC;SACH;QACD,OAAO,KAAK,CAAC;IACf,CAAC,CAAA,CAAC;AACJ,CAAC","sourcesContent":["import type { Event, Integration } from '@sentry/types';\nimport { logger } from '@sentry/utils';\n\nimport { NATIVE } from '../wrapper';\n\nconst INTEGRATION_NAME = 'ModulesLoader';\n\n/** Loads runtime JS modules from prepared file. */\nexport const modulesLoaderIntegration = (): Integration => {\n return {\n name: INTEGRATION_NAME,\n setupOnce: () => {\n // noop\n },\n processEvent: createProcessEvent(),\n };\n};\n\nfunction createProcessEvent(): (event: Event) => Promise<Event> {\n let isSetup = false;\n let modules: Record<string, string> | null = null;\n\n return async (event: Event) => {\n if (!isSetup) {\n try {\n modules = await NATIVE.fetchModules();\n } catch (e) {\n logger.log(`Failed to get modules from native: ${e}`);\n }\n isSetup = true;\n }\n if (modules) {\n event.modules = {\n ...modules,\n ...event.modules,\n };\n }\n return event;\n };\n}\n"]}
@@ -1,4 +1,4 @@
1
- import type { Integration, IntegrationClass, IntegrationFnResult } from '@sentry/types';
1
+ import type { Integration } from '@sentry/types';
2
2
  interface LinkedErrorsOptions {
3
3
  key: string;
4
4
  limit: number;
@@ -6,12 +6,6 @@ interface LinkedErrorsOptions {
6
6
  /**
7
7
  * Processes JS and RN native linked errors.
8
8
  */
9
- export declare const nativeLinkedErrorsIntegration: (options?: Partial<LinkedErrorsOptions>) => IntegrationFnResult;
10
- /**
11
- * Processes JS and RN native linked errors.
12
- *
13
- * @deprecated Use `nativeLinkedErrorsIntegration()` instead.
14
- */
15
- export declare const NativeLinkedErrors: IntegrationClass<Integration> & (new (options?: Partial<LinkedErrorsOptions>) => Integration);
9
+ export declare const nativeLinkedErrorsIntegration: (options?: Partial<LinkedErrorsOptions>) => Integration;
16
10
  export {};
17
11
  //# sourceMappingURL=nativelinkederrors.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"nativelinkederrors.d.ts","sourceRoot":"","sources":["../../../src/js/integrations/nativelinkederrors.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAOV,WAAW,EACX,gBAAgB,EAChB,mBAAmB,EAGpB,MAAM,eAAe,CAAC;AAWvB,UAAU,mBAAmB;IAC3B,GAAG,EAAE,MAAM,CAAC;IACZ,KAAK,EAAE,MAAM,CAAC;CACf;AAED;;GAEG;AACH,eAAO,MAAM,6BAA6B,aAAa,QAAQ,mBAAmB,CAAC,KAAQ,mBAY1F,CAAC;AAEF;;;;GAIG;AAEH,eAAO,MAAM,kBAAkB,kDAId,QAAQ,mBAAmB,CAAC,KAAG,WAAW,CAC1D,CAAC"}
1
+ {"version":3,"file":"nativelinkederrors.d.ts","sourceRoot":"","sources":["../../../src/js/integrations/nativelinkederrors.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAOV,WAAW,EAGZ,MAAM,eAAe,CAAC;AAWvB,UAAU,mBAAmB;IAC3B,GAAG,EAAE,MAAM,CAAC;IACZ,KAAK,EAAE,MAAM,CAAC;CACf;AAED;;GAEG;AACH,eAAO,MAAM,6BAA6B,aAAa,QAAQ,mBAAmB,CAAC,KAAQ,WAY1F,CAAC"}
@@ -1,5 +1,4 @@
1
1
  import { exceptionFromError } from '@sentry/browser';
2
- import { convertIntegrationFnToClass } from '@sentry/core';
3
2
  import { isInstanceOf, isPlainObject } from '@sentry/utils';
4
3
  import { NATIVE } from '../wrapper';
5
4
  const INTEGRATION_NAME = 'NativeLinkedErrors';
@@ -19,13 +18,6 @@ export const nativeLinkedErrorsIntegration = (options = {}) => {
19
18
  preprocessEvent: (event, hint, client) => preprocessEvent(event, hint, client, limit, key),
20
19
  };
21
20
  };
22
- /**
23
- * Processes JS and RN native linked errors.
24
- *
25
- * @deprecated Use `nativeLinkedErrorsIntegration()` instead.
26
- */
27
- // eslint-disable-next-line deprecation/deprecation
28
- export const NativeLinkedErrors = convertIntegrationFnToClass(INTEGRATION_NAME, nativeLinkedErrorsIntegration);
29
21
  function preprocessEvent(event, hint, client, limit, key) {
30
22
  if (!event.exception || !event.exception.values || !hint || !isInstanceOf(hint.originalException, Error)) {
31
23
  return;
@@ -1 +1 @@
1
- {"version":3,"file":"nativelinkederrors.js","sourceRoot":"","sources":["../../../src/js/integrations/nativelinkederrors.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,kBAAkB,EAAE,MAAM,iBAAiB,CAAC;AACrD,OAAO,EAAE,2BAA2B,EAAE,MAAM,cAAc,CAAC;AAc3D,OAAO,EAAE,YAAY,EAAE,aAAa,EAAE,MAAM,eAAe,CAAC;AAG5D,OAAO,EAAE,MAAM,EAAE,MAAM,YAAY,CAAC;AAEpC,MAAM,gBAAgB,GAAG,oBAAoB,CAAC;AAE9C,MAAM,WAAW,GAAG,OAAO,CAAC;AAC5B,MAAM,aAAa,GAAG,CAAC,CAAC;AAOxB;;GAEG;AACH,MAAM,CAAC,MAAM,6BAA6B,GAAG,CAAC,UAAwC,EAAE,EAAuB,EAAE;IAC/G,MAAM,GAAG,GAAG,OAAO,CAAC,GAAG,IAAI,WAAW,CAAC;IACvC,MAAM,KAAK,GAAG,OAAO,CAAC,KAAK,IAAI,aAAa,CAAC;IAE7C,OAAO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AC,iBAAiB,IAAK,iBAAiB,CAAC,eAAgC,CAAC,IAAI,EAAE;KACnG,CAAC;AACJ,CAAC;AAED,IAAI,aAAa,GAAkB,IAAI,CAAC;AACxC;;GAEG;AACH,SAAS,kBAAkB;IACzB,IAAI,aAAa,KAAK,IAAI,EAAE;QAC1B,aAAa,GAAG,MAAM,CAAC,sBAAsB,EAAE,CAAC;KACjD;IACD,OAAO,aAAa,CAAC;AACvB,CAAC;AAED;;GAEG;AACH,SAAS,sBAAsB,CAAC,gBAA0B;IACxD,OAAO,MAAM,CAAC,wBAAwB,CAAC,gBAAgB,CAAC,CAAC;AAC3D,CAAC","sourcesContent":["import { exceptionFromError } from '@sentry/browser';\nimport { convertIntegrationFnToClass } from '@sentry/core';\nimport type {\n Client,\n DebugImage,\n Event,\n EventHint,\n Exception,\n ExtendedError,\n Integration,\n IntegrationClass,\n IntegrationFnResult,\n StackFrame,\n StackParser,\n} from '@sentry/types';\nimport { isInstanceOf, isPlainObject } from '@sentry/utils';\n\nimport type { NativeStackFrames } from '../NativeRNSentry';\nimport { NATIVE } from '../wrapper';\n\nconst INTEGRATION_NAME = 'NativeLinkedErrors';\n\nconst DEFAULT_KEY = 'cause';\nconst DEFAULT_LIMIT = 5;\n\ninterface LinkedErrorsOptions {\n key: string;\n limit: number;\n}\n\n/**\n * Processes JS and RN native linked errors.\n */\nexport const nativeLinkedErrorsIntegration = (options: Partial<LinkedErrorsOptions> = {}): IntegrationFnResult => {\n const key = options.key || DEFAULT_KEY;\n const limit = options.limit || DEFAULT_LIMIT;\n\n return {\n name: INTEGRATION_NAME,\n setupOnce: (): void => {\n // noop\n },\n preprocessEvent: (event: Event, hint: EventHint, client: Client): void =>\n preprocessEvent(event, hint, client, limit, key),\n };\n};\n\n/**\n * Processes JS and RN native linked errors.\n *\n * @deprecated Use `nativeLinkedErrorsIntegration()` instead.\n */\n// eslint-disable-next-line deprecation/deprecation\nexport const NativeLinkedErrors = convertIntegrationFnToClass(\n INTEGRATION_NAME,\n nativeLinkedErrorsIntegration,\n) as IntegrationClass<Integration> & {\n new (options?: Partial<LinkedErrorsOptions>): Integration;\n};\n\nfunction preprocessEvent(event: Event, hint: EventHint | undefined, client: Client, limit: number, key: string): void {\n if (!event.exception || !event.exception.values || !hint || !isInstanceOf(hint.originalException, Error)) {\n return;\n }\n\n const parser = client.getOptions().stackParser;\n\n const { exceptions: linkedErrors, debugImages } = walkErrorTree(\n parser,\n limit,\n hint.originalException as ExtendedError,\n key,\n );\n event.exception.values = [...event.exception.values, ...linkedErrors];\n\n event.debug_meta = event.debug_meta || {};\n event.debug_meta.images = event.debug_meta.images || [];\n event.debug_meta.images.push(...(debugImages || []));\n}\n\n/**\n * Walks linked errors and created Sentry exceptions chain.\n * Collects debug images from native errors stack frames.\n */\nfunction walkErrorTree(\n parser: StackParser,\n limit: number,\n error: ExtendedError,\n key: string,\n exceptions: Exception[] = [],\n debugImages: DebugImage[] = [],\n): {\n exceptions: Exception[];\n debugImages?: DebugImage[];\n} {\n const linkedError = error[key];\n if (!linkedError || exceptions.length + 1 >= limit) {\n return {\n exceptions,\n debugImages,\n };\n }\n\n let exception: Exception;\n let exceptionDebugImages: DebugImage[] | undefined;\n if ('stackElements' in linkedError) {\n // isJavaException\n exception = exceptionFromJavaStackElements(linkedError);\n } else if ('stackReturnAddresses' in linkedError) {\n // isObjCException\n const { appleException, appleDebugImages } = exceptionFromAppleStackReturnAddresses(linkedError);\n exception = appleException;\n exceptionDebugImages = appleDebugImages;\n } else if (isInstanceOf(linkedError, Error)) {\n exception = exceptionFromError(parser, error[key]);\n } else if (isPlainObject(linkedError)) {\n exception = {\n type: typeof linkedError.name === 'string' ? linkedError.name : undefined,\n value: typeof linkedError.message === 'string' ? linkedError.message : undefined,\n };\n } else {\n return {\n exceptions,\n debugImages,\n };\n }\n\n return walkErrorTree(\n parser,\n limit,\n linkedError,\n key,\n [...exceptions, exception],\n [...debugImages, ...(exceptionDebugImages || [])],\n );\n}\n\n/**\n * Converts a Java Throwable to an SentryException\n */\nfunction exceptionFromJavaStackElements(javaThrowable: {\n name: string;\n message: string;\n stackElements: {\n className: string;\n fileName: string;\n methodName: string;\n lineNumber: number;\n }[];\n}): Exception {\n const nativePackage = fetchNativePackage();\n return {\n type: javaThrowable.name,\n value: javaThrowable.message,\n stacktrace: {\n frames: javaThrowable.stackElements\n .map(\n stackElement =>\n <StackFrame>{\n platform: 'java',\n module: stackElement.className,\n filename: stackElement.fileName,\n lineno: stackElement.lineNumber >= 0 ? stackElement.lineNumber : undefined,\n function: stackElement.methodName,\n in_app: nativePackage !== null && stackElement.className.startsWith(nativePackage) ? true : undefined,\n },\n )\n .reverse(),\n },\n };\n}\n\n/**\n * Converts StackAddresses to a SentryException with DebugMetaImages\n */\nfunction exceptionFromAppleStackReturnAddresses(objCException: {\n name: string;\n message: string;\n stackReturnAddresses: number[];\n}): {\n appleException: Exception;\n appleDebugImages: DebugImage[];\n} {\n const nativeStackFrames = fetchNativeStackFrames(objCException.stackReturnAddresses);\n\n return {\n appleException: {\n type: objCException.name,\n value: objCException.message,\n stacktrace: {\n frames: (nativeStackFrames && nativeStackFrames.frames.reverse()) || [],\n },\n },\n appleDebugImages: (nativeStackFrames && (nativeStackFrames.debugMetaImages as DebugImage[])) || [],\n };\n}\n\nlet nativePackage: string | null = null;\n/**\n * Fetches the native package/image name from the native layer\n */\nfunction fetchNativePackage(): string | null {\n if (nativePackage === null) {\n nativePackage = NATIVE.fetchNativePackageName();\n }\n return nativePackage;\n}\n\n/**\n * Fetches native debug image information on iOS\n */\nfunction fetchNativeStackFrames(instructionsAddr: number[]): NativeStackFrames | null {\n return NATIVE.fetchNativeStackFramesBy(instructionsAddr);\n}\n"]}
1
+ {"version":3,"file":"nativelinkederrors.js","sourceRoot":"","sources":["../../../src/js/integrations/nativelinkederrors.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,kBAAkB,EAAE,MAAM,iBAAiB,CAAC;AAYrD,OAAO,EAAE,YAAY,EAAE,aAAa,EAAE,M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aAAa,CAAC,oBAAoB,CAAC,CAAC;IAErF,OAAO;QACL,cAAc,EAAE;YACd,IAAI,EAAE,aAAa,CAAC,IAAI;YACxB,KAAK,EAAE,aAAa,CAAC,OAAO;YAC5B,UAAU,EAAE;gBACV,MAAM,EAAE,CAAC,iBAAiB,IAAI,iBAAiB,CAAC,MAAM,CAAC,OAAO,EAAE,CAAC,IAAI,EAAE;aACxE;SACF;QACD,gBAAgB,EAAE,CAAC,iBAAiB,IAAK,iBAAiB,CAAC,eAAgC,CAAC,IAAI,EAAE;KACnG,CAAC;AACJ,CAAC;AAED,IAAI,aAAa,GAAkB,IAAI,CAAC;AACxC;;GAEG;AACH,SAAS,kBAAkB;IACzB,IAAI,aAAa,KAAK,IAAI,EAAE;QAC1B,aAAa,GAAG,MAAM,CAAC,sBAAsB,EAAE,CAAC;KACjD;IACD,OAAO,aAAa,CAAC;AACvB,CAAC;AAED;;GAEG;AACH,SAAS,sBAAsB,CAAC,gBAA0B;IACxD,OAAO,MAAM,CAAC,wBAAwB,CAAC,gBAAgB,CAAC,CAAC;AAC3D,CAAC","sourcesContent":["import { exceptionFromError } from '@sentry/browser';\nimport type {\n Client,\n DebugImage,\n Event,\n EventHint,\n Exception,\n ExtendedError,\n Integration,\n StackFrame,\n StackParser,\n} from '@sentry/types';\nimport { isInstanceOf, isPlainObject } from '@sentry/utils';\n\nimport type { NativeStackFrames } from '../NativeRNSentry';\nimport { NATIVE } from '../wrapper';\n\nconst INTEGRATION_NAME = 'NativeLinkedErrors';\n\nconst DEFAULT_KEY = 'cause';\nconst DEFAULT_LIMIT = 5;\n\ninterface LinkedErrorsOptions {\n key: string;\n limit: number;\n}\n\n/**\n * Processes JS and RN native linked errors.\n */\nexport const nativeLinkedErrorsIntegration = (options: Partial<LinkedErrorsOptions> = {}): Integration => {\n const key = options.key || DEFAULT_KEY;\n const limit = options.limit || DEFAULT_LIMIT;\n\n return {\n name: INTEGRATION_NAME,\n setupOnce: (): void => {\n // noop\n },\n preprocessEvent: (event: Event, hint: EventHint, client: Client): void =>\n preprocessEvent(event, hint, client, limit, key),\n };\n};\n\nfunction preprocessEvent(event: Event, hint: EventHint | undefined, client: Client, limit: number, key: string): void {\n if (!event.exception || !event.exception.values || !hint || !isInstanceOf(hint.originalException, Error)) {\n return;\n }\n\n const parser = client.getOptions().stackParser;\n\n const { exceptions: linkedErrors, debugImages } = walkErrorTree(\n parser,\n limit,\n hint.originalException as ExtendedError,\n key,\n );\n event.exception.values = [...event.exception.values, ...linkedErrors];\n\n event.debug_meta = event.debug_meta || {};\n event.debug_meta.images = event.debug_meta.images || [];\n event.debug_meta.images.push(...(debugImages || []));\n}\n\n/**\n * Walks linked errors and created Sentry exceptions chain.\n * Collects debug images from native errors stack frames.\n */\nfunction walkErrorTree(\n parser: StackParser,\n limit: number,\n error: ExtendedError,\n key: string,\n exceptions: Exception[] = [],\n debugImages: DebugImage[] = [],\n): {\n exceptions: Exception[];\n debugImages?: DebugImage[];\n} {\n const linkedError = error[key];\n if (!linkedError || exceptions.length + 1 >= limit) {\n return {\n exceptions,\n debugImages,\n };\n }\n\n let exception: Exception;\n let exceptionDebugImages: DebugImage[] | undefined;\n if ('stackElements' in linkedError) {\n // isJavaException\n exception = exceptionFromJavaStackElements(linkedError);\n } else if ('stackReturnAddresses' in linkedError) {\n // isObjCException\n const { appleException, appleDebugImages } = exceptionFromAppleStackReturnAddresses(linkedError);\n exception = appleException;\n exceptionDebugImages = appleDebugImages;\n } else if (isInstanceOf(linkedError, Error)) {\n exception = exceptionFromError(parser, error[key]);\n } else if (isPlainObject(linkedError)) {\n exception = {\n type: typeof linkedError.name === 'string' ? linkedError.name : undefined,\n value: typeof linkedError.message === 'string' ? linkedError.message : undefined,\n };\n } else {\n return {\n exceptions,\n debugImages,\n };\n }\n\n return walkErrorTree(\n parser,\n limit,\n linkedError,\n key,\n [...exceptions, exception],\n [...debugImages, ...(exceptionDebugImages || [])],\n );\n}\n\n/**\n * Converts a Java Throwable to an SentryException\n */\nfunction exceptionFromJavaStackElements(javaThrowable: {\n name: string;\n message: string;\n stackElements: {\n className: string;\n fileName: string;\n methodName: string;\n lineNumber: number;\n }[];\n}): Exception {\n const nativePackage = fetchNativePackage();\n return {\n type: javaThrowable.name,\n value: javaThrowable.message,\n stacktrace: {\n frames: javaThrowable.stackElements\n .map(\n stackElement =>\n <StackFrame>{\n platform: 'java',\n module: stackElement.className,\n filename: stackElement.fileName,\n lineno: stackElement.lineNumber >= 0 ? stackElement.lineNumber : undefined,\n function: stackElement.methodName,\n in_app: nativePackage !== null && stackElement.className.startsWith(nativePackage) ? true : undefined,\n },\n )\n .reverse(),\n },\n };\n}\n\n/**\n * Converts StackAddresses to a SentryException with DebugMetaImages\n */\nfunction exceptionFromAppleStackReturnAddresses(objCException: {\n name: string;\n message: string;\n stackReturnAddresses: number[];\n}): {\n appleException: Exception;\n appleDebugImages: DebugImage[];\n} {\n const nativeStackFrames = fetchNativeStackFrames(objCException.stackReturnAddresses);\n\n return {\n appleException: {\n type: objCException.name,\n value: objCException.message,\n stacktrace: {\n frames: (nativeStackFrames && nativeStackFrames.frames.reverse()) || [],\n },\n },\n appleDebugImages: (nativeStackFrames && (nativeStackFrames.debugMetaImages as DebugImage[])) || [],\n };\n}\n\nlet nativePackage: string | null = null;\n/**\n * Fetches the native package/image name from the native layer\n */\nfunction fetchNativePackage(): string | null {\n if (nativePackage === null) {\n nativePackage = NATIVE.fetchNativePackageName();\n }\n return nativePackage;\n}\n\n/**\n * Fetches native debug image information on iOS\n */\nfunction fetchNativeStackFrames(instructionsAddr: number[]): NativeStackFrames | null {\n return NATIVE.fetchNativeStackFramesBy(instructionsAddr);\n}\n"]}
@@ -1,4 +1,4 @@
1
- import type { Integration, IntegrationClass, IntegrationFnResult } from '@sentry/types';
1
+ import type { Integration } from '@sentry/types';
2
2
  /** ReactNativeErrorHandlers Options */
3
3
  interface ReactNativeErrorHandlersOptions {
4
4
  onerror: boolean;
@@ -6,12 +6,6 @@ interface ReactNativeErrorHandlersOptions {
6
6
  patchGlobalPromise: boolean;
7
7
  }
8
8
  /** ReactNativeErrorHandlers Integration */
9
- export declare const reactNativeErrorHandlersIntegration: (options?: Partial<ReactNativeErrorHandlersOptions>) => IntegrationFnResult;
10
- /**
11
- * ReactNativeErrorHandlers Integration
12
- *
13
- * @deprecated Use `reactNativeErrorHandlersIntegration()` instead.
14
- */
15
- export declare const ReactNativeErrorHandlers: IntegrationClass<Integration> & (new (options?: Partial<ReactNativeErrorHandlersOptions>) => Integration);
9
+ export declare const reactNativeErrorHandlersIntegration: (options?: Partial<ReactNativeErrorHandlersOptions>) => Integration;
16
10
  export {};
17
11
  //# sourceMappingURL=reactnativeerrorhandlers.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"reactnativeerrorhandlers.d.ts","sourceRoot":"","sources":["../../../src/js/integrations/reactnativeerrorhandlers.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAa,WAAW,EAAE,gBAAgB,EAAE,mBAAmB,EAAiB,MAAM,eAAe,CAAC;AASlH,uCAAuC;AACvC,UAAU,+BAA+B;IACvC,OAAO,EAAE,OAAO,CAAC;IACjB,oBAAoB,EAAE,OAAO,CAAC;IAC9B,kBAAkB,EAAE,OAAO,CAAC;CAC7B;AAOD,2CAA2C;AAC3C,eAAO,MAAM,mCAAmC,aACrC,QAAQ,+BAA+B,CAAC,KAChD,mBAWF,CAAC;AAEF;;;;GAIG;AAEH,eAAO,MAAM,wBAAwB,kDAIpB,QAAQ,+BAA+B,CAAC,KAAG,WAAW,CACtE,CAAC"}
1
+ {"version":3,"file":"reactnativeerrorhandlers.d.ts","sourceRoot":"","sources":["../../../src/js/integrations/reactnativeerrorhandlers.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAa,WAAW,EAAiB,MAAM,eAAe,CAAC;AAS3E,uCAAuC;AACvC,UAAU,+BAA+B;IACvC,OAAO,EAAE,OAAO,CAAC;IACjB,oBAAoB,EAAE,OAAO,CAAC;IAC9B,kBAAkB,EAAE,OAAO,CAAC;CAC7B;AAOD,2CAA2C;AAC3C,eAAO,MAAM,mCAAmC,aACrC,QAAQ,+BAA+B,CAAC,KAChD,WAWF,CAAC"}
@@ -1,5 +1,5 @@
1
1
  import { __awaiter } from "tslib";
2
- import { captureException, convertIntegrationFnToClass, getClient, getCurrentScope } from '@sentry/core';
2
+ import { captureException, getClient, getCurrentScope } from '@sentry/core';
3
3
  import { addExceptionMechanism, logger } from '@sentry/utils';
4
4
  import { createSyntheticError, isErrorLike } from '../utils/error';
5
5
  import { RN_GLOBAL_OBJ } from '../utils/worldwide';
@@ -12,13 +12,6 @@ export const reactNativeErrorHandlersIntegration = (options = {}) => {
12
12
  setupOnce: () => setup(Object.assign({ onerror: true, onunhandledrejection: true, patchGlobalPromise: true }, options)),
13
13
  };
14
14
  };
15
- /**
16
- * ReactNativeErrorHandlers Integration
17
- *
18
- * @deprecated Use `reactNativeErrorHandlersIntegration()` instead.
19
- */
20
- // eslint-disable-next-line deprecation/deprecation
21
- export const ReactNativeErrorHandlers = convertIntegrationFnToClass(INTEGRATION_NAME, reactNativeErrorHandlersIntegration);
22
15
  function setup(options) {
23
16
  options.onunhandledrejection && setupUnhandledRejectionsTracking(options.patchGlobalPromise);
24
17
  options.onerror && setupErrorUtilsGlobalHandler();
@@ -1 +1 @@
1
- {"version":3,"file":"reactnativeerrorhandlers.js","sourceRoot":"","sources":["../../../src/js/integrations/reactnativeerrorhandlers.ts"],"names":[],"mappings":";AAAA,OAAO,EAAE,gBAAgB,EAAE,2BAA2B,EAAE,SAAS,EAAE,eAAe,EAAE,MAAM,cAAc,CAAC;AAEzG,OAAO,EAAE,qBAAqB,EAAE,MAAM,EAAE,MAAM,eAAe,CAAC;AAE9D,OAAO,EAAE,oBAAoB,EAAE,WAAW,EAAE,MAAM,gBAAgB,CAAC;AACnE,OAAO,EAAE,aAAa,EAAE,MAAM,oBAAoB,CAAC;AACnD,OAAO,EAAE,mBAAmB,EAAE,eAAe,EAAE,wBAAwB,EAAE,M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{ captureException, convertIntegrationFnToClass, getClient, getCurrentScope } from '@sentry/core';\nimport type { EventHint, Integration, IntegrationClass, IntegrationFnResult, SeverityLevel } from '@sentry/types';\nimport { addExceptionMechanism, logger } from '@sentry/utils';\n\nimport { createSyntheticError, isErrorLike } from '../utils/error';\nimport { RN_GLOBAL_OBJ } from '../utils/worldwide';\nimport { checkPromiseAndWarn, polyfillPromise, requireRejectionTracking } from './reactnativeerrorhandlersutils';\n\nconst INTEGRATION_NAME = 'ReactNativeErrorHandlers';\n\n/** ReactNativeErrorHandlers Options */\ninterface ReactNativeErrorHandlersOptions {\n onerror: boolean;\n onunhandledrejection: boolean;\n patchGlobalPromise: boolean;\n}\n\ninterface PromiseRejectionTrackingOptions {\n onUnhandled: (id: string, error: unknown) => void;\n onHandled: (id: string) => void;\n}\n\n/** ReactNativeErrorHandlers Integration */\nexport const reactNativeErrorHandlersIntegration = (\n options: Partial<ReactNativeErrorHandlersOptions> = {},\n): IntegrationFnResult => {\n return {\n name: INTEGRATION_NAME,\n setupOnce: () =>\n setup({\n onerror: true,\n onunhandledrejection: true,\n patchGlobalPromise: true,\n ...options,\n }),\n };\n};\n\n/**\n * ReactNativeErrorHandlers Integration\n *\n * @deprecated Use `reactNativeErrorHandlersIntegration()` instead.\n */\n// eslint-disable-next-line deprecation/deprecation\nexport const ReactNativeErrorHandlers = convertIntegrationFnToClass(\n INTEGRATION_NAME,\n reactNativeErrorHandlersIntegration,\n) as IntegrationClass<Integration> & {\n new (options?: Partial<ReactNativeErrorHandlersOptions>): Integration;\n};\n\nfunction setup(options: ReactNativeErrorHandlersOptions): void {\n options.onunhandledrejection && setupUnhandledRejectionsTracking(options.patchGlobalPromise);\n options.onerror && setupErrorUtilsGlobalHandler();\n}\n\n/**\n * Setup unhandled promise rejection tracking\n */\nfunction setupUnhandledRejectionsTracking(patchGlobalPromise: boolean): void {\n if (patchGlobalPromise) {\n polyfillPromise();\n }\n\n attachUnhandledRejectionHandler();\n checkPromiseAndWarn();\n}\n\nfunction attachUnhandledRejectionHandler(): void {\n const tracking = requireRejectionTracking();\n\n const promiseRejectionTrackingOptions: PromiseRejectionTrackingOptions = {\n onUnhandled: (id, rejection = {}) => {\n // eslint-disable-next-line no-console\n console.warn(`Possible Unhandled Promise Rejection (id: ${id}):\\n${rejection}`);\n },\n onHandled: id => {\n // eslint-disable-next-line no-console\n console.warn(\n `Promise Rejection Handled (id: ${id})\\n` +\n 'This means you can ignore any previous messages of the form ' +\n `\"Possible Unhandled Promise Rejection (id: ${id}):\"`,\n );\n },\n };\n\n tracking.enable({\n allRejections: true,\n onUnhandled: (id: string, error: unknown) => {\n if (__DEV__) {\n promiseRejectionTrackingOptions.onUnhandled(id, error);\n }\n\n captureException(error, {\n data: { id },\n originalException: error,\n syntheticException: isErrorLike(error) ? undefined : createSyntheticError(),\n });\n },\n onHandled: (id: string) => {\n promiseRejectionTrackingOptions.onHandled(id);\n },\n });\n}\n\nfunction setupErrorUtilsGlobalHandler(): void {\n let handlingFatal = false;\n\n const errorUtils = RN_GLOBAL_OBJ.ErrorUtils;\n if (!errorUtils) {\n logger.warn('ErrorUtils not found. Can be caused by different environment for example react-native-web.');\n return;\n }\n\n const defaultHandler = errorUtils.getGlobalHandler && errorUtils.getGlobalHandler();\n\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n errorUtils.setGlobalHandler(async (error: any, isFatal?: boolean) => {\n // We want to handle fatals, but only in production mode.\n const shouldHandleFatal = isFatal && !__DEV__;\n if (shouldHandleFatal) {\n if (handlingFatal) {\n logger.log('Encountered multiple fatals in a row. The latest:', error);\n return;\n }\n handlingFatal = true;\n }\n\n const client = getClient();\n\n if (!client) {\n logger.error('Sentry client is missing, the error event might be lost.', error);\n\n // If there is no client something is fishy, anyway we call the default handler\n defaultHandler(error, isFatal);\n\n return;\n }\n\n const hint: EventHint = {\n originalException: error,\n attachments: getCurrentScope().getScopeData().attachments,\n };\n const event = await client.eventFromException(error, hint);\n\n if (isFatal) {\n event.level = 'fatal' as SeverityLevel;\n\n addExceptionMechanism(event, {\n handled: false,\n type: 'onerror',\n });\n } else {\n event.level = 'error';\n\n addExceptionMechanism(event, {\n handled: true,\n type: 'generic',\n });\n }\n\n client.captureEvent(event, hint);\n\n if (__DEV__) {\n // If in dev, we call the default handler anyway and hope the error will be sent\n // Just for a better dev experience\n defaultHandler(error, isFatal);\n return;\n }\n\n void client.flush(client.getOptions().shutdownTimeout || 2000).then(\n () => {\n defaultHandler(error, isFatal);\n },\n (reason: unknown) => {\n logger.error('[ReactNativeErrorHandlers] Error while flushing the event cache after uncaught error.', reason);\n },\n );\n });\n}\n"]}
1
+ {"version":3,"file":"reactnativeerrorhandlers.js","sourceRoot":"","sources":["../../../src/js/integrations/reactnativeerrorhandlers.ts"],"names":[],"mappings":";AAAA,OAAO,EAAE,gBAAgB,EAAE,SAAS,EAAE,eAAe,EAAE,MAAM,cAAc,CAAC;AAE5E,OAAO,EAAE,qBAAqB,EAAE,MAAM,EAAE,MAAM,eAAe,CAAC;AAE9D,OAAO,EAAE,oBAAoB,EAAE,WAAW,EAAE,MAAM,gBAAgB,CAAC;AACnE,OAAO,EAAE,aAAa,EAAE,MAAM,oBAAoB,CAAC;AACnD,OAAO,EAAE,mBAAmB,EAAE,eAAe,EAAE,wBAAwB,EAAE,MAAM,iCAAiC,CAAC;AAEjH,MAAM,gBAAgB,GAAG,0BAA0B,CAAC;AAcpD,2CAA2C;AAC3C,MAAM,CAAC,MAAM,mCAAmC,GAAG,CACjD,UAAoD,EAAE,EACzC,EAAE;IACf,OAAO;QACL,IAAI,EAAE,gBAAgB;QACtB,SAAS,EAAE,GAAG,EAAE,CACd,KAAK,iBACH,OAAO,EAAE,IAAI,EACb,oBAAoB,EAAE,IAAI,EAC1B,kBAAkB,EAAE,IAAI,IACrB,OAAO,EACV;KACL,CAAC;AACJ,CAAC,CAAC;AAEF,SAAS,KAAK,CAAC,OAAwC;IACrD,OAAO,CAAC,oBAAoB,IAAI,gCAAgC,CAAC,OAAO,CAAC,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AM;YACL,KAAK,CAAC,KAAK,GAAG,OAAO,CAAC;YAEtB,qBAAqB,CAAC,KAAK,EAAE;gBAC3B,OAAO,EAAE,IAAI;gBACb,IAAI,EAAE,SAAS;aAChB,CAAC,CAAC;SACJ;QAED,MAAM,CAAC,YAAY,CAAC,KAAK,EAAE,IAAI,CAAC,CAAC;QAEjC,IAAI,OAAO,EAAE;YACX,gFAAgF;YAChF,mCAAmC;YACnC,cAAc,CAAC,KAAK,EAAE,OAAO,CAAC,CAAC;YAC/B,OAAO;SACR;QAED,KAAK,MAAM,CAAC,KAAK,CAAC,MAAM,CAAC,UAAU,EAAE,CAAC,eAAe,IAAI,IAAI,CAAC,CAAC,IAAI,CACjE,GAAG,EAAE;YACH,cAAc,CAAC,KAAK,EAAE,OAAO,CAAC,CAAC;QACjC,CAAC,EACD,CAAC,MAAe,EAAE,EAAE;YAClB,MAAM,CAAC,KAAK,CAAC,uFAAuF,EAAE,MAAM,CAAC,CAAC;QAChH,CAAC,CACF,CAAC;IACJ,CAAC,CAAA,CAAC,CAAC;AACL,CAAC","sourcesContent":["import { captureException, getClient, getCurrentScope } from '@sentry/core';\nimport type { EventHint, Integration, SeverityLevel } from '@sentry/types';\nimport { addExceptionMechanism, logger } from '@sentry/utils';\n\nimport { createSyntheticError, isErrorLike } from '../utils/error';\nimport { RN_GLOBAL_OBJ } from '../utils/worldwide';\nimport { checkPromiseAndWarn, polyfillPromise, requireRejectionTracking } from './reactnativeerrorhandlersutils';\n\nconst INTEGRATION_NAME = 'ReactNativeErrorHandlers';\n\n/** ReactNativeErrorHandlers Options */\ninterface ReactNativeErrorHandlersOptions {\n onerror: boolean;\n onunhandledrejection: boolean;\n patchGlobalPromise: boolean;\n}\n\ninterface PromiseRejectionTrackingOptions {\n onUnhandled: (id: string, error: unknown) => void;\n onHandled: (id: string) => void;\n}\n\n/** ReactNativeErrorHandlers Integration */\nexport const reactNativeErrorHandlersIntegration = (\n options: Partial<ReactNativeErrorHandlersOptions> = {},\n): Integration => {\n return {\n name: INTEGRATION_NAME,\n setupOnce: () =>\n setup({\n onerror: true,\n onunhandledrejection: true,\n patchGlobalPromise: true,\n ...options,\n }),\n };\n};\n\nfunction setup(options: ReactNativeErrorHandlersOptions): void {\n options.onunhandledrejection && setupUnhandledRejectionsTracking(options.patchGlobalPromise);\n options.onerror && setupErrorUtilsGlobalHandler();\n}\n\n/**\n * Setup unhandled promise rejection tracking\n */\nfunction setupUnhandledRejectionsTracking(patchGlobalPromise: boolean): void {\n if (patchGlobalPromise) {\n polyfillPromise();\n }\n\n attachUnhandledRejectionHandler();\n checkPromiseAndWarn();\n}\n\nfunction attachUnhandledRejectionHandler(): void {\n const tracking = requireRejectionTracking();\n\n const promiseRejectionTrackingOptions: PromiseRejectionTrackingOptions = {\n onUnhandled: (id, rejection = {}) => {\n // eslint-disable-next-line no-console\n console.warn(`Possible Unhandled Promise Rejection (id: ${id}):\\n${rejection}`);\n },\n onHandled: id => {\n // eslint-disable-next-line no-console\n console.warn(\n `Promise Rejection Handled (id: ${id})\\n` +\n 'This means you can ignore any previous messages of the form ' +\n `\"Possible Unhandled Promise Rejection (id: ${id}):\"`,\n );\n },\n };\n\n tracking.enable({\n allRejections: true,\n onUnhandled: (id: string, error: unknown) => {\n if (__DEV__) {\n promiseRejectionTrackingOptions.onUnhandled(id, error);\n }\n\n captureException(error, {\n data: { id },\n originalException: error,\n syntheticException: isErrorLike(error) ? undefined : createSyntheticError(),\n });\n },\n onHandled: (id: string) => {\n promiseRejectionTrackingOptions.onHandled(id);\n },\n });\n}\n\nfunction setupErrorUtilsGlobalHandler(): void {\n let handlingFatal = false;\n\n const errorUtils = RN_GLOBAL_OBJ.ErrorUtils;\n if (!errorUtils) {\n logger.warn('ErrorUtils not found. Can be caused by different environment for example react-native-web.');\n return;\n }\n\n const defaultHandler = errorUtils.getGlobalHandler && errorUtils.getGlobalHandler();\n\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n errorUtils.setGlobalHandler(async (error: any, isFatal?: boolean) => {\n // We want to handle fatals, but only in production mode.\n const shouldHandleFatal = isFatal && !__DEV__;\n if (shouldHandleFatal) {\n if (handlingFatal) {\n logger.log('Encountered multiple fatals in a row. The latest:', error);\n return;\n }\n handlingFatal = true;\n }\n\n const client = getClient();\n\n if (!client) {\n logger.error('Sentry client is missing, the error event might be lost.', error);\n\n // If there is no client something is fishy, anyway we call the default handler\n defaultHandler(error, isFatal);\n\n return;\n }\n\n const hint: EventHint = {\n originalException: error,\n attachments: getCurrentScope().getScopeData().attachments,\n };\n const event = await client.eventFromException(error, hint);\n\n if (isFatal) {\n event.level = 'fatal' as SeverityLevel;\n\n addExceptionMechanism(event, {\n handled: false,\n type: 'onerror',\n });\n } else {\n event.level = 'error';\n\n addExceptionMechanism(event, {\n handled: true,\n type: 'generic',\n });\n }\n\n client.captureEvent(event, hint);\n\n if (__DEV__) {\n // If in dev, we call the default handler anyway and hope the error will be sent\n // Just for a better dev experience\n defaultHandler(error, isFatal);\n return;\n }\n\n void client.flush(client.getOptions().shutdownTimeout || 2000).then(\n () => {\n defaultHandler(error, isFatal);\n },\n (reason: unknown) => {\n logger.error('[ReactNativeErrorHandlers] Error while flushing the event cache after uncaught error.', reason);\n },\n );\n });\n}\n"]}
@@ -1,4 +1,4 @@
1
- import type { Context, Integration, IntegrationClass, IntegrationFnResult } from '@sentry/types';
1
+ import type { Context, Integration } from '@sentry/types';
2
2
  export interface ReactNativeContext extends Context {
3
3
  js_engine?: string;
4
4
  turbo_module: boolean;
@@ -12,11 +12,5 @@ export interface ReactNativeContext extends Context {
12
12
  expo_sdk_version?: string;
13
13
  }
14
14
  /** Loads React Native context at runtime */
15
- export declare const reactNativeInfoIntegration: () => IntegrationFnResult;
16
- /**
17
- * Loads React Native context at runtime
18
- *
19
- * @deprecated Use `reactNativeInfoIntegration()` instead.
20
- */
21
- export declare const ReactNativeInfo: IntegrationClass<Integration>;
15
+ export declare const reactNativeInfoIntegration: () => Integration;
22
16
  //# sourceMappingURL=reactnativeinfo.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"reactnativeinfo.d.ts","sourceRoot":"","sources":["../../../src/js/integrations/reactnativeinfo.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,OAAO,EAAoB,WAAW,EAAE,gBAAgB,EAAE,mBAAmB,EAAE,MAAM,eAAe,CAAC;AAgBnH,MAAM,WAAW,kBAAmB,SAAQ,OAAO;IACjD,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,YAAY,EAAE,OAAO,CAAC;IACtB,MAAM,EAAE,OAAO,CAAC;IAChB,IAAI,EAAE,OAAO,CAAC;IACd,cAAc,CAAC,EAAE,MAAM,CAAC;IACxB,oBAAoB,CAAC,EAAE,MAAM,CAAC;IAC9B,eAAe,CAAC,EAAE,MAAM,CAAC;IACzB,iBAAiB,CAAC,EAAE,OAAO,CAAC;IAC5B,eAAe,CAAC,EAAE,MAAM,CAAC;IACzB,gBAAgB,CAAC,EAAE,MAAM,CAAC;CAC3B;AAED,4CAA4C;AAC5C,eAAO,MAAM,0BAA0B,QAAO,mBAQ7C,CAAC;AAEF;;;;GAIG;AAEH,eAAO,MAAM,eAAe,+BAGM,CAAC"}
1
+ {"version":3,"file":"reactnativeinfo.d.ts","sourceRoot":"","sources":["../../../src/js/integrations/reactnativeinfo.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,OAAO,EAAoB,WAAW,EAAE,MAAM,eAAe,CAAC;AAgB5E,MAAM,WAAW,kBAAmB,SAAQ,OAAO;IACjD,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,YAAY,EAAE,OAAO,CAAC;IACtB,MAAM,EAAE,OAAO,CAAC;IAChB,IAAI,EAAE,OAAO,CAAC;IACd,cAAc,CAAC,EAAE,MAAM,CAAC;IACxB,oBAAoB,CAAC,EAAE,MAAM,CAAC;IAC9B,eAAe,CAAC,EAAE,MAAM,CAAC;IACzB,iBAAiB,CAAC,EAAE,OAAO,CAAC;IAC5B,eAAe,CAAC,EAAE,MAAM,CAAC;IACzB,gBAAgB,CAAC,EAAE,MAAM,CAAC;CAC3B;AAED,4CAA4C;AAC5C,eAAO,MAAM,0BAA0B,QAAO,WAQ7C,CAAC"}
@@ -1,4 +1,3 @@
1
- import { convertIntegrationFnToClass } from '@sentry/core';
2
1
  import { getExpoGoVersion, getExpoSdkVersion, getHermesVersion, getReactNativeVersion, isExpo, isFabricEnabled, isHermesEnabled, isTurboModuleEnabled, } from '../utils/environment';
3
2
  const INTEGRATION_NAME = 'ReactNativeInfo';
4
3
  /** Loads React Native context at runtime */
@@ -11,13 +10,6 @@ export const reactNativeInfoIntegration = () => {
11
10
  processEvent,
12
11
  };
13
12
  };
14
- /**
15
- * Loads React Native context at runtime
16
- *
17
- * @deprecated Use `reactNativeInfoIntegration()` instead.
18
- */
19
- // eslint-disable-next-line deprecation/deprecation
20
- export const ReactNativeInfo = convertIntegrationFnToClass(INTEGRATION_NAME, reactNativeInfoIntegration);
21
13
  function processEvent(event, hint) {
22
14
  const reactNativeError = (hint === null || hint === void 0 ? void 0 : hint.originalException) ? hint === null || hint === void 0 ? void 0 : hint.originalException : undefined;
23
15
  const reactNativeContext = {
@@ -1 +1 @@
1
- {"version":3,"file":"reactnativeinfo.js","sourceRoot":"","sources":["../../../src/js/integrations/reactnativeinfo.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,2BAA2B,EAAE,MAAM,cAAc,CAAC;AAG3D,OAAO,EACL,gBAAgB,EAChB,iBAAiB,EACjB,gBAAgB,EAChB,qBAAqB,EACrB,MAAM,EACN,eAAe,EACf,eAAe,EACf,oBAAoB,GACrB,MAAM,sBAAsB,CAAC;AAG9B,MAAM,gBAAgB,GAAG,iBAAiB,CAAC;AAe3C,4CAA4C;AAC5C,MAAM,CAAC,MAAM,0BAA0B,GAAG,GAAwB,EAAE;IAClE,OAAO;QACL,IAAI,EAAE,gBAAgB;QACtB,SAAS,EAAE,GAAG,EAAE;YACd,OAAO;QACT,CAAC;QACD,YAAY;KACb,CAAC;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AAgB,EAAE,CAAC;IACzC,IAAI,aAAa,EAAE;QACjB,kBAAkB,CAAC,eAAe,GAAG,aAAa,CAAC;KACpD;IAED,MAAM,cAAc,GAAG,iBAAiB,EAAE,CAAC;IAC3C,IAAI,cAAc,EAAE;QAClB,kBAAkB,CAAC,gBAAgB,GAAG,cAAc,CAAC;KACtD;IAED,KAAK,CAAC,QAAQ,mBACZ,oBAAoB,EAAE,kBAAkB,IACrC,KAAK,CAAC,QAAQ,CAClB,CAAC;IAEF,OAAO,KAAK,CAAC;AACf,CAAC;AAED;;;;;;;;;;;;;;;;GAgBG;AACH,SAAS,+BAA+B,CAAC,KAAY;;IACnD,KAAK,MAAM,KAAK,IAAI,CAAA,MAAA,KAAK,CAAC,SAAS,0CAAE,MAAM,MAAI,MAAA,KAAK,CAAC,OAAO,0CAAE,MAAM,CAAA,IAAI,EAAE,EAAE;QAC1E,KAAK,MAAM,KAAK,IAAI,CAAA,MAAA,KAAK,CAAC,UAAU,0CAAE,MAAM,KAAI,EAAE,EAAE;YAClD,mGAAmG;YACnG,IAAI,KAAK,CAAC,QAAQ,KAAK,SAAS,IAAI,KAAK,CAAC,MAAM,KAAK,CAAC,EAAE;gBACtD,OAAO,IAAI,CAAC;aACb;SACF;KACF;IACD,OAAO,KAAK,CAAC;AACf,CAAC","sourcesContent":["import { convertIntegrationFnToClass } from '@sentry/core';\nimport type { Context, Event, EventHint, Integration, IntegrationClass, IntegrationFnResult } from '@sentry/types';\n\nimport {\n getExpoGoVersion,\n getExpoSdkVersion,\n getHermesVersion,\n getReactNativeVersion,\n isExpo,\n isFabricEnabled,\n isHermesEnabled,\n isTurboModuleEnabled,\n} from '../utils/environment';\nimport type { ReactNativeError } from './debugsymbolicator';\n\nconst INTEGRATION_NAME = 'ReactNativeInfo';\n\nexport interface ReactNativeContext extends Context {\n js_engine?: string;\n turbo_module: boolean;\n fabric: boolean;\n expo: boolean;\n hermes_version?: string;\n react_native_version?: string;\n component_stack?: string;\n hermes_debug_info?: boolean;\n expo_go_version?: string;\n expo_sdk_version?: string;\n}\n\n/** Loads React Native context at runtime */\nexport const reactNativeInfoIntegration = (): IntegrationFnResult => {\n return {\n name: INTEGRATION_NAME,\n setupOnce: () => {\n // noop\n },\n processEvent,\n };\n};\n\n/**\n * Loads React Native context at runtime\n *\n * @deprecated Use `reactNativeInfoIntegration()` instead.\n */\n// eslint-disable-next-line deprecation/deprecation\nexport const ReactNativeInfo = convertIntegrationFnToClass(\n INTEGRATION_NAME,\n reactNativeInfoIntegration,\n) as IntegrationClass<Integration>;\n\nfunction processEvent(event: Event, hint: EventHint): Event {\n const reactNativeError = hint?.originalException ? (hint?.originalException as ReactNativeError) : undefined;\n\n const reactNativeContext: ReactNativeContext = {\n turbo_module: isTurboModuleEnabled(),\n fabric: isFabricEnabled(),\n react_native_version: getReactNativeVersion(),\n expo: isExpo(),\n };\n\n if (isHermesEnabled()) {\n reactNativeContext.js_engine = 'hermes';\n const hermesVersion = getHermesVersion();\n if (hermesVersion) {\n reactNativeContext.hermes_version = hermesVersion;\n }\n reactNativeContext.hermes_debug_info = !isEventWithHermesBytecodeFrames(event);\n } else if (reactNativeError?.jsEngine) {\n reactNativeContext.js_engine = reactNativeError.jsEngine;\n }\n\n if (reactNativeContext.js_engine === 'hermes') {\n event.tags = {\n hermes: 'true',\n ...event.tags,\n };\n }\n\n if (reactNativeError?.componentStack) {\n reactNativeContext.component_stack = reactNativeError.componentStack;\n }\n\n const expoGoVersion = getExpoGoVersion();\n if (expoGoVersion) {\n reactNativeContext.expo_go_version = expoGoVersion;\n }\n\n const expoSdkVersion = getExpoSdkVersion();\n if (expoSdkVersion) {\n reactNativeContext.expo_sdk_version = expoSdkVersion;\n }\n\n event.contexts = {\n react_native_context: reactNativeContext,\n ...event.contexts,\n };\n\n return event;\n}\n\n/**\n * Guess if the event contains frames with Hermes bytecode\n * (thus Hermes bundle doesn't contain debug info)\n * based on the event exception/threads frames.\n *\n * This function can be relied on only if Hermes is enabled!\n *\n * Hermes bytecode position is always line 1 and column 0-based number.\n * If Hermes bundle has debug info, the bytecode frames pos are calculated\n * back to the plain bundle source code positions and line will be > 1.\n *\n * Line 1 contains start time var, it's safe to assume it won't crash.\n * The above only applies when Hermes is enabled.\n *\n * Javascript/Hermes bytecode frames have platform === undefined.\n * Native (Java, ObjC, C++) frames have platform === 'android'/'ios'/'native'.\n */\nfunction isEventWithHermesBytecodeFrames(event: Event): boolean {\n for (const value of event.exception?.values || event.threads?.values || []) {\n for (const frame of value.stacktrace?.frames || []) {\n // platform === undefined we assume it's javascript (only native frames use the platform attribute)\n if (frame.platform === undefined && frame.lineno === 1) {\n return true;\n }\n }\n }\n return false;\n}\n"]}
1
+ {"version":3,"file":"reactnativeinfo.js","sourceRoot":"","sources":["../../../src/js/integrations/reactnativeinfo.ts"],"names":[],"mappings":"AAEA,OAAO,EACL,gBAAgB,EAChB,iBAAiB,EACjB,gBAAgB,EAChB,qBAAqB,EACrB,MAAM,EACN,eAAe,EACf,eAAe,EACf,oBAAoB,GACrB,MAAM,sBAAsB,CAAC;AAG9B,MAAM,gBAAgB,GAAG,iBAAiB,CAAC;AAe3C,4CAA4C;AAC5C,MAAM,CAAC,MAAM,0BAA0B,GAAG,GAAgB,EAAE;IAC1D,OAAO;QACL,IAAI,EAAE,gBAAgB;QACtB,SAAS,EAAE,GAAG,EAAE;YACd,OAAO;QACT,CAAC;QACD,YAAY;KACb,CAAC;AACJ,CAAC,CAAC;AAEF,SAAS,YAAY,CAAC,KAAY,EAAE,IAAe;IACjD,MAAM,gBAAgB,GAAG,CAAA,IAAI,aAAJ,IAAI,uBAAJ,IAAI,CAAE,iBAAiB,EAAC,CAAC,CAAE,IAAI,aAAJ,IAAI,uBAAJ,IAAI,CAAE,iBAAsC,CAAC,CAAC,CAAC,SAAS,CAAC;IAE7G,MAAM,kBAAkB,GAAuB;QAC7C,YAAY,EAAE,oBAAoB,EAAE;QACpC,MAAM,EAAE,eAAe,EAAE;QACzB,oBAAoB,EAAE,qBAAqB,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AM,MAAI,MAAA,KAAK,CAAC,OAAO,0CAAE,MAAM,CAAA,IAAI,EAAE,EAAE;QAC1E,KAAK,MAAM,KAAK,IAAI,CAAA,MAAA,KAAK,CAAC,UAAU,0CAAE,MAAM,KAAI,EAAE,EAAE;YAClD,mGAAmG;YACnG,IAAI,KAAK,CAAC,QAAQ,KAAK,SAAS,IAAI,KAAK,CAAC,MAAM,KAAK,CAAC,EAAE;gBACtD,OAAO,IAAI,CAAC;aACb;SACF;KACF;IACD,OAAO,KAAK,CAAC;AACf,CAAC","sourcesContent":["import type { Context, Event, EventHint, Integration } from '@sentry/types';\n\nimport {\n getExpoGoVersion,\n getExpoSdkVersion,\n getHermesVersion,\n getReactNativeVersion,\n isExpo,\n isFabricEnabled,\n isHermesEnabled,\n isTurboModuleEnabled,\n} from '../utils/environment';\nimport type { ReactNativeError } from './debugsymbolicator';\n\nconst INTEGRATION_NAME = 'ReactNativeInfo';\n\nexport interface ReactNativeContext extends Context {\n js_engine?: string;\n turbo_module: boolean;\n fabric: boolean;\n expo: boolean;\n hermes_version?: string;\n react_native_version?: string;\n component_stack?: string;\n hermes_debug_info?: boolean;\n expo_go_version?: string;\n expo_sdk_version?: string;\n}\n\n/** Loads React Native context at runtime */\nexport const reactNativeInfoIntegration = (): Integration => {\n return {\n name: INTEGRATION_NAME,\n setupOnce: () => {\n // noop\n },\n processEvent,\n };\n};\n\nfunction processEvent(event: Event, hint: EventHint): Event {\n const reactNativeError = hint?.originalException ? (hint?.originalException as ReactNativeError) : undefined;\n\n const reactNativeContext: ReactNativeContext = {\n turbo_module: isTurboModuleEnabled(),\n fabric: isFabricEnabled(),\n react_native_version: getReactNativeVersion(),\n expo: isExpo(),\n };\n\n if (isHermesEnabled()) {\n reactNativeContext.js_engine = 'hermes';\n const hermesVersion = getHermesVersion();\n if (hermesVersion) {\n reactNativeContext.hermes_version = hermesVersion;\n }\n reactNativeContext.hermes_debug_info = !isEventWithHermesBytecodeFrames(event);\n } else if (reactNativeError?.jsEngine) {\n reactNativeContext.js_engine = reactNativeError.jsEngine;\n }\n\n if (reactNativeContext.js_engine === 'hermes') {\n event.tags = {\n hermes: 'true',\n ...event.tags,\n };\n }\n\n if (reactNativeError?.componentStack) {\n reactNativeContext.component_stack = reactNativeError.componentStack;\n }\n\n const expoGoVersion = getExpoGoVersion();\n if (expoGoVersion) {\n reactNativeContext.expo_go_version = expoGoVersion;\n }\n\n const expoSdkVersion = getExpoSdkVersion();\n if (expoSdkVersion) {\n reactNativeContext.expo_sdk_version = expoSdkVersion;\n }\n\n event.contexts = {\n react_native_context: reactNativeContext,\n ...event.contexts,\n };\n\n return event;\n}\n\n/**\n * Guess if the event contains frames with Hermes bytecode\n * (thus Hermes bundle doesn't contain debug info)\n * based on the event exception/threads frames.\n *\n * This function can be relied on only if Hermes is enabled!\n *\n * Hermes bytecode position is always line 1 and column 0-based number.\n * If Hermes bundle has debug info, the bytecode frames pos are calculated\n * back to the plain bundle source code positions and line will be > 1.\n *\n * Line 1 contains start time var, it's safe to assume it won't crash.\n * The above only applies when Hermes is enabled.\n *\n * Javascript/Hermes bytecode frames have platform === undefined.\n * Native (Java, ObjC, C++) frames have platform === 'android'/'ios'/'native'.\n */\nfunction isEventWithHermesBytecodeFrames(event: Event): boolean {\n for (const value of event.exception?.values || event.threads?.values || []) {\n for (const frame of value.stacktrace?.frames || []) {\n // platform === undefined we assume it's javascript (only native frames use the platform attribute)\n if (frame.platform === undefined && frame.lineno === 1) {\n return true;\n }\n }\n }\n return false;\n}\n"]}
@@ -1,10 +1,4 @@
1
- import type { Integration, IntegrationClass, IntegrationFnResult } from '@sentry/types';
1
+ import type { Integration } from '@sentry/types';
2
2
  /** Release integration responsible to load release from file. */
3
- export declare const nativeReleaseIntegration: () => IntegrationFnResult;
4
- /**
5
- * Release integration responsible to load release from file.
6
- *
7
- * @deprecated Use `nativeReleaseIntegration()` instead.
8
- */
9
- export declare const Release: IntegrationClass<Integration>;
3
+ export declare const nativeReleaseIntegration: () => Integration;
10
4
  //# sourceMappingURL=release.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"release.d.ts","sourceRoot":"","sources":["../../../src/js/integrations/release.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAMV,WAAW,EACX,gBAAgB,EAChB,mBAAmB,EACpB,MAAM,eAAe,CAAC;AAMvB,iEAAiE;AACjE,eAAO,MAAM,wBAAwB,QAAO,mBAQ3C,CAAC;AAEF;;;;GAIG;AAEH,eAAO,MAAM,OAAO,+BAGc,CAAC"}
1
+ {"version":3,"file":"release.d.ts","sourceRoot":"","sources":["../../../src/js/integrations/release.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAiE,WAAW,EAAE,MAAM,eAAe,CAAC;AAMhH,iEAAiE;AACjE,eAAO,MAAM,wBAAwB,QAAO,WAQ3C,CAAC"}
@@ -1,5 +1,4 @@
1
1
  import { __awaiter } from "tslib";
2
- import { convertIntegrationFnToClass } from '@sentry/core';
3
2
  import { NATIVE } from '../wrapper';
4
3
  const INTEGRATION_NAME = 'Release';
5
4
  /** Release integration responsible to load release from file. */
@@ -12,13 +11,6 @@ export const nativeReleaseIntegration = () => {
12
11
  processEvent,
13
12
  };
14
13
  };
15
- /**
16
- * Release integration responsible to load release from file.
17
- *
18
- * @deprecated Use `nativeReleaseIntegration()` instead.
19
- */
20
- // eslint-disable-next-line deprecation/deprecation
21
- export const Release = convertIntegrationFnToClass(INTEGRATION_NAME, nativeReleaseIntegration);
22
14
  function processEvent(event, _, client) {
23
15
  var _a, _b;
24
16
  return __awaiter(this, void 0, void 0, function* () {