Skip to content

Commit

Permalink
Merge pull request #7 from RKrahl/pillow
Browse files Browse the repository at this point in the history
Document and enforce minimal version for Pillow
  • Loading branch information
hydrargyrum committed Sep 5, 2023
2 parents cd17083 + 50d7455 commit 7234c3d
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 2 deletions.
2 changes: 1 addition & 1 deletion README.rst
Original file line number Diff line number Diff line change
Expand Up @@ -101,7 +101,7 @@ Backends are divided in 2 types:

Vignette currently has thumbnail/metadata backends supporting:

* Python Imaging Library (PIL)
* Python Imaging Library (PIL), e.g. `Pillow <https://python-pillow.org/>`_ >= 6.0
* PyQt
* PythonMagick

Expand Down
2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ email = "dev@indigo.re"

[project.optional-dependencies]
pillow = [
"Pillow",
"Pillow>=6.0",
]
pythonmagick = [
"PythonMagick",
Expand Down
3 changes: 3 additions & 0 deletions vignette/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -554,8 +554,11 @@ def is_available(cls):
try:
import PIL.Image
import PIL.PngImagePlugin
import PIL.ImageOps
except ImportError:
return False
if not hasattr(PIL.ImageOps, 'exif_transpose'):
return False

cls.mod = PIL.Image
cls.png = PIL.PngImagePlugin
Expand Down

0 comments on commit 7234c3d

Please sign in to comment.