Skip to content

Commit

Permalink
Add optional dependencies for pillow/wand (#130)
Browse files Browse the repository at this point in the history
  • Loading branch information
zerolab authored Oct 22, 2023
1 parent 2cf3f31 commit 16169e5
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 5 deletions.
11 changes: 10 additions & 1 deletion docs/installation.rst
Original file line number Diff line number Diff line change
Expand Up @@ -15,11 +15,20 @@ Installing underlying libraries
-------------------------------

In order for most features of Willow to work, you need to install either Pillow
or Wand.
or Wand. You can follow the installation instructions for each of them:

- `Pillow installation <https://pillow.readthedocs.io/en/stable/installation.html#basic-installation>`_
- `Wand installation <https://docs.wand-py.org/en/stable/guide/install.html>`_

or you can install them together with Willow when using ``pip``:

.. code-block:: shell
pip install Willow[Pillow]
# or
pip install Willow[Wand]
Note that Pillow doesn't support animated GIFs and Wand isn't as fast.
Installing both will give best results.

Expand Down
8 changes: 4 additions & 4 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -31,15 +31,15 @@ dependencies = [
]

[project.optional-dependencies]
pillow = ["Pillow>=9.1.0,<11.0.0"]
wand = ["Wand>=0.6,<1.0"]
heif = [
"pillow-heif>=0.10.0,<1.0.0; python_version < '3.12'",
"pillow-heif>=0.13.0,<1.0.0; python_version >= '3.12'",
]

testing = [
"Pillow>=9.1.0,<11.0.0",
"Wand>=0.6,<1.0",
"mock>=3.0,<4.0",
"pillow-heif>=0.10.0,<1.0.0",
"willow[pillow,wand,heif]",
"black==22.3.0",
"ruff==0.0.275",
"coverage[toml]>=7.2.7,<8.0",
Expand Down

0 comments on commit 16169e5

Please sign in to comment.