zipapp fails to import _imaging from PIL #9326
-
|
After I introduced the Pillow dependency to my project, the zipapp-produced executable no longer executes properly. I get an
from PIL import Image, UnidentifiedImageErrorBelow is the shell script used to generate the zipapp. It is meant to be executed from the project root (where mkdir ./zipapp
echo 'Installing requirements'
pipenv run pip freeze --exclude-editable \
| pipenv run pip install --requirement /dev/stdin --target ./zipapp
echo 'Installing BasketCase'
pipenv run pip install . --target ./zipapp --upgrade
echo 'Generating zipapp'
python3 -m zipapp ./zipapp \
--main="basketcase.__main__:main" \
--python="/usr/bin/env python3" \
--output=./dist/basketcase --compress
rm -r ./zipappIn its output (last line) I see: I get the |
Beta Was this translation helpful? Give feedback.
Replies: 2 comments
-
|
I just noticed there's a strange lone dot in that file path ( Maybe that's why it's failing, but I can't see where it comes from. |
Beta Was this translation helpful? Give feedback.
-
|
The reason was explained in the Caveats section of the docs. Sorry, I missed it.
I see that Pillow contains a lot of C files. |
Beta Was this translation helpful? Give feedback.
The reason was explained in the Caveats section of the docs. Sorry, I missed it.
I see that Pillow contains a lot of C files.