Skip to content
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

Replace requirements.txt with extras #6072

Merged
merged 14 commits into from Feb 27, 2022
Merged

Conversation

hugovk
Copy link
Member

@hugovk hugovk commented Feb 19, 2022

Using extras_require means we can install just those requirements needed for a given task at the same time as installing Pillow, rather using a separate command that installs the whole bunch.

For example, to install things needed for testing:

pip install .[tests]

# Or my Mac terminal needs quotes
pip install ".[tests]"

Or for building docs:

pip install .[docs]

# Or my Mac terminal needs quotes
pip install ".[docs]"

This also removes two non-existent commands from the make help, and adds some capitalisation.


Whilst editing Makefile I noticed install-venv is deprecated but not in the deprecations docs:

	@echo "  install-venv       (deprecated) install in virtualenv"

...

.PHONY: install-venv
install-venv:
	echo "'install-venv' is deprecated and will be removed in a future Pillow release"
	virtualenv .

Deprecated in #5171 / #5159 / Pillow 8.1.0 / 2 Jan 2021, so strictly speaking would have been eligible for removal in 9.0.0 / Jan 2022.

But this is arguably a dev helper rather than a formal API. Shall we wait for Pillow 10 (and add it to the deprecations docs?), or is it safe to remove it now?

@hugovk hugovk added the Installation Usually a problem with … label Feb 19, 2022
setup.cfg Show resolved Hide resolved
@radarhere
Copy link
Member

Whilst editing Makefile I noticed install-venv is deprecated but not in the deprecations docs:

	@echo "  install-venv       (deprecated) install in virtualenv"

...

.PHONY: install-venv
install-venv:
	echo "'install-venv' is deprecated and will be removed in a future Pillow release"
	virtualenv .

Deprecated in #5171 / #5159 / Pillow 8.1.0 / 2 Jan 2021, so strictly speaking would have been eligible for removal in 9.0.0 / Jan 2022.

But this is arguably a dev helper rather than a formal API. Shall we wait for Pillow 10 (and add it to the deprecations docs?), or is it safe to remove it now?

You've suggested before that the Makefile is a lower priority, so I don't mind. See hugovk#81

I think the bigger change is removing install-req without deprecation - but I can imagine an argument that changes to how you compile Pillow are easier to adapt to than changes in the core API, and that if you're compiling Pillow yourself, there is a measure of acceptance that this might not be a completely stable experience.

Shall we make a note of these changes in the release notes at least?

@hugovk
Copy link
Member Author

hugovk commented Feb 24, 2022

Yep, added to release notes in the last commit.

Co-authored-by: Andrew Murray <3112309+radarhere@users.noreply.github.com>
@hugovk hugovk added the automerge Automatically merge PRs that are ready label Feb 27, 2022
@mergify mergify bot merged commit 8abff14 into python-pillow:main Feb 27, 2022
@hugovk hugovk deleted the extras_require branch February 28, 2022 07:39
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
automerge Automatically merge PRs that are ready Installation Usually a problem with …
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants