question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Improve error messaging when missing "public" directory

See original GitHub issue

After logging in, running firebase deploy fails with the following log:

[debug] ----------------------------------------------------------------------
[debug] Command:      node C:\Users\mckinnonzw\AppData\Roaming\npm\node_modules\firebase-tools\bin\firebase deploy
[debug] Platform:     win32
[debug] Node Version: v0.12.7
[debug] Time:         Wed Dec 16 2015 15:34:56 GMT-0600 (Central Standard Time)
[debug] ----------------------------------------------------------------------
[debug] 
[debug] >>> HTTP REQUEST GET https://admin.firebase.com/firebase/future150/token?token=XXX 
[debug] <<< HTTP RESPONSE 200
[debug] >>> HTTP REQUEST GET https://admin.firebase.com/firebase/future150/token?token=XXX 
[debug] <<< HTTP RESPONSE 200
[info] 
[info] === Deploying to 'future150'...
[info] 
[info] i  deploying 
[debug] >>> HTTP REQUEST POST https://deploy.firebase.com/firebase/future150/releases?token=XXX
[debug] TypeError: Cannot read property 'error' of undefined
    at Request._callback (C:\Users\mckinnonzw\AppData\Roaming\npm\node_modules\firebase-tools\lib\api.js:31:22)
    at Request.self.callback (C:\Users\mckinnonzw\AppData\Roaming\npm\node_modules\firebase-tools\node_modules\request\request.js:198:22)
    at Request.emit (events.js:110:17)
    at Request.<anonymous> (C:\Users\mckinnonzw\AppData\Roaming\npm\node_modules\firebase-tools\node_modules\request\request.js:1035:10)
    at Request.emit (events.js:129:20)
    at IncomingMessage.<anonymous> (C:\Users\mckinnonzw\AppData\Roaming\npm\node_modules\firebase-tools\node_modules\request\request.js:962:12)
    at IncomingMessage.emit (events.js:129:20)
    at _stream_readable.js:908:16
    at process._tickCallback (node.js:355:11)
[error] 
[error] Error: An unexpected error has occurred.

Issue Analytics

  • State:closed
  • Created 8 years ago
  • Comments:11 (2 by maintainers)

github_iconTop GitHub Comments

4reactions
JimmyLvcommented, May 11, 2016

Fixed by add "public": "." 🎯

1reaction
erquhartcommented, May 7, 2016

Yep, this error message is super cryptic.

Read more comments on GitHub >

github_iconTop Results From Across the Web

How to Write Helpful Error Messages to Improve Your App's ...
The current state of error messaging · Failing validation · Server-side failures · Rate limiting · Borked code · Acts of god.
Read more >
Designing Better Error Messages UX - Smashing Magazine
One simple way of doing so is to improve the discovery errors, by never relying on the color of error messages alone.
Read more >
Better error message when missing required fields from request
A simple workaround is to make the Message fields optional and enforce the requirement constraint somewhere in the endpoint handler/method. So ...
Read more >
Error Messages: Examples, Best Practices & Common Mistakes
4 common mistakes with error messages · 1. Ambiguity · 2. Condescending language/blaming the user · 3. Poor placement of error messages ·...
Read more >
failed to mount local volume, no such file or directory ... - GitHub
Description Error response from daemon: error while mounting volume ... Improve error message: failed to mount local volume, no such file or ...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found