Skip to content

Launch crash in SentryWatchdogTerminationAttributesProcessor after upgrading to 8.5.0 with native init #5995

@saeed4u

Description

@saeed4u

What React Native libraries do you use?

React Navigation, Hermes, RN New Architecture, Expo (mobile only)

Are you using sentry.io or on-premise?

on-premise (Self-Hosted)

Are you using any other error monitoring solution alongside Sentry?

No

Other Error Monitoring Solution Name

No response

@sentry/react-native SDK Version

8.5.0

How does your development environment look like?

⬇  Place the `npx react-native@latest info` output here. ⬇

System:
  OS: macOS 26.4
  CPU: (10) arm64 Apple M5
  Memory: 421.16 MB / 24.00 GB
  Shell:
    version: "5.9"
    path: /bin/zsh
Binaries:
  Node:
    version: 25.9.0
    path: /Users/seidu/.nvm/versions/node/v25.9.0/bin/node
  Yarn:
    version: 4.12.0
    path: /opt/homebrew/bin/yarn
  npm:
    version: 11.12.1
    path: /Users/seidu/.nvm/versions/node/v25.9.0/bin/npm
  Watchman: Not Found
Managers:
  CocoaPods:
    version: 1.16.2
    path: /opt/homebrew/bin/pod
SDKs:
  iOS SDK:
    Platforms:
      - DriverKit 25.4
      - iOS 26.4
      - macOS 26.4
      - tvOS 26.4
      - visionOS 26.4
      - watchOS 26.4
  Android SDK: Not Found
IDEs:
  Android Studio: 2025.3 AI-253.31033.145.2533.15113396
  Xcode:
    version: 26.4/17E192
    path: /usr/bin/xcodebuild
Languages:
  Java:
    version: 21.0.10
    path: /opt/homebrew/opt/openjdk@21/bin/javac
  Ruby:
    version: 2.6.10
    path: /usr/bin/ruby
npmPackages:
  "@react-native-community/cli":
    installed: 20.1.3
    wanted: 20.1.3
  react:
    installed: 19.1.0
    wanted: 19.1.0
  react-native:
    installed: 0.81.5
    wanted: 0.81.5
  react-native-macos: Not Found
npmGlobalPackages:
  "*react-native*": Not Found
Android:
  hermesEnabled: true
  newArchEnabled: true
iOS:
  hermesEnabled: true
  newArchEnabled: true


Sentry.init()

Sentry.init({
  dsn: '...'
 tracesSampleRate: 0.1,
 patchGlobalPromise: false,
 denyUrls: ['localhost', '127.0.0.1'],
  replaysOnErrorSampleRate: 1,
  replaysSessionSampleRate: 0,
});

Steps to Reproduce

Note: this is a race condition and does not reproduce 100% of the time.
In our production traffic, it affects less than 1% of cold launches on iOS 26+.
We have not been able to reproduce it with an Xcode-attached debug build or with TestFlight/Release builds on physical devices.

Expected Result

App launches normally.

Actual Result

EXC_BAD_ACCESS (SIGSEGV) on the main thread inside
_SentryDispatchQueueWrapperInternal dispatchAsyncOnMainQueueIfNotMainThread,
with Thread 7 concurrently in
SentryWatchdogTerminationAttributesProcessor.setContext →
SentryScopePersistentStore.writeFieldToDisk.

