-
Notifications
You must be signed in to change notification settings - Fork 1.2k
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
Bug: sam build
doesn't return an error when it should
#5026
Comments
@aidansteele Thanks for reporting both to us and Docker. We do need to upgrade Docker regardless (we are too far out of date). |
As @jfuss recommended, I've tried to update What I've found is that, when we call There are two options for fixing this issue;
I will be discussing this with the team about which approach would be better. |
Hi! 👋 I also encountered the same issue, I'm just sharing here my setup if it helps validate that the error is part of the Reproduction steps
|
Patch is released in v1.91.0. Closing |
Description:
I am trying to build and deploy an image-based Lambda function using the SAM CLI.
sam build
succeeds even when the image failed to build, which causes a lot of confusion.I think the cause is the underlying docker-py library not raising an exception when it should. I filed an issue in that repo too: docker/docker-py#3108. The code in question hasn't changed between 4.2.0 (which SAM uses) and the head of that repo.
Steps to reproduce:
Have the following template:
Make sure there is an
example
directory without aDockerfile
inside it. Now runsam build
. This should fail. It fails (as expected) on Linux, but it succeeds on MacOS.Observed result:
Expected result:
I expect the build to fail, like it does on Linux.
Additional environment details (Ex: Windows, Mac, Amazon Linux etc)
The text was updated successfully, but these errors were encountered: