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

Prepare for Pip 23.2 release. #2174

Merged
merged 1 commit into from
Jul 11, 2023
Merged

Prepare for Pip 23.2 release. #2174

merged 1 commit into from
Jul 11, 2023

Conversation

jsirois
Copy link
Member

@jsirois jsirois commented Jul 11, 2023

A recent Pip commit has broken
pip --use-deprecated legacy-resolver download ... which is our
backwards-compatible default use case. Whether or not Pip decides to
fix, the legacy resolver will be yanked at some point and it seems
reasonable to just require any Pex user on Python 3.12 and thus Pip 23.2
to only use the Pip 2020 resolver.

See: pypa/pip#12138

A recent Pip commit has broken
`pip --use-deprecated legacy-resolver download ...` which is our
backwards-compatible default use case. Whether or not Pip decides to
fix, the legacy resolver will be yanked at some point and it seems
reasonable to just require any Pex user on Python 3.12 and thus Pip 23.2
to only use the Pip 2020 resolver.

See: pypa/pip#12138
Copy link
Collaborator

@kaos kaos left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lgtm.

Quite a few moving parts in the implementation I don't have a sense on, but I agree with taking the described actions outlined in the PR description.

@jsirois
Copy link
Member Author

jsirois commented Jul 11, 2023

Thanks for taking a look @kaos.

def _supports_legacy_resolver(pip_version=None):
# type: (Optional[PipVersionValue]) -> bool
pip_ver = pip_version or PipVersion.DEFAULT
return pip_ver.version < Version("23.2")
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It looks like the underlying issue will get fixed before 23.2 is released (pypa/pip#12140). I'll probably follow up, leaving all the code in this change in place but changing this function to just return True for all cases so that < Version("X.Y.Z") can go back in when Pip does actually drop support for the legacy resolver.

@jsirois jsirois merged commit 0e48174 into pex-tool:main Jul 11, 2023
30 checks passed
@jsirois jsirois deleted the Pip23.2/prep branch July 11, 2023 19:50
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants