Open tbaggett opened 6 years ago
Have you resolved this? Perhaps try adding the google_sign_in and firebase_auth packages back in, as they're dependencies?
I had the same problem and I solved it by setting up Facebook correctly - adding fb app id into manifest. Whats interesting - this happened even if I removed facebook provider type. I use visual code for development and I was not able to see error - running my app in android studio helped me.
maybe you should update your readme, to redirect to the one of the "flutter_facebook_login" dependency. this library indeed issues the problem that it will crash if no Facebook information is provided in the app, and gives the instructions to setup Facebook's API keys.
What would be perfect is to make the dependency optional for users that don't want to integrate the facebook provider, and even better would be some error handling from "flutter_facebook_login" (which is not the place to issue this)
I think you can work around this by adding a fake facebook app id:
<meta-data android:name="com.facebook.sdk.ApplicationId"
android:value="@string/facebook_app_id"/>
<string name="facebook_app_id">00000000000</string>
Thanks, @davidair . That works for now. The file should look like this:
<?xml version="1.0" encoding="utf-8"?>
<resources>
<string name="facebook_app_id">00000000</string>
</resources>
If you add the string directly, you'll get an error that it can't be found. Probably obvious if you work with Android a lot, but it took my a while to figure that out.
Hi, thanks for sharing your plugin. I'm having difficulty getting it to work. My app immediately stops working on my Android device when I launch it. However, I was able to download, build and launch your example app on the same Android device without any problems.
I am new to Flutter, so I'm probably doing something wrong. I tried for a couple of hours to get your plugin to work in my app without success, so any suggestions are greatly appreciated.
I was already using the firebase_auth plugin and was able to log in using Google with their example code copied into my main.dart file. This leads me to think I have FireBase Auth set up in my app correctly.
I removed the firebase_auth and google_sign_in dependencies and added a dependency for your plugin in my pubspec.yaml file, and copied your example code into my main.dart file.
Before:
After:
The only difference I've found is in my google-services.json file. My oauth_client section looks like this (note the client_type value of 1 and android_info subsection):
In your example app's google-services.json file, your oauth_client section has a client_type value of 3 and is missing the android_info:
Do you know if the different client type value is causing my issue? Any suggestions on how to fix this? Thanks again.