Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

App crash in background on iOS when using with CodePush #206

Open
KirillRodichev opened this issue Dec 6, 2023 · 10 comments
Open

App crash in background on iOS when using with CodePush #206

KirillRodichev opened this issue Dec 6, 2023 · 10 comments

Comments

@KirillRodichev
Copy link

"react-native-mmkv": "2.11.0",
"react-native-quick-crypto": "0.6.1",
"react-native-code-push": "8.1.0",

Preconditions: CodePush is configured to install updates on app suspend

STR:

push an update to CodePush
move it to the background
move app to foreground

AR: In background, after bundle installation the app crashes leading to a rollback in CodePush

ENV:

iOS 16.0
iPhone iPhone X

Seems to be related to mrousavy/react-native-mmkv#494, but this time on the newer version
For the previous issue I was able to create a patch. Maybe this time we'll be able to make an update to the library :)

Stack trace:

OS Version: iOS 16.0 (20A362)
Report Version: 104

Exception Type: EXC_BAD_ACCESS (SIGBUS)
Exception Codes: BUS_NOOP at 0x0000000283282880
Crashed Thread: 9

Application Specific Information:
Exception 1, Code 2, Subcode 10790381696 >
KERN_PROTECTION_FAILURE at 0x283282880.

Thread 9 Crashed:
0   <unknown>                       0x283282880         <redacted>
1   DEV UTORG                       0x2029e2c54         _ZN13MGLTypedArrayIL17MGLTypedArrayKind3EEC1ERN8facebook3jsi7RuntimeENSt3__16vectorIhNS6_9allocatorIhEEEE
2   DEV UTORG                       0x2029e2d04         _ZN13MGLTypedArrayIL17MGLTypedArrayKind3EEC1ERN8facebook3jsi7RuntimeENSt3__16vectorIhNS6_9allocatorIhEEEE
3   DEV UTORG                       0x2029e2cb0         _ZN13MGLTypedArrayIL17MGLTypedArrayKind3EEC1ERN8facebook3jsi7RuntimeENSt3__16vectorIhNS6_9allocatorIhEEEE
4   DEV UTORG                       0x2029db4f8         _ZN7margelo16PasswordCallbackEPciiPv
5   DEV UTORG                       0x202484b00         _ZN5folly17exception_wrapper12ExceptionPtr18get_exception_ptr_EPKS0_
6   DEV UTORG                       0x20264f764         _ZN5folly6detail8function9execSmallIZNS_7futures6detail4CoreINS_4UnitEE11setCallbackIZNS4_10FutureBaseIS6_E18thenImplementationIZNRS_6FutureIS6_E3viaENS_8Executor9KeepAliveISE_EEEUlOSG_ONS_3TryIS6_EEE_NS4_25tryExecutorCallableResultIS6_SL_vEEEENSt3__19e...
7   hermes                          0x104569724         _ZN8facebook6hermes8debugger8Debugger23jsiValueFromHermesValueEN6hermes2vm11HermesValueE
8   hermes                          0x1046700ac         _ZN8facebook3jsi7JSErrorD0Ev
9   hermes                          0x1045dfcb8         _ZN8facebook3jsi7JSErrorD0Ev
10  hermes                          0x1045e0140         _ZN8facebook3jsi7JSErrorD0Ev
11  hermes                          0x1045671e8         _ZN8facebook6hermes8debugger8Debugger23jsiValueFromHermesValueEN6hermes2vm11HermesValueE
12  hermes                          0x1045648b0         _ZN8facebook6hermes8debugger8Debugger23jsiValueFromHermesValueEN6hermes2vm11HermesValueE
13  DEV UTORG                       0x202484b00         _ZN5folly17exception_wrapper12ExceptionPtr18get_exception_ptr_EPKS0_
14  DEV UTORG                       0x20264d0c4         _ZN5folly6detail8function9execSmallIZNS_7futures6detail4CoreINS_4UnitEE11setCallbackIZNS4_10FutureBaseIS6_E18thenImplementationIZNRS_6FutureIS6_E3viaENS_8Executor9KeepAliveISE_EEEUlOSG_ONS_3TryIS6_EEE_NS4_25tryExecutorCallableResultIS6_SL_vEEEENSt3__19e...
15  DEV UTORG                       0x202484b00         _ZN5folly17exception_wrapper12ExceptionPtr18get_exception_ptr_EPKS0_
16  DEV UTORG                       0x20264c8c8         _ZN5folly6detail8function9execSmallIZNS_7futures6detail4CoreINS_4UnitEE11setCallbackIZNS4_10FutureBaseIS6_E18thenImplementationIZNRS_6FutureIS6_E3viaENS_8Executor9KeepAliveISE_EEEUlOSG_ONS_3TryIS6_EEE_NS4_25tryExecutorCallableResultIS6_SL_vEEEENSt3__19e...
17  DEV UTORG                       0x20264cacc         _ZN5folly6detail8function9execSmallIZNS_7futures6detail4CoreINS_4UnitEE11setCallbackIZNS4_10FutureBaseIS6_E18thenImplementationIZNRS_6FutureIS6_E3viaENS_8Executor9KeepAliveISE_EEEUlOSG_ONS_3TryIS6_EEE_NS4_25tryExecutorCallableResultIS6_SL_vEEEENSt3__19e...
18  DEV UTORG                       0x20257d224         _ZN8facebook5react11JSIExecutor21defaultTimeoutInvokerERKNSt3__18functionIFvvEEENS3_IFNS2_12basic_stringIcNS2_11char_traitsIcEENS2_9allocatorIcEEEEvEEE
19  DEV UTORG                       0x202589070         _ZN8facebook5react11JSIExecutor21defaultTimeoutInvokerERKNSt3__18functionIFvvEEENS3_IFNS2_12basic_stringIcNS2_11char_traitsIcEENS2_9allocatorIcEEEEvEEE
20  DEV UTORG                       0x2025893b4         _ZN8facebook5react11JSIExecutor21defaultTimeoutInvokerERKNSt3__18functionIFvvEEENS3_IFNS2_12basic_stringIcNS2_11char_traitsIcEENS2_9allocatorIcEEEEvEEE
21  DEV UTORG                       0x20262022c         _ZN8facebook5react11JSIExecutor21defaultTimeoutInvokerERKNSt3__18functionIFvvEEENS3_IFNS2_12basic_stringIcNS2_11char_traitsIcEENS2_9allocatorIcEEEEvEEE
22  DEV UTORG                       0x202616ad0         _ZN8facebook5react11JSIExecutor21defaultTimeoutInvokerERKNSt3__18functionIFvvEEENS3_IFNS2_12basic_stringIcNS2_11char_traitsIcEENS2_9allocatorIcEEEEvEEE
23  DEV UTORG                       0x20257a30c         _ZNK5folly3TryINS_4UnitEE16throwUnlessValueEv
24  DEV UTORG                       0x202577650         _ZNK5folly3TryINS_4UnitEE16throwUnlessValueEv
25  DEV UTORG                       0x20257d224         _ZN8facebook5react11JSIExecutor21defaultTimeoutInvokerERKNSt3__18functionIFvvEEENS3_IFNS2_12basic_stringIcNS2_11char_traitsIcEENS2_9allocatorIcEEEEvEEE
26  DEV UTORG                       0x202572dcc         _ZNK5folly3TryINS_4UnitEE16throwUnlessValueEv
27  Foundation                      0x334d3a2cc         <redacted>
28  CoreFoundation                  0x33668e500         <redacted>
29  CoreFoundation                  0x336699e70         <redacted>
30  CoreFoundation                  0x336624224         <redacted>
31  CoreFoundation                  0x336639230         <redacted>
32  CoreFoundation                  0x33663ddfc         CFRunLoopRunSpecific
33  DEV UTORG                       0x202572d04         _ZNK5folly3TryINS_4UnitEE16throwUnlessValueEv
34  Foundation                      0x334d57f44         <redacted>
35  libsystem_pthread.dylib         0x3ce731060         _pthread_start

