Open JuliusKumar opened 4 years ago
This issue does not have all the information required by the template. Looks like you forgot to fill out some sections. Please update the issue with more information.
I've logged in multiple times but looks like the CLI is unable to connect to the firebase console to retrieve details
@JuliusKumar when filing issues please fill out the issue template otherwise we won't be able to debug. For instance we really need to see what the error in the debug logs is here.
If you're having trouble connecting it may be due to a Firewall or VPN that you are using on your machine?
I have updated the issue with the debug log
@JuliusKumar this line means that somewhere you have the FIREBASE_TOKEN
environment variable set:
> authorizing via FIREBASE_TOKEN environment variable
So that overrides the credential from firebase login
. You should find out where you have that variable set and undo it,
Hi Sam, I've checked and removed FIREBASE_TOKEN variable and I still get error. I also tried reauthorizing it confirms that I am logged in. But the debug log says that "Authorization Error"
<------
C:\Users\kumarja\workspace\GCP\firebase\functions>set FIREBASE_TOKEN
Environment variable FIREBASE_TOKEN not defined
C:\Users\kumarja\workspace\GCP\firebase\functions>firebase login
Already logged in as juliuskumar.email@gmail.com
C:\Users\kumarja\workspace\GCP\firebase\functions>firebase projects:list
× Preparing the list of your Firebase projects
Error: Failed to list Firebase projects. See firebase-debug.log for more info.
----------->
<--------DEBUG LOG ------------------------>
[debug] [2020-08-03T15:24:59.618Z] Command: C:\Program Files\nodejs\node.exe C:\Users\kumarja\AppData\Roaming\npm\node_modules\firebase-tools\lib\bin\firebase.js projects:list
[debug] [2020-08-03T15:24:59.619Z] CLI Version: 8.6.0
[debug] [2020-08-03T15:24:59.620Z] Platform: win32
[debug] [2020-08-03T15:24:59.620Z] Node Version: v10.15.3
[debug] [2020-08-03T15:24:59.623Z] Time: Mon Aug 03 2020 08:24:59 GMT-0700 (Pacific Daylight Time)
[debug] [2020-08-03T15:24:59.623Z] ----------------------------------------------------------------------
[debug] [2020-08-03T15:24:59.624Z]
[debug] [2020-08-03T15:24:59.649Z] > command requires scopes: ["email","openid","https://www.googleapis.com/auth/cloudplatformprojects.readonly","https://www.googleapis.com/auth/firebase","https://www.googleapis.com/auth/cloud-platform"]
[debug] [2020-08-03T15:24:59.650Z] > authorizing via signed-in user
[debug] [2020-08-03T15:24:59.664Z] > refreshing access token with scopes: ["email","https://www.googleapis.com/auth/cloud-platform","https://www.googleapis.com/auth/cloudplatformprojects.readonly","https://www.googleapis.com/auth/firebase","openid"]
[debug] [2020-08-03T15:24:59.665Z] >>> HTTP REQUEST POST https://www.googleapis.com/oauth2/v3/token
<request body omitted>
[debug] [2020-08-03T15:24:59.824Z] Authentication Error: Your credentials are no longer valid. Please run firebase login --reauth
<---------------------------------------------------------->
@JuliusKumar thanks for the extra logs. Have you tried running firebase logout
and then running firebase login
again?
Hey @JuliusKumar. We need more information to resolve this issue but there hasn't been an update in 7 weekdays. I'm marking the issue as stale and if there are no new updates in the next 3 days I will close it automatically.
If you have more information that will help us get to the bottom of this, just add a comment!
I've tried to logout and re-login many times. it does not work. Keeps giving me credentials error. Something seems to be missing in the oauth set up.
[debug] [2020-08-13T01:42:23.263Z] > refreshing access token with scopes: ["email","https://www.googleapis.com/auth/cloud-platform","https://www.googleapis.com/auth/cloudplatformprojects.readonly","https://www.googleapis.com/auth/firebase","openid"]
[debug] [2020-08-13T01:42:23.263Z] >>> HTTP REQUEST POST https://www.googleapis.com/oauth2/v3/token
[debug] [2020-08-13T01:42:23.397Z] Authentication Error: Your credentials are no longer valid. Please run firebase login --reauth
Additionally, I noticed that if I don't work on the firebase CLI commands for 1 day, the next day having to re-login, I can run the command "firebase projects:list" and it lists my projects. It works a few times and starts throwing error as before.
One of the error messages I've seen is - "Error: Server Error. self signed certificate in certificate chain"
@JuliusKumar sorry for the very late response but I think I may know what's going on here. Is it possible you or someone you work with is using Google Cloud session duration controls: https://support.google.com/a/answer/9368756?hl=en
Basically these are controls that mean your firebase login
credentials would expire on some regular interval, but the Firebase CLI wouldn't be aware of this.
Hello, such a thing is happening to me now. I wanna help someone with this.
is there anything way to solve this problem?
from stackoverflow answer https://stackoverflow.com/questions/44471670/firebase-init-command-failing-to-execute/62071359
Happen to me today on the firebase-tools v13.13.3. When I tried to run firebase logout
first, the error still the same, as it always telling to login
with --reauth
. So when this issue happen in my case login
, logout
, and projects:list
commands are not working.
The workaround is to use gcloud auth login
first, then the firebase logout
will be usable again, then I can run firebase login
successfully. Hope this helps.
[REQUIRED] Environment info
firebase --version = 8.6.0
firebase-tools:
Platform: Windows 10
[REQUIRED] Test case
[REQUIRED] Steps to reproduce
Listed below are the commands and responses firebase login Already logged in as juliuskumar firebase projects:list × Preparing the list of your Firebase projects Error: Failed to list Firebase projects. See firebase-debug.log for more info.
[REQUIRED] Expected behavior
firebase projects:list - should connect to firebase account and list my projects
[REQUIRED] Actual behavior
Listed below are the commands and responses
firebase projects:list × Preparing the list of your Firebase projects Error: Failed to list Firebase projects. See firebase-debug.log for more info.