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 is crashing with issue [FBSDKBasicUtility _convertObjectToJSONObject:invalidObjectHandler:stop:] #2289

Open
5 tasks done
nalint2s opened this issue Oct 20, 2023 · 0 comments

Comments

@nalint2s
Copy link

Checklist before submitting a bug report

Xcode version

14.2

Facebook iOS SDK version

16.1.3

Dependency Manager

CocoaPods

SDK Framework

Login

Goals

I am trying to update my apps and after I release to test flight it is crashing. Debugging the crash log and this is what I have found

Also find screenshot for reference
Screenshot 2023-10-20 at 6 47 04 PM

Video issue

Untitled.mov

Expected results

It should not crash when initialising Facebook SDK. If I remove below line from AppDelegate.m, it works fine.

[[FBSDKApplicationDelegate sharedInstance] application:application
didFinishLaunchingWithOptions:launchOptions];

But then, I have to remove Facebook login from my app.

Actual results

Currently app is crashing with below crash log, this crash is happening at initial launch as shown in video.

FBSDKCoreKit_Basics
+[FBSDKBasicUtility _convertObjectToJSONObject:invalidObjectHandler:stop:] FBSDKBasicUtility.m:128
FBSDKCoreKit_Basics
+[FBSDKBasicUtility _convertObjectToJSONObject:invalidObjectHandler:stop:] FBSDKBasicUtility.m:120
FBSDKCoreKit_Basics
+[FBSDKBasicUtility JSONStringForObject:error:invalidObjectHandler:] FBSDKBasicUtility.m:59
FBSDKCoreKit
-[FBSDKAppEventsUtility activityParametersDictionaryForEvent:shouldAccessAdvertisingID:userID:userData:] FBSDKAppEventsUtility.m:127
FBSDKCoreKit
-[FBSDKAppEvents publishInstall] FBSDKAppEvents.m:866
FBSDKCoreKit
-[FBSDKAppEvents fetchServerConfiguration:] FBSDKAppEvents.m:1023
FBSDKCoreKit
-[FBSDKServerConfigurationManager _didProcessConfigurationFromNetwork:appID:error:] FBSDKServerConfigurationManager.m:387
FBSDKCoreKit
-[FBSDKServerConfigurationManager processLoadRequestResponse:error:appID:] FBSDKServerConfigurationManager.m:281
FBSDKCoreKit
-[FBSDKGraphRequestPiggybackManager addServerConfigurationPiggyback:] FBSDKGraphRequestPiggybackManager.m:178
FBSDKCoreKit
-[FBSDKGraphRequestMetadata invokeCompletionHandlerForConnection:withResults:error:] FBSDKGraphRequestMetadata.m:32
FBSDKCoreKit
-[FBSDKGraphRequestConnection processResultBody:error:metadata:canNotifyDelegate:] FBSDKGraphRequestConnection.m:998
FBSDKCoreKit
-[FBSDKGraphRequestConnection processResultBody:error:metadata:canNotifyDelegate:] FBSDKGraphRequestConnection.m:1032
FBSDKCoreKit
-[FBSDKGraphRequestConnection _completeWithResults:networkError:] FBSDKGraphRequestConnection.m:981
CoreFoundation
NSARRAY_IS_CALLING_OUT_TO_A_BLOCK

Steps to reproduce

We have an existing Facebook developer id that is causing this issue. We are not sure if this will happen for new developers who are going to integrate Facebook in their app. We are using Objective-c file for App Delegate.

Code samples & details

// INSERT YOUR CODE HERE
var example = "Example code"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant