firebase-tools: I Can't Deploy Using firebase deploy

Version info

Firebase Version: 3.17.4

Platform Information

OS X and Linux

Steps to reproduce

What I did was create a CI token using the firebase cli by doing firebase login:ci

Now I can’t deploy without a token, even though I’ve logged out and logged back in multiple times, I have also tried going to https://myaccount.google.com/permissions and removed permission then logged in again.

Expected behavior

When I run firebase deploy for my functions I should be able to deploy them.

Actual behavior

firebase deploy --only functions
Error: An unexpected error has occurred.

[debug] [2018-03-07T07:26:18.988Z] Error: Firebase.authWithCustomToken failed: First argument must be a valid credential (a string).
    at ng (/usr/local/lib/node_modules/firebase-tools/node_modules/firebase/lib/firebase-node.js:129:313)
    at X.gg (/usr/local/lib/node_modules/firebase-tools/node_modules/firebase/lib/firebase-node.js:266:131)
    at /usr/local/lib/node_modules/firebase-tools/lib/acquireRefs.js:19:19
    at initializePromise (/usr/local/lib/node_modules/firebase-tools/node_modules/rsvp/dist/rsvp.js:567:5)
    at new Promise (/usr/local/lib/node_modules/firebase-tools/node_modules/rsvp/dist/rsvp.js:1039:33)
    at /usr/local/lib/node_modules/firebase-tools/lib/acquireRefs.js:12:12
    at tryCatch (/usr/local/lib/node_modules/firebase-tools/node_modules/rsvp/dist/rsvp.js:525:12)
    at invokeCallback (/usr/local/lib/node_modules/firebase-tools/node_modules/rsvp/dist/rsvp.js:538:13)
    at publish (/usr/local/lib/node_modules/firebase-tools/node_modules/rsvp/dist/rsvp.js:508:7)
    at flush (/usr/local/lib/node_modules/firebase-tools/node_modules/rsvp/dist/rsvp.js:2415:5)
[error] 
[error] Error: An unexpected error has occurred.

About this issue

  • Original URL
  • State: closed
  • Created 6 years ago
  • Reactions: 1
  • Comments: 22 (3 by maintainers)

Most upvoted comments

Just had the same issue but a firebase login --reauth made it start working again for me

There was an issue deploying your functions. Verify that your project has a Google App Engine instance setup at https://console.cloud.google.com/appengine and try again. If this issue persists, please contact support.

Error: HTTP Error: 404, Could not find Application “fir-friendlychat-6292b”. Pls help guys

I am getting a 410 in response to uploading the project public directory

[2019-03-04T18:46:08.016Z] <<< HTTP RESPONSE 410 server=nginx, date=Mon, 04 Mar 2019 18:46:07 GMT, content-type=application/json; charset=utf-8, content-length=240, connection=close, access-control-allow-origin=*, access-control-allow-methods=GET, PUT, POST, DELETE, OPTIONS, strict-transport-security=max-age=31556926; includeSubDomains; preload
[2019-03-04T18:46:08.017Z] <<< HTTP RESPONSE BODY undefined
[2019-03-04T18:46:08.019Z] TypeError: Cannot read property 'error' of undefined
    at module.exports (/Users/user/Repos/stlvl/node_modules/firebase-tools/lib/responseToError.js:10:13)
    at Request._callback (/Users/user/Repos/stlvl/node_modules/firebase-tools/lib/api.js:47:25)
    at Request.self.callback (/Users/user/Repos/stlvl/node_modules/request/request.js:185:22)
    at Request.emit (events.js:197:13)
    at Request.EventEmitter.emit (domain.js:446:20)
    at Request.<anonymous> (/Users/user/Repos/stlvl/node_modules/request/request.js:1157:10)
    at Request.emit (events.js:197:13)
    at Request.EventEmitter.emit (domain.js:446:20)
    at IncomingMessage.<anonymous> (/Users/user/Repos/stlvl/node_modules/request/request.js:1079:12)
    at Object.onceWrapper (events.js:285:13)

Error: An unexpected error has occurred.

The issue should be resolved as of a couple of hours ago. Sorry for the inconvenience, folks.