Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Firebase Emulators download failed, expected 64907894 bytes but got 64723779 #5734

Closed
markmxr opened this issue Apr 25, 2023 · 17 comments
Closed

Comments

@markmxr
Copy link

markmxr commented Apr 25, 2023

[REQUIRED] Environment info

firebase-tools: 11.29.0

Platform: macOS, Ubuntu

[REQUIRED] Test case

None

[REQUIRED] Steps to reproduce

In a project with Firebase Emulators set up,

  1. npm uninstall firebase-tools
    1 optional) npm uninstall -g firebase-tools
  2. npm install firebase-tools
  3. firebase emulators:start

[REQUIRED] Expected behavior

Firebase Emulators downloads and boots up as normally.

[REQUIRED] Actual behavior

Firebase Emulators appears to download to 100%, but emulators are aborted with the error
Error: download failed, expected 64907894 bytes but got 64723779

@google-oss-bot
Copy link
Contributor

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.

@avilao
Copy link

avilao commented Apr 25, 2023

I have the same issue. Using node v18.16.0

@DavidWeiss2
Copy link

I have the same issue. node 16.19.1

@Lerobindesbois
Copy link

Lerobindesbois commented Apr 25, 2023

same problem :-(

Mac OS : Ventura 13.3.1 M1
Node : v18.16.0
Firebase CLI : 11.29.0

Capture d’écran, le 2023-04-25 à 19 58 32

@rhys-mondo
Copy link

Ran into the same issue with v11.29.0

For now, have reverted back to using my previous version (v11.24.1) which is working again 👍

@endrureza
Copy link

endrureza commented Apr 26, 2023

I have the same problem, here is the debug log

[debug] [2023-04-26T00:56:27.915Z] ----------------------------------------------------------------------
[debug] [2023-04-26T00:56:27.916Z] Command:       /opt/homebrew/Cellar/node@18/18.16.0/bin/node /Users/tabsquare/Library/pnpm/global/5/node_modules/firebase-tools/lib/bin/firebase.js setup:emulators:firestore --debug
[debug] [2023-04-26T00:56:27.917Z] CLI Version:   11.29.0
[debug] [2023-04-26T00:56:27.917Z] Platform:      darwin
[debug] [2023-04-26T00:56:27.917Z] Node Version:  v18.16.0
[debug] [2023-04-26T00:56:27.918Z] Time:          Wed Apr 26 2023 07:56:27 GMT+0700 (Western Indonesia Time)
[debug] [2023-04-26T00:56:27.918Z] ----------------------------------------------------------------------
[debug] 
[info] i  firestore: downloading cloud-firestore-emulator-v1.17.2.jar... {"metadata":{"emulator":{"name":"firestore"},"message":"downloading cloud-firestore-emulator-v1.17.2.jar..."}}
[debug] [2023-04-26T00:56:27.955Z] >>> [apiv2][query] GET https://storage.googleapis.com/firebase-preview-drop/emulator/cloud-firestore-emulator-v1.17.2.jar 
[debug] [2023-04-26T00:56:28.691Z] <<< [apiv2][status] GET https://storage.googleapis.com/firebase-preview-drop/emulator/cloud-firestore-emulator-v1.17.2.jar 200
[debug] [2023-04-26T00:56:28.694Z] <<< [apiv2][body] GET https://storage.googleapis.com/firebase-preview-drop/emulator/cloud-firestore-emulator-v1.17.2.jar [stream]
[error] 
[error] Error: download failed, expected 64907894 bytes but got 64723779

i have no idea why it's happening.

I had to install firebase-tools@11.24.1 to make it firestore and ui work.

@Lerobindesbois
Copy link

hoe do reverse @rhys-mondo your version ?

@tensaebayew
Copy link

i cant figure out the problem

@rhys-mondo
Copy link

hoe do reverse @rhys-mondo your version ?

You need to specify the exact version when installing, in your package.json, or when using firebase-tools

e.g

npm install firebase-tools@11.24.1

or if running in a script with npx

npx firebase-tools@11.24.1 <command>

@Lerobindesbois
Copy link

Merci ! thx you !!!

@mfb-remotesocial
Copy link

Yep... same issue. CLI reports the following:

i  firestore: downloading cloud-firestore-emulator-v1.17.2.jar...
Progress: ===========================> (100% of 65MB
i  emulators: Shutting down emulators.
i  functions: Stopping Functions Emulator
i  firestore: Stopping Firestore Emulator
i  eventarc: Stopping Eventarc Emulator
i  hub: Stopping emulator hub

Error: download failed, expected 64907894 bytes but got 64723779

@KoheiKanagu
Copy link

KoheiKanagu commented Apr 26, 2023

There was no problem using v11.28.0

@pedrofsantoscom
Copy link

Ran into the same issue with v11.29.0

For now, have reverted back to using my previous version (v11.24.1) which is working again 👍

Can confirm that downgrading to the version 11.24.1 works. Thanks

@christhompsongoogle
Copy link
Contributor

Apologies everyone there seems to be an incorrect size and hash in the latest firebase-tools release. We'll release a new version ASAP but for now reverting to 11.28 should resolve the issue.

@colerogers
Copy link
Contributor

colerogers commented Apr 26, 2023

Sorry folks, we found the original version of the firestore binary and re-uploaded it to our backend. Version 11.29.0 should work once you remove the cached jar from your machine, usually found here - ~/.cache/firebase/emulators/cloud-firestore-emulator-v1.17.2.jar. After that, running firebase emulators:start should download the correct one.

Thanks for all of your patience

@sceee
Copy link
Contributor

sceee commented Apr 26, 2023

I can confirm Version 11.29.0 now works again. Thanks @colerogers and @christhompsongoogle .

@christhompsongoogle
Copy link
Contributor

christhompsongoogle commented Apr 26, 2023

11.29.1 fixes the issue without needing to purge the cache - thanks everyone.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests