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

Validate zip file param validation for AWS Lambda #1296

Merged
merged 8 commits into from
Apr 20, 2015

Conversation

jamesls
Copy link
Member

@jamesls jamesls commented Apr 17, 2015

This improves the error message when the customer does not provide a fileb:// prefix for the zip file argument. Now you get:

# Omitting any file/fileb prefix:
$ aws lambda update-function-code --function-name helloworld --zip-file tests.zip

--zip-file must be a file with the fileb:// prefix.
Example usage:  --zip-file fileb://path/to/file.zip

# Using file:// instead of fileb://

$ aws lambda update-function-code --function-name helloworld --zip-file file://tests.zip

Error parsing parameter '--zip-file': Unable to load paramfile (tests.zip), text contents could not be decoded.  If this is a binary file, please use the fileb:// prefix instead of the file:// prefix.

The same logic is applied to the create-function operation as well.

cc @kyleknap

@coveralls
Copy link

Coverage Status

Coverage increased (+0.04%) to 92.89% when pulling 5dbc95b on jamesls:validate-zip-file into c910c87 on aws:develop.

Otherwise this breaks --generate-cli-skeleton.
@coveralls
Copy link

Coverage Status

Coverage decreased (-0.11%) to 92.75% when pulling 86795d0 on jamesls:validate-zip-file into c910c87 on aws:develop.

@coveralls
Copy link

Coverage Status

Coverage increased (+0.03%) to 92.88% when pulling 86795d0 on jamesls:validate-zip-file into c910c87 on aws:develop.

@kyleknap
Copy link
Contributor

Looks good. 🚢

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

Successfully merging this pull request may close these issues.

3 participants