`This is the full stack trace: OS Version: iOS 26.3.1 (23D8133)
Report Version: 104

Exception Type: EXC_BAD_ACCESS (SIGSEGV)
Exception Codes: SEGV_NOOP at 0x00315262c7721370
Crashed Thread: 0

Application Specific Information:
hash >
KERN_INVALID_ADDRESS at 0x315262c7721370.

Thread 0 Crashed:
0 libobjc.A.dylib 0x3068ff020 + 6551941152
1 Foundation 0x307fac390 + 6568604560
2 Tonie-App 0x204657a74 thunk for closure
3 Tonie-App 0x20551926c __79-[_SentryDispatchQueueWrapperInternal dispatchAsyncOnMainQueueIfNotMainThread:]_block_invoke (_SentryDispatchQueueWrapperInternal.m:59)
4 libdispatch.dylib 0x37e46badc + 7556172508
5 libdispatch.dylib 0x37e4857fc + 7556278268
6 libdispatch.dylib 0x37e4a2b10 + 7556397840
7 libdispatch.dylib 0x37e47aec8 + 7556234952
8 libdispatch.dylib 0x37e47ae04 + 7556234756
9 CoreFoundation 0x30ca842b4 + 6603281076
10 CoreFoundation 0x30ca37b3c + 6602967868
11 CoreFoundation 0x30ca36a6c + 6602963564
12 GraphicsServices 0x455d4d498 + 9364378776
13 UIKitCore 0x317f15df8 + 6698057208
14 UIKitCore 0x317ebee54 + 6697700948
15 UIKitCore 0x317fea938 + 6698928440
16 Tonie-App 0x2046494d0 [inlined] $sSo21UIApplicationDelegateP5UIKitE4mainyyFZ9Tonie_App0fB0C_Ttg5
17 Tonie-App 0x2046494d0 [inlined] AppDelegate.$main (:12)
18 Tonie-App 0x2046494d0 main
19 dyld 0x306a04e28 + 6552481320

Thread 0 Crashed:
0 libobjc.A.dylib 0x3068ff020 + 6551941152
1 Foundation 0x307fac390 + 6568604560
2 Tonie-App 0x204657a74 thunk for closure
3 Tonie-App 0x20551926c __79-[_SentryDispatchQueueWrapperInternal dispatchAsyncOnMainQueueIfNotMainThread:]_block_invoke (_SentryDispatchQueueWrapperInternal.m:59)
4 libdispatch.dylib 0x37e46badc + 7556172508
5 libdispatch.dylib 0x37e4857fc + 7556278268
6 libdispatch.dylib 0x37e4a2b10 + 7556397840
7 libdispatch.dylib 0x37e47aec8 + 7556234952
8 libdispatch.dylib 0x37e47ae04 + 7556234756
9 CoreFoundation 0x30ca842b4 + 6603281076
10 CoreFoundation 0x30ca37b3c + 6602967868
11 CoreFoundation 0x30ca36a6c + 6602963564
12 GraphicsServices 0x455d4d498 + 9364378776
13 UIKitCore 0x317f15df8 + 6698057208
14 UIKitCore 0x317ebee54 + 6697700948
15 UIKitCore 0x317fea938 + 6698928440
16 Tonie-App 0x2046494d0 [inlined] $sSo21UIApplicationDelegateP5UIKitE4mainyyFZ9Tonie_App0fB0C_Ttg5
17 Tonie-App 0x2046494d0 [inlined] AppDelegate.$main (:12)
18 Tonie-App 0x2046494d0 main
19 dyld 0x306a04e28 + 6552481320

Thread 1
0 libsystem_kernel.dylib 0x467998a80 + 9513429632

Thread 2 name: GC Timer thread
0 libsystem_kernel.dylib 0x46799e5d4 + 9513453012
1 libc++.1.dylib 0x32b10079c + 6858192796
2 Usercentrics 0x108127bc8 kotlin::RepeatedTimer::Run
3 Usercentrics 0x108127e50 std::__1::__thread_proxy
4 libsystem_pthread.dylib 0x3c610844c + 8158381132

Thread 3 name: Main GC thread
0 libsystem_kernel.dylib 0x46799e5d4 + 9513453012
1 libc++.1.dylib 0x32b100704 + 6858192644
2 Usercentrics 0x10812a924 kotlin::ScopedThread::Run
3 Usercentrics 0x10812d468 std::__1::__thread_proxy
4 libsystem_pthread.dylib 0x3c610844c + 8158381132

Thread 4
0 libsystem_kernel.dylib 0x467998a80 + 9513429632

Thread 5
0 libsystem_kernel.dylib 0x4679991d0 + 9513431504
1 libsqlite3.dylib 0x3098fe76c + 6577112940
2 libsqlite3.dylib 0x309911390 + 6577189776
3 libsqlite3.dylib 0x309910044 + 6577184836
4 libsqlite3.dylib 0x30990f02c + 6577180716
5 libsqlite3.dylib 0x30999e238 + 6577766968
6 libsqlite3.dylib 0x30990a54c + 6577161548
7 libsqlite3.dylib 0x3099b8128 + 6577873192
8 libsqlite3.dylib 0x30990503c + 6577139772
9 libsqlite3.dylib 0x309903978 + 6577133944
10 libsqlite3.dylib 0x3099011f8 + 6577123832
11 libsqlite3.dylib 0x309900940 + 6577121600
12 libsqlite3.dylib 0x309900594 + 6577120660
13 libsqlite3.dylib 0x309900100 + 6577119488
14 CFNetwork 0x33658fadc + 6953388764
15 CFNetwork 0x33658f734 + 6953387828
16 CFNetwork 0x3365935b4 + 6953403828
17 libdispatch.dylib 0x37e4857fc + 7556278268
18 libdispatch.dylib 0x37e47b8c0 + 7556237504
19 CFNetwork 0x336593278 + 6953403000
20 CFNetwork 0x33649e584 + 6952400260
21 CFNetwork 0x33649d23c + 6952395324
22 CFNetwork 0x33647456c + 6952228204
23 CFNetwork 0x33649c40c + 6952391692
24 CFNetwork 0x336497f80 + 6952374144
25 CFNetwork 0x336497ed0 + 6952373968
26 CFNetwork 0x33647313c + 6952223036
27 libdispatch.dylib 0x37e46badc + 7556172508
28 libdispatch.dylib 0x37e4857fc + 7556278268
29 libdispatch.dylib 0x37e474468 + 7556207720
30 libdispatch.dylib 0x37e474f78 + 7556210552
31 libdispatch.dylib 0x37e476288 + 7556215432
32 libdispatch.dylib 0x37e47f3ec + 7556252652
33 libdispatch.dylib 0x37e47ece4 + 7556250852
34 libsystem_pthread.dylib 0x3c61053b8 + 8158368696

Thread 6
0 libsystem_kernel.dylib 0x467998a80 + 9513429632

Thread 7
0 libsystem_kernel.dylib 0x4679a0250 + 9513460304
1 Foundation 0x307701c78 + 6559517816
2 Foundation 0x3076fe9d0 + 6559504848
3 Foundation 0x3076fe9ec + 6559504876
4 Foundation 0x3076fea04 + 6559504900
5 Foundation 0x3076cf740 + 6559311680
6 Foundation 0x3076fdce4 + 6559501540
7 Foundation 0x3076fda94 + 6559500948
8 Tonie-App 0x20554bba0 -[SentryFileManagerHelper writeData:toPath:] (SentryFileManagerHelper.m:600)
9 Tonie-App 0x2055dd7cc [inlined] SentryFileManager.write (SentryFileManager.swift:233)
10 Tonie-App 0x2055dd7cc SentryFileManager.write (:232)
11 Tonie-App 0x20561dc44 SentryScopePersistentStore.writeFieldToDisk (SentryScopePersistentStore.swift:179)
12 Tonie-App 0x20566f350 closure in SentryWatchdogTerminationAttributesProcessor.setContext
13 Tonie-App 0x205671850 closure in SentryWatchdogTerminationAttributesProcessor.setData
14 Tonie-App 0x2056726c0 closure in SentryWatchdogTerminationAttributesProcessor.setData
15 Tonie-App 0x204657a74 thunk for closure
16 Tonie-App 0x205519324 __62-[_SentryDispatchQueueWrapperInternal dispatchAsyncWithBlock:]_block_invoke (_SentryDispatchQueueWrapperInternal.m:69)
17 libdispatch.dylib 0x37e46badc + 7556172508
18 libdispatch.dylib 0x37e4857fc + 7556278268
19 libdispatch.dylib 0x37e474468 + 7556207720
20 libdispatch.dylib 0x37e474f44 + 7556210500
21 libdispatch.dylib 0x37e47f3ec + 7556252652
22 libdispatch.dylib 0x37e47ece4 + 7556250852
23 libsystem_pthread.dylib 0x3c61053b8 + 8158368696

Thread 8
0 React 0x107459264 facebook::react::operator==
1 React 0x10745ae68 facebook::react::RawPropsParser::at
2 React 0x107459018 facebook::react::RawProps::at
3 React 0x10741c38c facebook::react::AccessibilityProps::AccessibilityProps
4 React 0x107422260 facebook::react::BaseViewProps::BaseViewProps
5 React 0x107411aa4 facebook::react::RootProps::RootProps
6 React 0x10746df4c facebook::react::RawPropsParser::prepare
7 React 0x10746ba38 facebook::react::ShadowTree::ShadowTree
8 React 0x10747c080 facebook::react::SurfaceHandler::start
9 React 0x1074eb8a8 __25-[RCTFabricSurface start]_block_invoke_2
10 libdispatch.dylib 0x37e46badc + 7556172508
11 libdispatch.dylib 0x37e4857fc + 7556278268
12 libdispatch.dylib 0x37e4a241c + 7556396060
13 libdispatch.dylib 0x37e47e0bc + 7556247740
14 libdispatch.dylib 0x37e47e6fc + 7556249340
15 libsystem_pthread.dylib 0x3c610537c + 8158368636

Thread 9 name: com.apple.uikit.eventfetch-thread
0 libsystem_kernel.dylib 0x467998cd4 + 9513430228
1 libsystem_kernel.dylib 0x46799c214 + 9513443860
2 libsystem_kernel.dylib 0x46799c05c + 9513443420
3 CoreFoundation 0x30ca60868 + 6603135080
4 CoreFoundation 0x30ca37848 + 6602967112
5 CoreFoundation 0x30ca36a6c + 6602963564
6 Foundation 0x308030f54 + 6569148244
7 Foundation 0x30803112c + 6569148716
8 UIKitCore 0x317eeb094 + 6697881748
9 Foundation 0x3076f021c + 6559445532
10 libsystem_pthread.dylib 0x3c610844c + 8158381132

Thread 10
0 libsystem_kernel.dylib 0x46799e7f4 + 9513453556
1 libsystem_c.dylib 0x323c7a908 + 6797056264
2 Tonie-App 0x205528b18 monitorThreadCache (SentryCrashCachedData.c:219)
3 libsystem_pthread.dylib 0x3c610844c + 8158381132

Thread 11 name: SentryCrash Exception Handler (Secondary)
0 libsystem_kernel.dylib 0x467998cd4 + 9513430228
1 libsystem_kernel.dylib 0x46799c214 + 9513443860
2 libsystem_kernel.dylib 0x46799c05c + 9513443420
3 Tonie-App 0x205531570 handleExceptions (SentryCrashMonitor_MachException.c:313)
4 libsystem_pthread.dylib 0x3c610844c + 8158381132

Thread 13 name: io.sentry.app-hang-tracker
0 libsystem_kernel.dylib 0x46799e7f4 + 9513453556
1 Foundation 0x308052180 + 6569283968
2 Tonie-App 0x20551bc20 -[SentryANRTrackerV2 detectANRs] (SentryANRTrackerV2.m:116)
3 Foundation 0x3076f021c + 6559445532
4 libsystem_pthread.dylib 0x3c610844c + 8158381132

Thread 14
0 libsystem_kernel.dylib 0x467998a80 + 9513429632

Thread 15 name: com.facebook.react.runtime.JavaScript
0 libsystem_kernel.dylib 0x467998cd4 + 9513430228
1 libsystem_kernel.dylib 0x46799c214 + 9513443860
2 libsystem_kernel.dylib 0x46799c05c + 9513443420
3 CoreFoundation 0x30ca60868 + 6603135080
4 CoreFoundation 0x30ca37848 + 6602967112
5 CoreFoundation 0x30ca36a6c + 6602963564
6 React 0x10756cf10 +[RCTJSThreadManager runRunLoop]
7 Foundation 0x3076f021c + 6559445532
8 libsystem_pthread.dylib 0x3c610844c + 8158381132

Thread 16 name: hades
0 libsystem_kernel.dylib 0x46799e5d4 + 9513453012
1 libc++.1.dylib 0x32b100704 + 6858192644
2 hermes 0x106e039c0 hermes::vm::HadesGC::Executor::worker
3 hermes 0x106e03928 std::__1::__thread_proxy[abi:nn180100]
4 libsystem_pthread.dylib 0x3c610844c + 8158381132

Thread 17 name: AudioSession - RootQueue
0 libsystem_kernel.dylib 0x467998c68 + 9513430120
1 libdispatch.dylib 0x37e46de88 + 7556181640
2 libdispatch.dylib 0x37e47dd40 + 7556246848
3 libsystem_pthread.dylib 0x3c610844c + 8158381132

Thread 18 name: com.apple.NSURLConnectionLoader
0 libsystem_kernel.dylib 0x467998cd4 + 9513430228
1 libsystem_kernel.dylib 0x46799c214 + 9513443860
2 libsystem_kernel.dylib 0x46799c05c + 9513443420
3 CoreFoundation 0x30ca60868 + 6603135080
4 CoreFoundation 0x30ca37848 + 6602967112
5 CoreFoundation 0x30ca36a6c + 6602963564
6 CFNetwork 0x3366b2c10 + 6954581008
7 Foundation 0x3076f021c + 6559445532
8 libsystem_pthread.dylib 0x3c610844c + 8158381132

Thread 19 name: hades
0 libsystem_kernel.dylib 0x46799e5d4 + 9513453012
1 libc++.1.dylib 0x32b100704 + 6858192644
2 hermes 0x106e039c0 hermes::vm::HadesGC::Executor::worker
3 hermes 0x106e03928 std::__1::__thread_proxy[abi:nn180100]
4 libsystem_pthread.dylib 0x3c610844c + 8158381132

Thread 20 name: video-metadata-runtime_queue
0 libsystem_kernel.dylib 0x46799e5d4 + 9513453012
1 libc++.1.dylib 0x32b100704 + 6858192644
2 Tonie-App 0x20546ecc4 [inlined] std::__1::condition_variable::wait (condition_variable.h:147)
3 Tonie-App 0x20546ecc4 [inlined] worklets::AsyncQueueImpl::AsyncQueueImpl::lambda::operator() (AsyncQueueImpl.cpp:17)
4 Tonie-App 0x20546ecc4 [inlined] std::__1::__invoke[abi:ne200100] (invoke.h:179)
5 Tonie-App 0x20546ecc4 [inlined] std::__1::__thread_execute[abi:ne200100] (thread.h:205)
6 Tonie-App 0x20546ecc4 std::__1::__thread_proxy[abi:ne200100] (thread.h:214)
7 libsystem_pthread.dylib 0x3c610844c + 8158381132

Thread 21 name: hades
0 libsystem_kernel.dylib 0x46799e5d4 + 9513453012
1 libc++.1.dylib 0x32b100704 + 6858192644
2 hermes 0x106e039c0 hermes::vm::HadesGC::Executor::worker
3 hermes 0x106e03928 std::__1::__thread_proxy[abi:nn180100]
4 libsystem_pthread.dylib 0x3c610844c + 8158381132

Thread 22 name: video-metadata-runtime(timeout)
0 libsystem_kernel.dylib 0x46799e5d4 + 9513453012
1 libc++.1.dylib 0x32b100704 + 6858192644
2 Tonie-App 0x2054718f0 [inlined] worklets::EventLoop::run::lambda::operator() (EventLoop.cpp:36)
3 Tonie-App 0x2054718f0 [inlined] std::__1::__invoke[abi:ne200100] (invoke.h:179)
4 Tonie-App 0x2054718f0 [inlined] std::__1::__thread_execute[abi:ne200100] (thread.h:205)
5 Tonie-App 0x2054718f0 std::__1::__thread_proxy[abi:ne200100] (thread.h:214)
6 libsystem_pthread.dylib 0x3c610844c + 8158381132

Thread 0 crashed with ARM Thread State (64-bit):
x0: 0x0000000109350b40 x1: 0x00000002001c96a8 x2: 0x000000016b7be2d0 x3: 0x0000000000000000
x4: 0x0000000000000001 x5: 0x0000000000000000 x6: 0x00000001092bc600 x7: 0xfffff0003ffff800
x8: 0x00000001f49947a0 x9: 0x0000000186f33498 x10: 0x6ae1000109350b40 x11: 0x000000000000001f
x12: 0x000000000078c980 x13: 0x000000010903de20 x14: 0xc0b15262c7721364 x15: 0x00315262c7721360
x16: 0x00315262c7721360 x17: 0x00000001f4901600 x18: 0x0000000000000000 x19: 0x00000001f30470c4
x20: 0x0000000000000000 x21: 0x0000000000000001 x22: 0x00000001091d7f70 x23: 0x0000000109350b40
x24: 0x000000010bf1cdc0 x25: 0x00000001091c5e00 x26: 0x0000000000000114 x27: 0x0000000000000000
x28: 0xffffffff76ffffff fp: 0x000000016b7be2c0 lr: 0x0000000186f33248 sp: 0x000000016b7be240
pc: 0x000000018686b020 cpsr: 0x0000000020000000

EOF`

Metadata

Metadata

Assignees

No one assigned
    No fields configured for issues without a type.

    Projects

    Status

    Waiting for: Product Owner

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions