Firebase- Deploying Firebase returns error


#1

I am new to the forums here so I will try my best to describe my issue. I am looking to integrate firebase into my app shown here.


I created the firebase.json file from the website tutorial for integrating firebase and when I click on deploy to firebase, I get this error in the log:
Cannot read property ‘load’ of undefined

If anyone could help me with this issue it would be greatly appreciated.


Firebase deploy error
#2

Deploying project to Firebase - that’s the first I’ve found and there is nothing about firebase.json
Well, firebase-tools package is outdated, so update it to a newer version and that could help.


#3

I used the tutorial for glitch that said to implement a firebase.json and click deploy to fire base with easy integration but I will look at doing it that way


#4

Hey @16amattice, welcome to the Glitch Forums!

I’m digging into this right now - I think we may have introduced a bug, and I’m trying to verify it so I can take it to the rest of the team.

@jarvis394 you’re correct that the firebase-tools package is out of date but I don’t think that’s related - that’s for the FIrebase console, I’m pretty sure.

https://glitch.com/help/how-do-i-deploy-my-glitch-project-to-firebase-hosting is the help article that’s been referenced here, I believe.


#5

@cori
Thanks for the reply please let me know what you discover. The original reference link I used was this


Do you think I should just not touch anything until this is looked into?


#6

Well, I don’t think you’ll be able to use the Deploy button until we fix the bug, but I’ve passed it on to the team.


#7

That’s fine @cori can I implement firebase another way?


#8

You can examine this project I made which implements client-side Firebase authentication as well as server-side Firebase admin.


#9

We’ve deployed a fix for this, so the Deploy to Firebase button should be working again.

Let us know if you have further problems. Happy Glitching!


#10

Ok thanks I will take a look once I have a pc available


#11

Alright so I worked on deploying to firebase again and it allowed me to sign in but i can’t access the console or “view firebase app”
And I am receiving this error in the logs

undefined is not an object (evaluating ‘e.length’)


#12

It looks like we still have some bugs to fix - I’ve let the team know.


#13

Thank you please keep me updated :slight_smile:


#15

Hi @16amattice if you open your Firebase console outside of GLitch, can you confirm that your project was actually deployed to Firebase upon using the Deploy button?


#16

@cori it doesn’t deploy to firebase at all with the button from within or externally


#17

I think I’m getting the same error – I was just trying to deploy to firebase from glitch for the first time. When I sign-in to firebase there is no model allowing me to choose which project to deploy to, as the help video said I would see. I then can click “Deploy to Firebase” but it just hangs. If I click “Firebase Console”, nothing happens.


#18

Ok it looks like there’s a breakdown in getting the projects list from Firebase, and we’re looking into it. Sorry for the inconvenience!

In the meantime you can use the Firebase tools from the project console to deploy your project, although it takes a few extra steps. In your console:

  1. run firebase login --no-localhost
    This will present you with a url to visit to get a token you can use to authenticate to Firebase from the CLI
  2. use the provided token to log yourself in, and then run firebase use --add
    this will set up a local alias and let you chose which project to use for your deploy - this is the step that appears to be breaking down in the Glitch Editor.
  3. then run firebase deploy and the CLI tools will push your project up to Firebase.

Please let us know if you have problems with that workflow and we’ll let everyone know here when we’ve sorted out what’s going on with the in-editor tools.


#19

Same thing I am getting


#20

That worked! Thank you!! This integration is seriously so cool :smiley: