shakebugs / shake-react-native

Bug reporting SDK for React Native apps.
https://shakebugs.com
11 stars 1 forks source link

Crashes on iOS #2

Closed zjkuang closed 9 months ago

zjkuang commented 1 year ago

Crashlytics log:

Fatal Exception: NSInvalidArgumentException
0  CoreFoundation                 0x9cb4 __exceptionPreprocess
1  libobjc.A.dylib                0x183d0 objc_exception_throw
2  CoreFoundation                 0x17eab8 +[NSObject(NSObject) _copyDescription]
3  CoreFoundation                 0x200e8 ___forwarding___
4  CoreFoundation                 0x86900 _CF_forwarding_prep_0
5  Shake                          0xf7aa8 (Missing UUID 1bcebc1001bc3155926f947f695b5c25)
6  Shake                          0x95fc (Missing UUID 1bcebc1001bc3155926f947f695b5c25)
7  Shake                          0x94b4 (Missing UUID 1bcebc1001bc3155926f947f695b5c25)
8  GasBuddy                       0xd81234 -[RNShake log::] + 233 (RNShake.m:233)
9  CoreFoundation                 0x72c04 __invoking___
10 CoreFoundation                 0x20cb4 -[NSInvocation invoke]
11 CoreFoundation                 0x206cc -[NSInvocation invokeWithTarget:]
12 GasBuddy                       0x5e13b4 -[RCTModuleMethod invokeWithBridge:module:arguments:] + 587 (RCTModuleMethod.mm:587)
13 GasBuddy                       0x5e3598 facebook::react::invokeInner(RCTBridge*, RCTModuleData*, unsigned int, folly::dynamic const&, int, (anonymous namespace)::SchedulingContext) + 196 (RCTNativeModule.mm:196)
14 GasBuddy                       0x5e3220 invocation function for block in facebook::react::RCTNativeModule::invoke(unsigned int, folly::dynamic&&, int) + 419 (Optional.h:419)
15 libdispatch.dylib              0x2320 _dispatch_call_block_and_release
16 libdispatch.dylib              0x3eac _dispatch_client_callout
17 libdispatch.dylib              0x126a4 _dispatch_main_queue_drain
18 libdispatch.dylib              0x122f4 _dispatch_main_queue_callback_4CF
19 CoreFoundation                 0x98c28 __CFRUNLOOP_IS_SERVICING_THE_MAIN_DISPATCH_QUEUE__
20 CoreFoundation                 0x7a560 __CFRunLoopRun
21 CoreFoundation                 0x7f3ec CFRunLoopRunSpecific
22 GraphicsServices               0x135c GSEventRunModal
23 UIKitCore                      0x39cf58 -[UIApplication _run]
24 UIKitCore                      0x39cbbc UIApplicationMain
25 GasBuddy                       0xacac main + 8 (main.m:8)
26 ???                            0x1e9778dec (Missing)

And we are at the latest version 16.1.0:

  "@shakebugs/react-native-shake": ^16.1.0
mstanic-shake commented 1 year ago

Hi @zjkuang,

Thank you for a report, we'll take a look at this and update you when we find the cause. It looks like something related to the custom logs.

mstanic-shake commented 9 months ago

It looks like this can happen if wrong data type is sent to Shake.log method. 16.2.1 version converts input to string.

vibinjoby commented 6 months ago

I'm on the latest version of react-native-shake and I still experience a crash on iOS everytime a push notification is received and I tap on the notification "@shakebugs/react-native-shake": "16.2.1", Mine is a fairly new react-native app with 0.73.x version so it should be pretty straightforward to reproduce