aws-samples / amazon-chime-react-native-demo

A React Native demo application for Android and iOS using the Amazon Chime SDK.
MIT No Attribution
102 stars 24 forks source link

[native] Exception '-[NSNull _fastCStringContents:]: unrecognized selector sent to instance 0x205dc8920' was thrown while invoking startMeeting on target NativeMobileSDKBridge #193

Closed addingama closed 1 year ago

addingama commented 1 year ago

Describe the bug I started a new react native project with RN 0.71.12 and follows all the sample and adjust the UI to only have 2 user, 1 local and 1 remote. When the meeting tried to start, the app keep crashing.

To Reproduce Steps to reproduce the behavior:

  1. call startMeeting on the RN project

Expected behavior Meeting should start properly because the same code is working on android

Logs

Printing description of mediaPlacement:
<AmazonChimeSDK.MediaPlacement: 0x28b86a100>
2023-07-30 22:22:31.712680+0800 LifeMappBeta[47098:19029152] -[NSNull _fastCStringContents:]: unrecognized selector sent to instance 0x205dc8920
2023-07-30 22:22:31.745464+0800 LifeMappBeta[47098:19029152] [native] Exception '-[NSNull _fastCStringContents:]: unrecognized selector sent to instance 0x205dc8920' was thrown while invoking startMeeting on target NativeMobileSDKBridge with params (
        {
        ExternalMeetingId = "<null>";
        MediaPlacement =         {
            AudioFallbackUrl = "wss://haxrp.m1.ue1.app.chime.aws:443/calls/f55ef2c7-e6c4-4d0a-bff8-b09fa64f0706";
            AudioHostUrl = "fa16a43f97b87540a9c94cc583a68ad6.k.m1.ue1.app.chime.aws:3478";
            ScreenDataUrl = "wss://bitpw.m1.ue1.app.chime.aws:443/v2/screen/f55ef2c7-e6c4-4d0a-bff8-b09fa64f0706";
            ScreenSharingUrl = "wss://bitpw.m1.ue1.app.chime.aws:443/v2/screen/f55ef2c7-e6c4-4d0a-bff8-b09fa64f0706";
            ScreenViewingUrl = "wss://bitpw.m1.ue1.app.chime.aws:443/ws/connect?passcode=null&viewer_uuid=null&X-BitHub-Call-Id=f55ef2c7-e6c4-4d0a-bff8-b09fa64f0706";
            SignalingUrl = "wss://signal.m1.ue1.app.chime.aws/control/f55ef2c7-e6c4-4d0a-bff8-b09fa64f0706";
            TurnControlUrl = "https://ccp.cp.ue1.app.chime.aws/v2/turn_sessions";
        };
        MediaRegion = "us-east-1";
        MeetingId = "f55ef2c7-e6c4-4d0a-bff8-b09fa64f0706";
    },
        {
        AttendeeId = "a8634328-0023-c8ef-aa3c-96e928cee85c";
        ExternalUserId = 880899836098969601;
        JoinToken = YTg2MzQzMjgtMDAyMy1jOGVmLWFhM2MtOTZlOTI4Y2VlODVjOjJlOGIyOWYyLTFlYWUtNDljOC04NjBiLWNiZmM2ZDBlYWUwZg;
    }
)
callstack: (
    0   CoreFoundation                      0x00000001ae365e94 5CDC5D9A-E506-3740-B64E-BB30867B4F1B + 40596
    1   libobjc.A.dylib                     0x00000001a769b8d8 objc_exception_throw + 60
    2   CoreFoundation                      0x00000001ae4da84c 5CDC5D9A-E506-3740-B64E-BB30867B4F1B + 1566796
    3   CoreFoundation                      0x00000001ae37bfa0 5CDC5D9A-E506-3740-B64E-BB30867B4F1B + 130976
    4   CoreFoundation                      0x00000001ae3e4350 _CF_forwarding_prep_0 + 96
    5   libswiftCore.dylib                  0x00000001a83b9194 F896D145-E025-39D6-AFD3-BC0A2AD4F839 + 2163092
    6   libswiftCore.dylib                  0x00000001a83b9348 $ss18_bridgeCocoaStringys01_C4GutsVyXlF + 152
    7   libswiftCore.dylib                  0x00000001a83b9570 $sSS12_cocoaStringSSyXl_tcfC + 28
    8   Foundation                          0x00000001a89de390 $sSS10FoundationE36_unconditionallyBridgeFromObjectiveCySSSo8NSStringCSgFZ + 172
    9   AmazonChimeSDK                      0x00000001049a2584 block_destroy_helper + 1216
    10  LifeMappBeta                        0x00000001006e1c7c -[NativeMobileSDKBridge startMeeting:attendeeInfo:] + 880
    11  CoreFoundation                      0x00000001ae3d0704 5CDC5D9A-E506-3740-B64E-BB30867B4F1B + 476932
    12  CoreFoundation                      0x00000001ae37cb6c 5CDC5D9A-E506-3740-B64E-BB30867B4F1B + 133996
    13  CoreFoundation                      0x00000001ae37c584 5CDC5D9A-E506-3740-B64E-BB30867B4F1B + 132484
    14  LifeMappBeta                        0x0000000100be2c54 -[RCTModuleMethod invokeWithBridge:module:arguments:] + 1808
    15  LifeMappBeta                        0x0000000100be6b54 _ZN8facebook5reactL11invokeInnerEP9RCTBridgeP13RCTModuleDatajRKN5folly7dynamicEiN12_GLOBAL__N_117SchedulingContextE + 1596
    16  LifeMappBeta                        0x0000000100be634c _ZZN8facebook5react15RCTNativeModule6invokeEjON5folly7dynamicEiENK3$_0clEv + 128
    17  LifeMappBeta                        0x0000000100be62c0 ___ZN8facebook5react15RCTNativeModule6invokeEjON5folly7dynamicEi_block_invoke + 28
    18  libdispatch.dylib                   0x00000001043005a8 _dispatch_call_block_and_release + 32
    19  libdispatch.dylib                   0x000000010430205c _dispatch_client_callout + 20
    20  libdispatch.dylib                   0x000000010430a10c _dispatch_lane_serial_drain + 988
    21  libdispatch.dylib                   0x000000010430ae34 _dispatch_lane_invoke + 420
    22  libdispatch.dylib                   0x0000000104317cbc _dispatch_workloop_worker_thread + 740
    23  libsystem_pthread.dylib             0x00000001fb3bbdf8 _pthread_wqthread + 288
    24  libsystem_pthread.dylib             0x00000001fb3bbb98 start_wqthread + 8

Screenshots image

Test environment Info (please complete the following information):

addingama commented 1 year ago

Nevermind, the issue was ExternalMeetingId is null, once I set the ExternalMeetingId, no more crash