Skip to main content

we are also seeing this issue on the latest React native version. 

"react-native": "0.72.4",or     "react-native": "0.71.4",
"@intercom/intercom-react-native": "^5.2.0",

maybe i’m doing some wrong thing, but when login user I got the details about it and do such a code: 

useEffect(() => {
if (user) {
Intercom.setUserHash(user?.uuid).then(() => {
Intercom.loginUserWithUserAttributes({
email: user?.email,
userId: user?.uuid,
languageOverride: 'en',
signedUpAt: Date.now(),
unsubscribedFromEmails: false,
});
});
}
}, >user]);

also tried without setUserHash and only with email and uuid. 

 

this is the stack: 
 

Exception '-cNSNull code]: unrecognized selector sent to instance 0x1bbb347d8' was thrown while invoking loginUserWithUserAttributes on target IntercomModule with params (
{
email = "daria.xxxxx@buildbook.co";
languageOverride = en;
signedUpAt = 1693481234436;
unsubscribedFromEmails = 0;
userId = "xxxx-xxxx-xxxxc4a";
},
688,
689
)
callstack: (
0 CoreFoundation 0x0000000180437330 __exceptionPreprocess + 172
1 libobjc.A.dylib 0x0000000180051274 objc_exception_throw + 56
2 CoreFoundation 0x0000000180445e3c +8NSObject(NSObject) instanceMethodSignatureForSelector:] + 0
3 CoreFoundation 0x000000018043b224 ___forwarding___ + 1308
4 CoreFoundation 0x000000018043d50c _CF_forwarding_prep_0 + 92
5 Staging 0x00000001009258e4 RCTJSErrorFromCodeMessageAndNSError + 736
6 Staging 0x00000001009255c4 RCTJSErrorFromNSError + 236
7 Staging 0x00000001008c80b8 __41-8RCTModuleMethod processMethodSignature]_block_invoke_4.56 + 132
8 Staging 0x0000000100c6bf28 __62-bIntercomModule loginUserWithUserAttributes:success:failure:]_block_invoke_2 + 72
9 Intercom 0x00000001039ea900 IntercomSDK_PINRemoteImageManagerSubclassOverridesSelector + 401424
10 Intercom 0x00000001039bb040 IntercomSDK_PINRemoteImageManagerSubclassOverridesSelector + 206672
11 Intercom 0x00000001039bb270 IntercomSDK_PINRemoteImageManagerSubclassOverridesSelector + 207232
12 Intercom 0x00000001039b5628 IntercomSDK_PINRemoteImageManagerSubclassOverridesSelector + 183608
13 Intercom 0x00000001039ea664 IntercomSDK_PINRemoteImageManagerSubclassOverridesSelector + 400756
14 Intercom 0x00000001039d5f90 IntercomSDK_PINRemoteImageManagerSubclassOverridesSelector + 317088
15 Intercom 0x00000001039d6fe4 IntercomSDK_PINRemoteImageManagerSubclassOverridesSelector + 321268
16 Intercom 0x0000000103803050 Intercom + 28752
17 Staging 0x0000000100c6be04 -0IntercomModule loginUserWithUserAttributes:success:failure:] + 520
18 CoreFoundation 0x000000018043d6c0 __invoking___ + 144
19 CoreFoundation 0x000000018043aa44 -8NSInvocation invoke] + 276
20 CoreFoundation 0x000000018043acdc -8NSInvocation invokeWithTarget:] + 60
21 Staging 0x00000001008ca0b4 -0RCTModuleMethod invokeWithBridge:module:arguments:] + 1796
22 Staging 0x00000001008ce000 _ZN8facebook5reactL11invokeInnerEP9RCTBridgeP13RCTModuleDatajRKN5folly7dynamicEiN12_GLOBAL__N_117SchedulingContextE + 1688
23 Staging 0x00000001008cd79c _ZZN8facebook5react15RCTNativeModule6invokeEjON5folly7dynamicEiENK3$_0clEv + 128
24 Staging 0x00000001008cd710 ___ZN8facebook5react15RCTNativeModule6invokeEjON5folly7dynamicEi_block_invoke + 28
25 libdispatch.dylib 0x0000000180132ee4 _dispatch_call_block_and_release + 24
26 libdispatch.dylib 0x0000000180134708 _dispatch_client_callout + 16
27 libdispatch.dylib 0x0000000180143fd8 _dispatch_main_queue_drain + 1220
28 libdispatch.dylib 0x0000000180143b04 _dispatch_main_queue_callback_4CF + 40
29 CoreFoundation 0x000000018039a784 __CFRUNLOOP_IS_SERVICING_THE_MAIN_DISPATCH_QUEUE__ + 12
30 CoreFoundation 0x0000000180394de4 __CFRunLoopRun + 1912
31 CoreFoundation 0x0000000180394254 CFRunLoopRunSpecific + 584
32 GraphicsServices 0x0000000188eb7c9c GSEventRunModal + 160
33 UIKitCore 0x000000010fe26ff0 -0UIApplication _run] + 868
34 UIKitCore 0x000000010fe2af3c UIApplicationMain + 124
35 Staging 0x00000001003fbd34 main + 100
36 dyld 0x0000000103039514 start_sim + 20
37 ??? 0x00000001030e5f28 0x0 + 4346240808
38 ??? 0x510b800000000000 0x0 + 5839902079304335360
)

RCTFatal
facebook::react::invokeInner(RCTBridge*, RCTModuleData*, unsigned int, folly::dynamic const&, int, (anonymous namespace)::SchedulingContext)
facebook::react::RCTNativeModule::invoke(unsigned int, folly::dynamic&&, int)::$_0::operator()() const
invocation function for block in facebook::react::RCTNativeModule::invoke(unsigned int, folly::dynamic&&, int)
_dispatch_call_block_and_release
_dispatch_client_callout
_dispatch_main_queue_drain
_dispatch_main_queue_callback_4CF
__CFRUNLOOP_IS_SERVICING_THE_MAIN_DISPATCH_QUEUE__
__CFRunLoopRun
CFRunLoopRunSpecific
GSEventRunModal
-dUIApplication _run]
UIApplicationMain
main
start_sim
0x0
0x0

 

Hey there @Konrad Hopek,

Did you say that you’ve tried it with ONLY the email and userId getting sent in? Can you try that again and send the error logs for that? I think you can only send login details in that login call. You would then pass in the other details by making an update call right afterwards.


I had a similar issue caused by the change to Xcode 15. It’s fixed in the latest release https://github.com/intercom/intercom-ios/releases/tag/15.2.1


Reply