Wayback Machinekoobas.hobune.stream
May JUN Jul
Previous capture 13 Next capture
2021 2022 2023
1 capture
13 Jun 22 - 13 Jun 22
sparklines
Close Help
  • Products
  • Solutions
  • Made with Unity
  • Learning
  • Support & Services
  • Community
  • Asset Store
  • Get Unity

UNITY ACCOUNT

You need a Unity Account to shop in the Online and Asset Stores, participate in the Unity Community and manage your license portfolio. Login Create account
  • Blog
  • Forums
  • Answers
  • Evangelists
  • User Groups
  • Beta Program
  • Advisory Panel

Navigation

  • Home
  • Products
  • Solutions
  • Made with Unity
  • Learning
  • Support & Services
  • Community
    • Blog
    • Forums
    • Answers
    • Evangelists
    • User Groups
    • Beta Program
    • Advisory Panel

Unity account

You need a Unity Account to shop in the Online and Asset Stores, participate in the Unity Community and manage your license portfolio. Login Create account

Language

  • Chinese
  • Spanish
  • Japanese
  • Korean
  • Portuguese
  • Ask a question
  • Spaces
    • Default
    • Help Room
    • META
    • Moderators
    • Topics
    • Questions
    • Users
    • Badges
  • Home /
avatar image
0
Question by sumeeton · Jun 21, 2020 at 03:30 PM · facebooklogin

Facebook SDK - Login Issue on iOS: No Prompt/Login Dialog

I'm using Facebook SDK 7.16.0 and the target iOS version is 13.0. I've created a fb app which is still in development mode, used the fb app id and client token and followed all the steps from the fb guide to set up the login. I tested it in the editor, used the access token and it's working.

Now, when I wanted to test it on the iPad, I created a build. Unfortunately SDK 7.20.0 wasn't working as it had a bug. So, I downgraded to 7.16. No bugs. When I hit the login button, it threw the following error.

-canOpenURL: failed for URL: "fbauth2:/" - error: "The operation couldn’t be completed. (OSStatus error -10814.)"

So, I installed the Facebook App and tried again. The login doesn't bring up the app or safari to login via facebook and instead in the result IsCancelled is true. Why? What am I missing?

 FB.LogInWithReadPermissions(new List<string>() { "public_profile", "email", "user_friends" },
     delegate(ILoginResult result)
     {
         if (result == null)
         {
             Debug.Log("result empty.");
         }
 
         if (!string.IsNullOrEmpty(result.Error))
         {
             Debug.Log("error -" + result.Error);
         }
         else if (result.Cancelled)
         {
             Debug.Log("cancelled");
         }
         else if (!string.IsNullOrEmpty(result.RawResult))
         {
             Debug.Log("success - check result");
         }
     }
 );

Comment
Add comment
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users

1 Reply

· Add your reply
  • Sort: 
avatar image
0

Answer by tfruzza · Aug 26, 2020 at 12:59 AM

I'm running into this same issue with Unity 2019.1.4f1 and Facebook SDK version 7.16.1 which works on Android, but I get the same behavior you're experiencing in iOS. I've seen others with the issue here https://github.com/facebook/facebook-sdk-for-unity/issues/385

Their solution was to upgrade to FB SDK 7.18

I've tried 7.18.0 and 7.18.1 and run into this issue with both: https://github.com/facebook/facebook-sdk-for-unity/issues/350

Switching to the latest available right now is 7.21.2 I didn't realize that I had to open the "xcworkspace" project file vs the "xcodeproj" file I was typically using. I had a new error about something being defined more than once, this was due to my imports of multiple FB SDKs within Unity, doing so left some orphaned files, so after manually removing the SDK in Unity and re-importing the FB SDK package, opening the xcworkspace and building, it worked for me.

This combination is working with Android equally well. I'd like to use a more modern version of Unity, but I had some issues with the latest and some Android builds I was performing.

Comment
Add comment · Share
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users

Your answer

Hint: You can notify a user about this post by typing @username

Up to 2 attachments (including images) can be used with a maximum of 524.3 kB each and 1.0 MB total.

Follow this Question

Answers Answers and Comments

132 People are following this question.

avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image

Related Questions

first steps with facebook developer 0 Answers

Facebook sdk for ios 9 is not opening the app when logging in, Why? 1 Answer

Facebook SDK Login Loads for a long time 0 Answers

400 Bad Request with Unity 2018.3.0b6 & Facebook Login 3 Answers

Firebase anonymous account hanging around after facebook sign in. 0 Answers


Enterprise
Social Q&A

Social
Subscribe on YouTube social-youtube Follow on LinkedIn social-linkedin Follow on Twitter social-twitter Follow on Facebook social-facebook Follow on Instagram social-instagram

Footer

  • Purchase
    • Products
    • Subscription
    • Asset Store
    • Unity Gear
    • Resellers
  • Education
    • Students
    • Educators
    • Certification
    • Learn
    • Center of Excellence
  • Download
    • Unity
    • Beta Program
  • Unity Labs
    • Labs
    • Publications
  • Resources
    • Learn platform
    • Community
    • Documentation
    • Unity QA
    • FAQ
    • Services Status
    • Connect
  • About Unity
    • About Us
    • Blog
    • Events
    • Careers
    • Contact
    • Press
    • Partners
    • Affiliates
    • Security
Copyright © 2020 Unity Technologies
  • Legal
  • Privacy Policy
  • Cookies
  • Do Not Sell My Personal Information
  • Cookies Settings
"Unity", Unity logos, and other Unity trademarks are trademarks or registered trademarks of Unity Technologies or its affiliates in the U.S. and elsewhere (more info here). Other names or brands are trademarks of their respective owners.
  • Anonymous
  • Sign in
  • Create
  • Ask a question
  • Spaces
  • Default
  • Help Room
  • META
  • Moderators
  • Explore
  • Topics
  • Questions
  • Users
  • Badges