Facebook iOS SDK login not functioning - NSExcepti

2019-09-06 19:23发布

问题:

Followed numerous Facebook iOS SDK login guides including:

  • https://developers.facebook.com/docs/facebook-login/ios/v2.3
  • http://www.brianjcoleman.com/tutorial-how-to-use-login-in-facebook-sdk-4-0-for-swift/

With accurate implementations of the Facebook and other guides the same problem is still occurring. When running the application the Log in button is clicked and then an NSException occurs at the start of the AppDelegate class (Error: "libc++abi.dylib: terminating with uncaught exception of type NSException"). The button as a result does nothing, and does not open another window to the Facebook login page. The simulator can use the internet and also the code and Info.plist has all the right data and code.

Does the Facebook app have to be live to the public be logged into from the app? The app online is in developer mode.

回答1:

Apparently, the problem was that the Facebook App ID was not found. Looking at the stack trace was revealing the problem, which was subsequently fixed.