Getting errors trying to add Firebase project from

2020-04-06 03:45发布

问题:

I want to add Firebase to my project via Android Studio by going to Tools > Firebase > authentication > Email and Password Authentication > Connect to Firebase. A dialog pops up, I choose create new Firebase Project and I get the following error, even though I have a fully working internet connection:

Firebase: Connect to Firebase failed. Please check your internet connection and try again. If errors persist, you can connect manually at https://console.firebase.google.com Project creation was attempted so an online project may exist online and registered to your account despite this failure message.

It's much easier setting it up this way rather than doing it manually, so I would like to solve the issue.

EDIT:

The problem turned out to be that I had reached the limit for adding new projects. To solve this issue, you have to delete some apps, link the new project to an existing one, or request for additional projects creation from the Firebase team.

回答1:

  1. Go to https://console.firebase.google.com
  2. Login to your account
  3. Create a new project as per your requirements
  4. Follow this guide: https://firebase.google.com/docs/android/setup


回答2:

It's simple.

You all have to just Sign-out and then Sign-in again.

Problem fixed for me at least. You can try it.



回答3:

go to android studio -> settings -> Appearance & Behaviour -> System Settings

  1. Check Auto Detect Proxy Setting. (Select the option)
  2. check Connection with error website

    For Ex. https://console.firebase.google.com

Apply Changes. and try again without Restarting or with restarting your android studio



回答4:

You should check other plugins. In my case the first lines in application build.gradle are:

apply plugin: 'com.android.application'
apply plugin: 'io.fabric'
... 

I have missed the second line and after adding it, the same issue was resolved for me.