Thread 0
0   DEV UTORG                       0x2030d6fd0         _ZN5folly6detail8function14FunctionTraitsIFvRKN8facebook6hermes8debugger12ProgramStateEEE10uninitCallES8_RNS1_4DataE
1   DEV UTORG                       0x2030a42f8         _ZN6RNSkia8RNSkView13requestRedrawEv
2   libdispatch.dylib               0x34dca07c8         <redacted>
3   libdispatch.dylib               0x34dc82b54         <redacted>
4   DEV UTORG                       0x2030a4104         _ZN6RNSkia8RNSkView13requestRedrawEv
5   DEV UTORG                       0x2030a3efc         _ZN6RNSkia8RNSkView13requestRedrawEv
6   DEV UTORG                       0x2030b24d4         _ZN6RNSkia8RNSkView13requestRedrawEv
7   UIKitCore                       0x3443a1568         <redacted>
8   UIKitCore                       0x34439ee80         <redacted>
9   UIKitCore                       0x3447cb3cc         <redacted>
10  UIKitCore                       0x344b0e218         <redacted>
11  UIKitCore                       0x344523fe4         <redacted>
12  UIKitCore                       0x344523f30         <redacted>
13  UIKitCore                       0x344523e6c         <redacted>
14  libdispatch.dylib               0x34dc9f850         <redacted>
15  libdispatch.dylib               0x34dca07c8         <redacted>
16  libdispatch.dylib               0x34dc81f18         <redacted>
17  libdispatch.dylib               0x34dc81b90         <redacted>
18  CoreFoundation                  0x336655ac8         <redacted>
19  CoreFoundation                  0x336639754         <redacted>
20  CoreFoundation                  0x33663ddfc         CFRunLoopRunSpecific
21  GraphicsServices                0x3aa423984         GSEventRunModal
22  UIKitCore                       0x344708e7c         <redacted>
23  UIKitCore                       0x344708af4         UIApplicationMain
24  DEV UTORG                       0x2022dd1e0         <redacted>
25  <unknown>                       0x1d60c2de0         <redacted>

Thread 1 name: com.apple.uikit.eventfetch-thread
0   libsystem_kernel.dylib          0x3b0fab194         mach_msg2_trap
1   libsystem_kernel.dylib          0x3b0fbca08         mach_msg2_internal
2   libsystem_kernel.dylib          0x3b0fbcc44         mach_msg_overwrite
3   libsystem_kernel.dylib          0x3b0fab688         mach_msg
4   CoreFoundation                  0x336638244         <redacted>
5   CoreFoundation                  0x3366393f4         <redacted>
6   CoreFoundation                  0x33663ddfc         CFRunLoopRunSpecific
7   Foundation                      0x334d403fc         <redacted>
8   Foundation                      0x334d402f8         <redacted>
9   UIKitCore                       0x34482d6d0         <redacted>
10  Foundation                      0x334d57f44         <redacted>
11  libsystem_pthread.dylib         0x3ce731060         _pthread_start

Thread 2 name: com.apple.NSURLConnectionLoader
0   libsystem_kernel.dylib          0x3b0fab194         mach_msg2_trap
1   libsystem_kernel.dylib          0x3b0fbca08         mach_msg2_internal
2   libsystem_kernel.dylib          0x3b0fbcc44         mach_msg_overwrite
3   libsystem_kernel.dylib          0x3b0fab688         mach_msg
4   CoreFoundation                  0x336638244         <redacted>
5   CoreFoundation                  0x3366393f4         <redacted>
6   CoreFoundation                  0x33663ddfc         CFRunLoopRunSpecific
7   CFNetwork                       0x3426a56cc         _CFURLStorageSessionDisableCache
8   Foundation                      0x334d57f44         <redacted>
9   libsystem_pthread.dylib         0x3ce731060         _pthread_start

Thread 3
0   libsystem_kernel.dylib          0x3b0fab610         __semwait_signal
1   libsystem_c.dylib               0x34dd49330         nanosleep
2   libsystem_c.dylib               0x34dd5cf18         sleep
3   DEV UTORG                       0x2026dda70         _ZN5folly17exception_wrapper7InPlaceIN8facebook6hermes9inspector32MultipleCommandsPendingExceptionEE18get_exception_ptr_EPKS0_
4   libsystem_pthread.dylib         0x3ce731060         _pthread_start

Thread 4 name: SentryCrash Exception Handler (Secondary)
0   libsystem_kernel.dylib          0x3b0fab194         mach_msg2_trap
1   libsystem_kernel.dylib          0x3b0fbca08         mach_msg2_internal
2   libsystem_kernel.dylib          0x3b0fbcc44         mach_msg_overwrite
3   libsystem_kernel.dylib          0x3b0fab688         mach_msg
4   DEV UTORG                       0x2026e974c         __cxa_throw
5   libsystem_pthread.dylib         0x3ce731060         _pthread_start

Thread 6 name: io.sentry.app-hang-tracker
0   libsystem_kernel.dylib          0x3b0fab610         __semwait_signal
1   libsystem_c.dylib               0x34dd49330         nanosleep
2   Foundation                      0x334da9f4c         <redacted>
3   DEV UTORG                       0x2026cdee0         _ZN5folly17exception_wrapper7InPlaceIN8facebook6hermes9inspector32MultipleCommandsPendingExceptionEE18get_exception_ptr_EPKS0_
4   Foundation                      0x334d57f44         <redacted>
5   libsystem_pthread.dylib         0x3ce731060         _pthread_start

Thread 7 name: com.squareup.SocketRocket.NetworkThread
0   libsystem_kernel.dylib          0x3b0fab194         mach_msg2_trap
1   libsystem_kernel.dylib          0x3b0fbca08         mach_msg2_internal
2   libsystem_kernel.dylib          0x3b0fbcc44         mach_msg_overwrite
3   libsystem_kernel.dylib          0x3b0fab688         mach_msg
4   CoreFoundation                  0x336638244         <redacted>
5   CoreFoundation                  0x3366393f4         <redacted>
6   CoreFoundation                  0x33663ddfc         CFRunLoopRunSpecific
7   Foundation                      0x334d403fc         <redacted>
8   DEV UTORG                       0x2025a90d4         _ZN8facebook5react11JSIExecutor21defaultTimeoutInvokerERKNSt3__18functionIFvvEEENS3_IFNS2_12basic_stringIcNS2_11char_traitsIcEENS2_9allocatorIcEEEEvEEE
9   Foundation                      0x334d57f44         <redacted>
10  libsystem_pthread.dylib         0x3ce731060         _pthread_start

Thread 8 name: com.apple.CFSocket.private
0   libsystem_kernel.dylib          0x3b0fabc5c         select$DARWIN_EXTSN
1   CoreFoundation                  0x336684418         <redacted>
2   libsystem_pthread.dylib         0x3ce731060         _pthread_start

Thread 9 name: com.facebook.react.JavaScript Crashed:
0   <unknown>                       0x283282880         <redacted>
1   DEV UTORG                       0x2029e2c54         _ZN13MGLTypedArrayIL17MGLTypedArrayKind3EEC1ERN8facebook3jsi7RuntimeENSt3__16vectorIhNS6_9allocatorIhEEEE
2   DEV UTORG                       0x2029e2d04         _ZN13MGLTypedArrayIL17MGLTypedArrayKind3EEC1ERN8facebook3jsi7RuntimeENSt3__16vectorIhNS6_9allocatorIhEEEE
3   DEV UTORG                       0x2029e2cb0         _ZN13MGLTypedArrayIL17MGLTypedArrayKind3EEC1ERN8facebook3jsi7RuntimeENSt3__16vectorIhNS6_9allocatorIhEEEE
4   DEV UTORG                       0x2029db4f8         _ZN7margelo16PasswordCallbackEPciiPv
5   DEV UTORG                       0x202484b00         _ZN5folly17exception_wrapper12ExceptionPtr18get_exception_ptr_EPKS0_
6   DEV UTORG                       0x20264f764         _ZN5folly6detail8function9execSmallIZNS_7futures6detail4CoreINS_4UnitEE11setCallbackIZNS4_10FutureBaseIS6_E18thenImplementationIZNRS_6FutureIS6_E3viaENS_8Executor9KeepAliveISE_EEEUlOSG_ONS_3TryIS6_EEE_NS4_25tryExecutorCallableResultIS6_SL_vEEEENSt3__19e...
7   hermes                          0x104569724         _ZN8facebook6hermes8debugger8Debugger23jsiValueFromHermesValueEN6hermes2vm11HermesValueE
8   hermes                          0x1046700ac         _ZN8facebook3jsi7JSErrorD0Ev
9   hermes                          0x1045dfcb8         _ZN8facebook3jsi7JSErrorD0Ev
10  hermes                          0x1045e0140         _ZN8facebook3jsi7JSErrorD0Ev
11  hermes                          0x1045671e8         _ZN8facebook6hermes8debugger8Debugger23jsiValueFromHermesValueEN6hermes2vm11HermesValueE
12  hermes                          0x1045648b0         _ZN8facebook6hermes8debugger8Debugger23jsiValueFromHermesValueEN6hermes2vm11HermesValueE
13  DEV UTORG                       0x202484b00         _ZN5folly17exception_wrapper12ExceptionPtr18get_exception_ptr_EPKS0_
14  DEV UTORG                       0x20264d0c4         _ZN5folly6detail8function9execSmallIZNS_7futures6detail4CoreINS_4UnitEE11setCallbackIZNS4_10FutureBaseIS6_E18thenImplementationIZNRS_6FutureIS6_E3viaENS_8Executor9KeepAliveISE_EEEUlOSG_ONS_3TryIS6_EEE_NS4_25tryExecutorCallableResultIS6_SL_vEEEENSt3__19e...
15  DEV UTORG                       0x202484b00         _ZN5folly17exception_wrapper12ExceptionPtr18get_exception_ptr_EPKS0_
16  DEV UTORG                       0x20264c8c8         _ZN5folly6detail8function9execSmallIZNS_7futures6detail4CoreINS_4UnitEE11setCallbackIZNS4_10FutureBaseIS6_E18thenImplementationIZNRS_6FutureIS6_E3viaENS_8Executor9KeepAliveISE_EEEUlOSG_ONS_3TryIS6_EEE_NS4_25tryExecutorCallableResultIS6_SL_vEEEENSt3__19e...
17  DEV UTORG                       0x20264cacc         _ZN5folly6detail8function9execSmallIZNS_7futures6detail4CoreINS_4UnitEE11setCallbackIZNS4_10FutureBaseIS6_E18thenImplementationIZNRS_6FutureIS6_E3viaENS_8Executor9KeepAliveISE_EEEUlOSG_ONS_3TryIS6_EEE_NS4_25tryExecutorCallableResultIS6_SL_vEEEENSt3__19e...
18  DEV UTORG                       0x20257d224         _ZN8facebook5react11JSIExecutor21defaultTimeoutInvokerERKNSt3__18functionIFvvEEENS3_IFNS2_12basic_stringIcNS2_11char_traitsIcEENS2_9allocatorIcEEEEvEEE
19  DEV UTORG                       0x202589070         _ZN8facebook5react11JSIExecutor21defaultTimeoutInvokerERKNSt3__18functionIFvvEEENS3_IFNS2_12basic_stringIcNS2_11char_traitsIcEENS2_9allocatorIcEEEEvEEE
20  DEV UTORG                       0x2025893b4         _ZN8facebook5react11JSIExecutor21defaultTimeoutInvokerERKNSt3__18functionIFvvEEENS3_IFNS2_12basic_stringIcNS2_11char_traitsIcEENS2_9allocatorIcEEEEvEEE
21  DEV UTORG                       0x20262022c         _ZN8facebook5react11JSIExecutor21defaultTimeoutInvokerERKNSt3__18functionIFvvEEENS3_IFNS2_12basic_stringIcNS2_11char_traitsIcEENS2_9allocatorIcEEEEvEEE
22  DEV UTORG                       0x202616ad0         _ZN8facebook5react11JSIExecutor21defaultTimeoutInvokerERKNSt3__18functionIFvvEEENS3_IFNS2_12basic_stringIcNS2_11char_traitsIcEENS2_9allocatorIcEEEEvEEE
23  DEV UTORG                       0x20257a30c         _ZNK5folly3TryINS_4UnitEE16throwUnlessValueEv
24  DEV UTORG                       0x202577650         _ZNK5folly3TryINS_4UnitEE16throwUnlessValueEv
25  DEV UTORG                       0x20257d224         _ZN8facebook5react11JSIExecutor21defaultTimeoutInvokerERKNSt3__18functionIFvvEEENS3_IFNS2_12basic_stringIcNS2_11char_traitsIcEENS2_9allocatorIcEEEEvEEE
26  DEV UTORG                       0x202572dcc         _ZNK5folly3TryINS_4UnitEE16throwUnlessValueEv
27  Foundation                      0x334d3a2cc         <redacted>
28  CoreFoundation                  0x33668e500         <redacted>
29  CoreFoundation                  0x336699e70         <redacted>
30  CoreFoundation                  0x336624224         <redacted>
31  CoreFoundation                  0x336639230         <redacted>
32  CoreFoundation                  0x33663ddfc         CFRunLoopRunSpecific
33  DEV UTORG                       0x202572d04         _ZNK5folly3TryINS_4UnitEE16throwUnlessValueEv
34  Foundation                      0x334d57f44         <redacted>
35  libsystem_pthread.dylib         0x3ce731060         _pthread_start

