0

Hello I released an app with the marketingCloud-SDK 5.1.1 in it. I can see crashes in crashlytics about the MarketingCloudSDK.

Do you know the problem and can you tell me in which situation this happens?

Here is the crashlog [__NSDictionaryM setObject:forKey:]: object cannot be nil (key: deviceid)

Fatal Exception: NSInvalidArgumentException 0 CoreFoundation
0x183dd6d8c __exceptionPreprocess 1 libobjc.A.dylib
0x182f905ec objc_exception_throw 2 CoreFoundation
0x183d6f750 _CFArgv 3 CoreFoundation 0x183ca4c6c -[__NSDictionaryM setObject:forKey:] 4 iphone-app 0x10315a654 -[MarketingCloudSDKIntelligence payloadForETAnalyticEntity:] (MarketingCloudSDKIntelligence.m:756) 5 iphone-app 0x1031572f4 __48-[MarketingCloudSDKIntelligence sendETAnalytics]_block_invoke_2 (MarketingCloudSDKIntelligence.m:464) 6 CoreFoundation
0x183db46c4 __NSArrayEnumerate 7 iphone-app
0x10315726c __48-[MarketingCloudSDKIntelligence sendETAnalytics]_block_invoke.356 (MarketingCloudSDKIntelligence.m:469)

1
  • I haven't worked with Objective-C since before anonymous blocks were introduced, but it looks to me like this is an internal error within Marketing Cloud SDK unless -[MarketingCloudSDKIntelligence sendETAnalytics] is invoking a block your code passed it. – David Reed Jul 5 '18 at 16:57
2

This crash occurs occasionally (timing dependent) when the user has done a "swipe to close", thus terminating your app. The timing issue is of the app going to the background just before that happens, the SDK processing analytics, and accessing a resource already released as part of the SDK's teardown.

Our next SDK release (scheduled for very soon) will have guards in place for this situation.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.