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

Drop run-time version constraints for modern pip #211

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Commits on Aug 26, 2024

  1. Drop run-time version constraints for modern pip

    Modern pip (v9.0.0+) supports `Requires-Python` and so automatically
    takes the current Python version into account, when determining the
    latest version of packages that can be installed.
    
    As such, for modern pip we don't need to specify version range
    constraints for the pip/setuptools/wheel versions passed to the
    `pip install` at `get-pip.py` run-time.
    
    This is the first step towards being able to remove `SCRIPT_CONSTRAINTS`
    and rely purely on `Requires-Python` metadata, per:
    pypa#88 (comment)
    
    I've intentionally left the "figure out what pip version to embed in the
    template" part of template generation alone for now to keep the PR
    smaller, and have only changed the run-time `pip install` parts.
    
    I had to add a new `pre-9.py` template file (created as a copy of
    `pre-10.py`), since it's only pip<9 that needs the various version
    constraint references in the template (and otherwise anything else that
    used `pre-10.py`, such as Python 2.6, would have had redundant version
    constraints). The new `pre-9.py` template is only used for Python 3.2.
    edmorley committed Aug 26, 2024
    Configuration menu
    Copy the full SHA
    a2eb69d View commit details
    Browse the repository at this point in the history