-
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: packaged SAM 1.98 fails build with ruby 3.2 while development version works correctly #6068
Comments
Thanks for opening this issue! I am able to reproduce this issue on Linux with the following versions of Ruby on both SAM CLI 1.98.0 and the development version:
However was not able to reproduce this using the latest version of everything:
Can you double check that the versions you have are up to date? Additionally, are you able to run |
Packaged
It works correctly using It also works correctly with |
Hi, sorry about the delay in response. Using your provided Docker image, I installed a modified version of SAM CLI (based off the released 1.98.0) that fixes the Ruby error output. Interestingly, it looks like Ruby is not happy about the zlib library version that SAM CLI provides in this environment.
If I remove the library file that is included with the packaged version, it'll pick up the system installed version and build fine. The same happens if I just
Some more work will have to be done to see what we can do about the library we package (if we can remove it, or update or, or potentially something else). In the mean time, we can see about fixing the output caught by the workflow to capture the error message. As a workaround for now when using the packaged version of SAM CLI, using |
Thanks for digging into it! I found it quite weird and was afraid that was something only happening on my setup. I guess we could try to use Do you think the next packaged version will get rid of the problem? |
Hi, I looked into the issue a little bit as well and it appears to be that the zlib library that is coming with the ruby version provided in the image seems to have an issue which is causing the error. I tried replicating the error on my own desktop with the same versions and was unable to, but if i copy the zlib.so library located at There will need to be more work done to determine if this is caused by something unique happening during the ruby install on Ubuntu compared to other OS's or if its due to something else. |
Closing for now as it seems to be a configuration issue rather than a bug within SAM CLI. Feel free to open another issue if you have any other questions |
|
I can't deploy a ruby hello world lambda on arm using sam and GitHub actions. I don't think it's a configuration issue. Using the latest version of SAM cli, and also got version `ZLIB_1.2.9' not found |
@JamesKyburz according this most likely the devs won't notice unless the issue is reopened. In my case I was forced to use |
I've found and read #5530 but I can not reopen it and the closed issues have a COMMENT VISIBILITY WARNING so I've opened a new one
Description:
sam build
installed from https://github.com/aws/aws-sam-cli/releases/latest/download/aws-sam-cli-linux-x86_64.zip fails to build indicatingBundler Failed:
but under the same conditions a development copy ofsam
of the same version works correctly whe I do asamdev build
To add more mystery after
samdev build
works,sam build
starts to work correctly until the.aws-sam
directory is removed.Steps to reproduce:
On a clean ubuntu 22.
sam
following AWS instructions for linuxsamdev
following the development instructionssam build
-> 💥samdev build
-> 👌sam build
-> 👌.aws-sam
sam build
-> 💥I've created a Dockerfile with all the required parts at https://github.com/theist/sam-debug-weird-case
building this container and running it with
docker run -ti /bin/bash
and doingsource /etc/profile.d/rbenv.sh
andcd /lambda
lets you to test the stepsObserved result:
with
samdev
Expected result:
packaged
sam
to work correctly as development version doesAdditional environment details (Ex: Windows, Mac, Amazon Linux etc)
Reproduced originally in debian 11
Reproduced in ubuntu container, with ruby 3.2.2 thru rbenv
sam
installed from https://github.com/aws/aws-sam-cli/releases/latest/download/aws-sam-cli-linux-x86_64.zipsamdev
installed thru sourcecode withvenv
and usingmake init
This might be important as packaged
sam
features a different python version, I guess embedded andsamdev
uses OS pythonsam
:samdev
Thanks!
The text was updated successfully, but these errors were encountered: