Firebase-tools: "Error: Server Error. socket hang up" when deploying but thats not the correct error.

Created on 15 Jul 2017  ·  4Comments  ·  Source: firebase/firebase-tools

When you have some crappy files in your projects public folder, which have e.g. incorrect syntax and you try to deploy this to firebase hosting, the CLI hangs at the step i hosting: preparing build/es6-bundled directory for upload... after some time it says Error: Server Error. socket hang up.
But I think this is not a correct error as when you correct the syntax in your files deploying is working without error.

Why firebase CLI shows this error instead of " errror at file XXX in line XXX " or something similar?

In a big project it would be great to know where to look for the error in the code!

Most helpful comment

Also had this issue. Discovered it was Kaspersky Internet Security that was blocking api callbacks. Turn off protection during deploy or whitelist the google domains.

All 4 comments

Is this still an issue? Can you provide specific examples of files that cause this problem?

Just because this is the number 1 result on Google for this error:
I had issues with this when deploying while using a VPN like tunnelbear. Try disabling that and see if it helps.

I have also tried deleted my cloud functions from google cloud console before trying to deploy again, which has helped in other similarly weird circumstances.
https://console.cloud.google.com/functions/list?project=

Also had this issue. Discovered it was Kaspersky Internet Security that was blocking api callbacks. Turn off protection during deploy or whitelist the google domains.

Algo VPN also causes this problem, and disabling it temporarily fixes it in my case.

Was this page helpful?
0 / 5 - 0 ratings