-
Notifications
You must be signed in to change notification settings - Fork 363
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
cryptography>=35.0, plus pip>=20.3 - downloads wrong cryptography anywheel package (GLIBC_2.18 error) #1063
Comments
I hit my own issue around the cryptography pacakge, and found that starting in 3.4.8, something happened to the dependency structure that keeps Zappa from properly discovering it when iterating over native dependencies. 3.4.7 gets discovered without issue |
Put in a more proper fix - #1083 . Cryptography moved to a new manylinux format that old Zappa publishing was not compatible with. |
Can this now be closed? |
Hi! Also faced with this problem. It helped me to fix the version for cryptography: cryptography==3.4.8 |
I faced this issue today. Using cryptography==3.4.8 fixed the issue. Is there a better solution as this might lead to dependency conflicts eventually |
This is happening with me also. With |
Hi there! Unfortunately, this Issue has not seen any activity for at least 90 days. If the Issue is still relevant to the latest version of Zappa, please comment within the next 10 days if you wish to keep it open. Otherwise, it will be automatically closed. |
Still encountering this issue in version 42.0.5.
|
For anyone still encountering the same issue with AWS Lambda, I worked around it by upgrading the AWS Lambda Runtime to Python 3.12. This works because the Python 3.12 runtime uses the Amazon Linux 2023 OS (vs Amazon Linux 2 in Python 3.11 and below), and the Amazon Linux 2023 contains newer version of the glibc wheel. If not possible to upgrade to Python 3.12, another solution is also detailed in this issue. |
Looks related to this issue in the cryptography project, suggesting the whole platform wheels are being downloaded.
Downgrading to
cryptography===3.4.8
resolves the issue for now.In my particular case, the code line that triggers the error is:
Stack trace from Lambda CloudWatch logs:
Confirmed both. Running in a docker build step from the official
python:3.7.4
dockerhub image.Your Environment
0.54.0
python:3.7.4
Reproducing
Use this
dockerfile
:(uncomment the applicable deploy/update line)
Build using this docker command:
The deploy/update step will have this line:
#16 15.14 Error: Warning! Status check on the deployed lambda failed. A GET request to '/' yielded a 502 response code.
and the logs cloudwatch logs will have:
[1635434131729] [ERROR] ImportError: /lib64/libc.so.6: version `GLIBC_2.18' not found (required by /var/task/cryptography/hazmat/bindings/_ from cryptography.hazmat.bindings._rust import asn1tric/utils.py", line 6, in <module>
However, if you modify the dockerfile and change pip version to 20.2:
RUN .env/bin/pip install 'pip===20.2 --upgrade
the build and deploy runs fine, and the webapp works fine.
Test matrix:
The text was updated successfully, but these errors were encountered: