Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Token Issue with Firebase

Whenever I run my app (powered by Firebase) in the iOS Simulator, I get multiple warnings printed out in the console:

<FIRInstanceID/WARNING> Error failed to delete all GCM tokens from keychain Error Domain=com.google.iid Code=-34018 "(null)"

<FIRInstanceID/WARNING> Error unable to save iid-token to keychain Error Domain=com.google.iid Code=-34018 "(null)"

<FIRInstanceID/WARNING> Failed to fetch default token Error Domain=com.firebase.iid Code=502 "(null)"

However, if I run the app on a device, I have no issues, and it works as expected. Upon further research, I found that the problem may exist with Firebase Cloud Messaging (FCM). After I found this out, I went to the GoogleService-Info.plist and I set the key IS_GCM_ENABLED to NO. However, this did not solve my issue.

like image 636
Rehaan Advani Avatar asked Oct 18 '22 02:10

Rehaan Advani


1 Answers

I figured out a solution for this issue. It turns out that there is a keychain bug with Xcode 8. To resolve this issue, I enabled my app's KeyChain Sharing in the Capabilities section. I hope this helps anyone with the same issue.

like image 107
Rehaan Advani Avatar answered Nov 04 '22 19:11

Rehaan Advani