Skip to content

Conversation

@adamchainz
Copy link
Contributor

@adamchainz adamchainz commented Nov 21, 2019

Description

Pip's dependency resolver (used in pipenv, pip-compile, poetry, etc.) can use this to infer whether there's a verison collision in what it's being asked to install or not.

Pip's dependency resolver (used in pipenv, pip-compile, poetry, etc.) can use this to infer whether there's a verison collision in what it's being asked to install or not.
@lovelydinosaur
Copy link
Contributor

We've avoided including a hard django package dependency in the past. I expect we have users who're doing things like running against a custom django codebase, that's just installed locally, rather than using a PyPI version.

I like the change for most users, but I think it might bite us.

@adamchainz
Copy link
Contributor Author

I've not had a complaint in django-cors-headers, at least since I added the requirement in March.

The (small) problem I ran into was the Scout test suite which runs from Django 1.8 to 3.0 (😱) was always pulling the latest DRF because there are no restrictions, and I had to go read the changelog to add the correct version pins for each environment.

@rpkilby
Copy link
Contributor

rpkilby commented Nov 21, 2019

I'd be -1 on enforcing a maximum supported version, but otherwise think this makes sense.

I expect we have users who're doing things like running against a custom django codebase, that's just installed locally, rather than using a PyPI version.

So long as their package is also named Django, this shouldn't matter, right?

@adamchainz
Copy link
Contributor Author

I'd be -1 on enforcing a maximum supported version, but otherwise think this makes sense.

Fair.

@rpkilby rpkilby added this to the 3.11 Release milestone Dec 11, 2019
@lovelydinosaur
Copy link
Contributor

Let's do it. Thanks!

@lovelydinosaur lovelydinosaur merged commit 7c54596 into encode:master Dec 12, 2019
pchiquet pushed a commit to pchiquet/django-rest-framework that referenced this pull request Nov 17, 2020
* Declare Django versions in install_requires Pip's dependency resolver (used in pipenv, pip-compile, poetry, etc.) can use this to infer whether there's a verison collision in what it's being asked to install or not. * No max
sigvef pushed a commit to sigvef/django-rest-framework that referenced this pull request Dec 3, 2022
* Declare Django versions in install_requires Pip's dependency resolver (used in pipenv, pip-compile, poetry, etc.) can use this to infer whether there's a verison collision in what it's being asked to install or not. * No max
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

4 participants