-
Notifications
You must be signed in to change notification settings - Fork 5.7k
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
Mac: aws-go-mod deploy failed Uploaded file must be a non-empty zip #8772
Comments
Hello @ifanchu, thanks for reporting. Did you first build your |
I have the same issue since yesterday as well. I've spent the evening trying to figure it out thinking it was a problem on my laptop. I've rebooted countless times, removed and installed Serverless again countless times, I've checked my firewall rules in case it was preventing file upload but that was not it. I also checked the uploaded zip into s3, the files were there but were all empty with 0 bytes size.. running I'm actually glad I'm not the only one having this issue. I'm on Mac Os Big Sur running latest everything (node, npm, docker, Brew...)
Serverless Yaml content
|
I'm having the exact same issue today with code that was working perfectly before. I'm working with serverless 2.19.0 but I've also downgraded to 2.18.0 I'm testing with a Python lambda function, even a simple hello world function won't deploy with the following error Uploaded file must be a non-empty zip (Service: AWSLambdaInternal; Status Code: 400; Error Code: InvalidParameterValueException; |
yes I did, and as I mentioned, I tried
Then I tried to unzip it
Looks a little weird to me... |
i'm having the same issue, tested on fresh osx and debian 10 with nodejs helloworld example. got the same error
|
I ran |
Hello everyone - thanks a lot for reporting more details about the issue. I've had a hard time reproducing it, but seeing output from @lxwang42 I've noticed use of the latest version of node The question to everyone reporting - are you all on node Thanks everyone for detailed reports 🙇 |
I was on
I downgraded to
And it is working good now. |
I created a small reproducer repository. See the Github action and the latest output. |
I've tested with Node 15.5 and it is working. It seams to be broken only on 15.6. |
I can also confirm I was running Node v15.6.0 and when I rolled back to Node v14.15.1 all is working fine so it seems to be Node related |
Confirmed working with node@14 |
Thanks everyone for checking out and confirming that it's in fact related to node |
I've had to roll back as well from v15.6.0 and v14.15.1 worked. |
@pgrzesik I can confirm this is working on node I don't know what the timeline for the fix upstream is, it might not be a bad idea to set |
To let everyone know, it has been confirmed to be a Node issue: nodejs/node#37027 |
This is still broken on 15.7.0.. however can confirm it works if downgrading to 14.15.1 |
Confirmed rolling back from node @ 15.6.0 to 14.15.4 fixed the problem for me. |
How can i downgrade the node version? Please... |
@bssilveira91 - that depends on the installation method for Node, one of the options is to use |
@bssilveira91 here hints shared by @sphinxs |
Same issue with node 15, downgrade to node 14 works. |
Hello everyone 👋 The original issue has been resolved and new version of |
How does one make an existing serverless project use this new version? |
Hello @electric-al - the best way is to just do a fresh installation which will install a patched version of |
Hello @sphinxs - I believe it's an obsolete page - also, what do you mean by |
I mean the supported languages and the versions, eg. Node 14, Python 3.9... |
Thanks for the clarification - all languages and versions supported by AWS are supported by Serverless Framework |
node v16 - same issue... "resolutions": {
"crc32-stream": "4.0.2"
} in |
Workaround for serverless/serverless#8772
Node 15.6.0+ has a bug that causes serverless to produce a zipped package with empty files. Deployment succeeds but the Lambda function fails because handler.py is empty. This is supposedly worked around in the latest serverless and its dependencies, but upgrading to serverless v2+ causes other breaking changes. Downgrade to Node 14 for now. serverless/serverless#8772
On my local Mac, I was trying the aws-go-mod template and
sls deploy
failed withserverless.yml
I did not make any change to serverless.yml out of the template.
⚠️⚠️ REPLACE WITH FULL COMMAND NAME
outputInstalled version
I also tried with
sls package
first thensls deploy --package
, also same issue.Am I doing anything wrong with the template?
AWS Setting
The text was updated successfully, but these errors were encountered: