The Operation Couldn't Be Completed. (Com.Facebook.Sdk Error 2.) iOS6

com.facebook.sdk error 2 on iOS

Turns out: a com.facebook.sdk error 2 can translate into a number of things. I'm looking for some kind of Facebook SDK error translation table, but I'm unable to find one. In my case:
The com.facebook.sdk error 2 happened because the connection timed out. Users who got this error had a bad network/WiFi connection.

We implemented an error logging system, which logged the error details every time an error happened while logging into Facebook. In those logs we could see a com.facebook.sdk error 2 happening quite a lot, but it being resolved every time the user tried to log in again after a few seconds.

It might be due to my inability to find the right documentation, but I was and still am quite frustrated about the vagueness of these SDK errors. There is a lot of documentation about permission asking (which can result into the com.facebook.sdk error 2), but apparently this error can be caused by more things. It would be nice to see this documented somewhere as well.

The operation couldn’t be completed. (com.facebook.sdk.login error 301.)

I got to know what causes this error. Even though it's funny error, it's good to know about this. The device which I'm running on has no browser to use. So facebook wants to open url in browser and it's failed to do so. That gave me error with facebookSDK.Login.Error.code: 301.

You can resolve this by setting FBSDKLoginManager.loginBehaviour to required behaviour(Browser, Web or App).



Related Topics



Leave a reply



Submit