Thread 10 name: hades
0   libsystem_kernel.dylib          0x3b0fab9e0         __psynch_cvwait
1   libsystem_pthread.dylib         0x3ce730584         <redacted>
2   libc++.1.dylib                  0x35b0c68b4         _ZNSt3__118condition_variable4waitERNS_11unique_lockINS_5mutexEEE
3   hermes                          0x104674ca8         _ZN8facebook3jsi7JSErrorD0Ev
4   hermes                          0x104674a5c         _ZN8facebook3jsi7JSErrorD0Ev
5   libsystem_pthread.dylib         0x3ce731060         _pthread_start

Thread 11 name: hades
0   libsystem_kernel.dylib          0x3b0fab9e0         __psynch_cvwait
1   libsystem_pthread.dylib         0x3ce730584         <redacted>
2   libc++.1.dylib                  0x35b0c68b4         _ZNSt3__118condition_variable4waitERNS_11unique_lockINS_5mutexEEE
3   hermes                          0x104674ca8         _ZN8facebook3jsi7JSErrorD0Ev
4   hermes                          0x104674a5c         _ZN8facebook3jsi7JSErrorD0Ev
5   libsystem_pthread.dylib         0x3ce731060         _pthread_start

Thread 12 name: hermes-chrome-inspector-conn
0   libsystem_kernel.dylib          0x3b0fab9e0         __psynch_cvwait
1   libsystem_pthread.dylib         0x3ce730584         <redacted>
2   libc++.1.dylib                  0x35b0c68b4         _ZNSt3__118condition_variable4waitERNS_11unique_lockINS_5mutexEEE
3   DEV UTORG                       0x20267b5cc         _ZN5folly17exception_wrapper7InPlaceIN8facebook6hermes9inspector32MultipleCommandsPendingExceptionEE18get_exception_ptr_EPKS0_
4   DEV UTORG                       0x202634208         _ZN8facebook6hermes9inspector6detail6Thread3runENSt3__112basic_stringIcNS4_11char_traitsIcEENS4_9allocatorIcEEEENS4_8functionIFvvEEE
5   libsystem_pthread.dylib         0x3ce731060         _pthread_start

Thread 13 name: hermes-inspector
0   libsystem_kernel.dylib          0x3b0fab9e0         __psynch_cvwait
1   libsystem_pthread.dylib         0x3ce730584         <redacted>
2   libc++.1.dylib                  0x35b0c68b4         _ZNSt3__118condition_variable4waitERNS_11unique_lockINS_5mutexEEE
3   DEV UTORG                       0x20267b5cc         _ZN5folly17exception_wrapper7InPlaceIN8facebook6hermes9inspector32MultipleCommandsPendingExceptionEE18get_exception_ptr_EPKS0_
4   DEV UTORG                       0x202634208         _ZN8facebook6hermes9inspector6detail6Thread3runENSt3__112basic_stringIcNS4_11char_traitsIcEENS4_9allocatorIcEEEENS4_8functionIFvvEEE
5   libsystem_pthread.dylib         0x3ce731060         _pthread_start

Thread 14
0   libsystem_kernel.dylib          0x3b0fab9e0         __psynch_cvwait
1   libsystem_pthread.dylib         0x3ce730584         <redacted>
2   libc++.1.dylib                  0x35b0c68b4         _ZNSt3__118condition_variable4waitERNS_11unique_lockINS_5mutexEEE
3   DEV UTORG                       0x2029c9da8         _ZN10TypedArrayIL14TypedArrayKind3EE6updateERN8facebook3jsi7RuntimeERKNSt3__16vectorIhNS6_9allocatorIhEEEE
4   DEV UTORG                       0x2029ca0c8         _ZN10TypedArrayIL14TypedArrayKind3EE6updateERN8facebook3jsi7RuntimeERKNSt3__16vectorIhNS6_9allocatorIhEEEE
5   libsystem_pthread.dylib         0x3ce731060         _pthread_start

Thread 15
0   libsystem_kernel.dylib          0x3b0fab9e0         __psynch_cvwait
1   libsystem_pthread.dylib         0x3ce730584         <redacted>
2   libc++.1.dylib                  0x35b0c68b4         _ZNSt3__118condition_variable4waitERNS_11unique_lockINS_5mutexEEE
3   DEV UTORG                       0x2029f2b10         _ZN13MGLTypedArrayIL17MGLTypedArrayKind3EEC1ERN8facebook3jsi7RuntimeENSt3__16vectorIhNS6_9allocatorIhEEEE
4   DEV UTORG                       0x2029f2e18         _ZN13MGLTypedArrayIL17MGLTypedArrayKind3EEC1ERN8facebook3jsi7RuntimeENSt3__16vectorIhNS6_9allocatorIhEEEE
5   libsystem_pthread.dylib         0x3ce731060         _pthread_start

Thread 16
0   libsystem_pthread.dylib         0x3ce72f674         <redacted>

Thread 17
0   libsystem_kernel.dylib          0x3b0fab654         __workq_kernreturn
1   libsystem_pthread.dylib         0x3ce72fb9c         _pthread_wqthread

Thread 18
0   libsystem_kernel.dylib          0x3b0fab654         __workq_kernreturn
1   libsystem_pthread.dylib         0x3ce72fb9c         _pthread_wqthread

Thread 19
0   libsystem_platform.dylib        0x3ce603b04         _platform_bzero
1   libsqlite3.dylib                0x382f9fe7c         sqlite3_log
2   libsqlite3.dylib                0x38308e860         sqlite3_sourceid
3   libsqlite3.dylib                0x382f9f9a4         sqlite3_log
4   libsqlite3.dylib                0x383033f34         sqlite3_sourceid
5   libsqlite3.dylib                0x382f9a964         sqlite3_finalize
6   libsqlite3.dylib                0x382fbace4         sqlite3_step
7   libsqlite3.dylib                0x382fb9690         sqlite3_step
8   DEV UTORG                       0x2030ab678         _ZN6RNSkia8RNSkView13requestRedrawEv
9   DEV UTORG                       0x20304cf40         _ZN6RNSkia8RNSkView13requestRedrawEv
10  DEV UTORG                       0x20304c914         _ZN6RNSkia8RNSkView13requestRedrawEv
11  DEV UTORG                       0x20305b088         _ZN6RNSkia8RNSkView13requestRedrawEv
12  DEV UTORG                       0x20304f230         _ZN6RNSkia8RNSkView13requestRedrawEv
13  DEV UTORG                       0x20304f1e0         _ZN6RNSkia8RNSkView13requestRedrawEv
14  DEV UTORG                       0x20304eebc         _ZN6RNSkia8RNSkView13requestRedrawEv
15  DEV UTORG                       0x2030a1010         _ZN6RNSkia8RNSkView13requestRedrawEv
16  libdispatch.dylib               0x34dc9f850         <redacted>
17  libdispatch.dylib               0x34dca07c8         <redacted>
18  libdispatch.dylib               0x34dc7b854         <redacted>
19  libdispatch.dylib               0x34dc7c2e4         <redacted>
20  libdispatch.dylib               0x34dc86000         <redacted>
21  libsystem_pthread.dylib         0x3ce72fb50         _pthread_wqthread

Thread 20
0   libsystem_kernel.dylib          0x3b0fab654         __workq_kernreturn
1   libsystem_pthread.dylib         0x3ce72fb9c         _pthread_wqthread

Thread 21
0   libsystem_kernel.dylib          0x3b0fab194         mach_msg2_trap
1   libsystem_kernel.dylib          0x3b0fbca08         mach_msg2_internal
2   libsystem_kernel.dylib          0x3b0fb0530         vm_copy
3   Foundation                      0x334dacee4         NSCopyMemoryPages
4   Foundation                      0x334d4c100         <redacted>
5   Foundation                      0x334d4ba70         <redacted>
6   Foundation                      0x334d4c200         <redacted>
7   Foundation                      0x334d4bb3c         <redacted>
8   DEV UTORG                       0x202560660         _ZNK5folly3TryINS_4UnitEE16throwUnlessValueEv
9   DEV UTORG                       0x202560718         _ZNK5folly3TryINS_4UnitEE16throwUnlessValueEv
10  DEV UTORG                       0x202578a24         _ZNK5folly3TryINS_4UnitEE16throwUnlessValueEv
11  DEV UTORG                       0x20257d224         _ZN8facebook5react11JSIExecutor21defaultTimeoutInvokerERKNSt3__18functionIFvvEEENS3_IFNS2_12basic_stringIcNS2_11char_traitsIcEENS2_9allocatorIcEEEEvEEE
12  DEV UTORG                       0x202572dcc         _ZNK5folly3TryINS_4UnitEE16throwUnlessValueEv
13  DEV UTORG                       0x20257869c         _ZNK5folly3TryINS_4UnitEE16throwUnlessValueEv
14  DEV UTORG                       0x20257850c         _ZNK5folly3TryINS_4UnitEE16throwUnlessValueEv
15  DEV UTORG                       0x202576574         _ZNK5folly3TryINS_4UnitEE16throwUnlessValueEv
16  DEV UTORG                       0x202574050         _ZNK5folly3TryINS_4UnitEE16throwUnlessValueEv
17  libdispatch.dylib               0x34dc9f850         <redacted>
18  libdispatch.dylib               0x34dca07c8         <redacted>
19  libdispatch.dylib               0x34dc84e68         <redacted>
20  libdispatch.dylib               0x34dc85514         <redacted>
21  libsystem_pthread.dylib         0x3ce72fb14         _pthread_wqthread

Thread 22
0   libsystem_kernel.dylib          0x3b0fab654         __workq_kernreturn
1   libsystem_pthread.dylib         0x3ce72fb9c         _pthread_wqthread

Thread 23
0   libsystem_kernel.dylib          0x3b0fab194         mach_msg2_trap
1   libsystem_kernel.dylib          0x3b0fbca08         mach_msg2_internal
2   libsystem_kernel.dylib          0x3b0fbcc44         mach_msg_overwrite
3   libsystem_kernel.dylib          0x3b0fab688         mach_msg
4   CoreFoundation                  0x336638244         <redacted>
5   CoreFoundation                  0x3366393f4         <redacted>
6   CoreFoundation                  0x33663ddfc         CFRunLoopRunSpecific
7   DEV UTORG                       0x202572d04         _ZNK5folly3TryINS_4UnitEE16throwUnlessValueEv
8   Foundation                      0x334d57f44         <redacted>
9   libsystem_pthread.dylib         0x3ce731060         _pthread_start

Thread 24
0   libsystem_kernel.dylib          0x3b0fab9e0         __psynch_cvwait
1   libsystem_pthread.dylib         0x3ce730584         <redacted>
2   libc++.1.dylib                  0x35b0c68b4         _ZNSt3__118condition_variable4waitERNS_11unique_lockINS_5mutexEEE
3   hermes                          0x104674ca8         _ZN8facebook3jsi7JSErrorD0Ev
4   hermes                          0x104674a5c         _ZN8facebook3jsi7JSErrorD0Ev
5   libsystem_pthread.dylib         0x3ce731060         _pthread_start

Thread 25
0   libsystem_kernel.dylib          0x3b0fab9e0         __psynch_cvwait
1   libsystem_pthread.dylib         0x3ce730584         <redacted>
2   libc++.1.dylib                  0x35b0c68b4         _ZNSt3__118condition_variable4waitERNS_11unique_lockINS_5mutexEEE
3   DEV UTORG                       0x20267b5cc         _ZN5folly17exception_wrapper7InPlaceIN8facebook6hermes9inspector32MultipleCommandsPendingExceptionEE18get_exception_ptr_EPKS0_
4   DEV UTORG                       0x202634208         _ZN8facebook6hermes9inspector6detail6Thread3runENSt3__112basic_stringIcNS4_11char_traitsIcEENS4_9allocatorIcEEEENS4_8functionIFvvEEE
5   libsystem_pthread.dylib         0x3ce731060         _pthread_start

Thread 26
0   libsystem_kernel.dylib          0x3b0fab9e0         __psynch_cvwait
1   libsystem_pthread.dylib         0x3ce730584         <redacted>
2   libc++.1.dylib                  0x35b0c68b4         _ZNSt3__118condition_variable4waitERNS_11unique_lockINS_5mutexEEE
3   DEV UTORG                       0x20267b5cc         _ZN5folly17exception_wrapper7InPlaceIN8facebook6hermes9inspector32MultipleCommandsPendingExceptionEE18get_exception_ptr_EPKS0_
4   DEV UTORG                       0x202634208         _ZN8facebook6hermes9inspector6detail6Thread3runENSt3__112basic_stringIcNS4_11char_traitsIcEENS4_9allocatorIcEEEENS4_8functionIFvvEEE
5   libsystem_pthread.dylib         0x3ce731060         _pthread_start
@KirillRodichev KirillRodichev changed the title App crash in background on iOS when using with react-native-quick-crypto and CodePush App crash in background on iOS when using with CodePush Dec 6, 2023
@KirillRodichevUtorg
Copy link

Was able to fix by implementing InvalidateCacheOnDestroy as it's done in react-native-mmkv

@Abramovick
Copy link

InvalidateCacheOnDestroy

Facing the same issue, can you please explain more how you fixed it with InvalidateCacheOnDestroy

@Sangkwun
Copy link

Sangkwun commented Mar 9, 2024

I'm facing same problem.
@KirillRodichev @KirillRodichevUtorg do you have any idea to fix it?

Exception 1, Code 2, Subcode 10772527776 >
KERN_PROTECTION_FAILURE at 0x28217baa0.

@KirillRodichevUtorg
Copy link

@Sangkwun, yes, I've mentioned previously how I fixed the issue

Was able to fix by implementing InvalidateCacheOnDestroy as it's done in react-native-mmkv

@Sangkwun
Copy link

Sangkwun commented Mar 10, 2024

@KirillRodichevUtorg
Did you follow any specific direction in React-native-mmkv, or did you modify InvalidateCacheOnDestroy?
I'm using the latest version of React-native-mmkv, but it doesn't seem like anything has been altered.

@KirillRodichevUtorg
Copy link

@Sangkwun, I didn't modify mmkv, I patched quick-crypto so that MGLTypedArray implementa cache invalidation as it's done in latest mmkv version

@Sangkwun
Copy link

Sangkwun commented Mar 10, 2024

I see.
Maybe I need to follow this PR
mrousavy/react-native-mmkv#519

Your patch seem like they could be very helpful.
Could you provide PR or snippet?

on my reseach mmkv invalidate needs key but MGLTypedArray doesn't.

@fleuverouge
Copy link

fleuverouge commented Sep 13, 2024

@Sangkwun, I didn't modify mmkv, I patched quick-crypto so that MGLTypedArray implementa cache invalidation as it's done in latest mmkv version

Hi @KirillRodichevUtorg
Can you please share your patch? I'm facing the same issue

@Rag0n
Copy link

Rag0n commented Oct 18, 2024

Hey @KirillRodichevUtorg, please share patch if you have time.
We can try to fix and improve library instead of patching it.

@KirillRodichevUtorg
Copy link

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

6 participants