Repository navigation
Pillow doesn't work in lambda #7591
Answered
by
radarhere
jasonrdunne
asked this question in
Q&A
|
Importing pillow from a lambda layer like so: from PIL import ImageGives this error: |
Answered by
radarhere
Dec 1, 2023
Replies: 1 comment 2 replies
|
Is this helpful? It's some old AWS documentation on how to use Pillow in a lambda - https://web.archive.org/web/20210126181708/https://docs.aws.amazon.com/lambda/latest/dg/with-s3-example-deployment-pkg.html |
2 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment

It is not uncommon for users to come here with installation problems like this. The cause of these problems is that Pillow is not a pure Python library, but contains C code as well. The standard first thing to try is to uninstall Pillow and install it again. That may not apply in your case.
https://stackoverflow.com/questions/57197283/aws-lambda-cannot-import-name-imaging-from-pil also suggests