error code when using GIDSignIn.sharedInstance.clientID =

北战南征 提交于 2019-12-12 12:26:55

问题


I have an app which I used to use Auth2 to sign in using a client Id and client secret but now I have to use Google Sign In

I have followed the instructions as I understand them but when I build I get this error

-[__NSDictionaryI gtm_httpArgumentsString]: unrecognized selector sent to instance 0x17d49a40

I have added the framework I have imported the headers I have made a separate GoogleServices-info.plist with CLIENT_ID and REVERSED_CLIENT_ID

I have put the following code in my ViewDidLoad

GIDSignIn.sharedInstance.delegate = self;
GIDSignIn.sharedInstance.uiDelegate = self;
GIDSignIn.sharedInstance.clientID = @"55240XXXXX13-aduv6ncti03giqt46s3oq4t83plqck10.apps.googleusercontent.com" ;
GIDSignIn.sharedInstance.scopes=@[@"https://www.googleapis.com/auth/plus.login",@"https://www.googleapis.com/auth/plus.me"];

If I comment out the GIDSignIn.sharedInstance.clientID the app builds just fine but when I don't the app crashes with the above error.

I have linked the library -ObjC also.

Does anyone have any ideas as to how to work this out.


回答1:


You should import the following frameworks:

  • AddressBook.framework
  • SafariServices.framework
  • SystemConfiguration.framework
  • libz.tbd



回答2:


I tried all the solutions found on internet but couldn't solve this then I tried manual integration instead of pod and it worked for me.



来源:https://stackoverflow.com/questions/34459504/error-code-when-using-gidsignin-sharedinstance-clientid

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!