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

pip check fails with pip==24.2: upf-to-json is not supported on this platform #4

Closed
danielhollas opened this issue Aug 2, 2024 · 3 comments · Fixed by #6
Closed
Labels
bug Something isn't working

Comments

@danielhollas
Copy link
Contributor

danielhollas commented Aug 2, 2024

Issue

Running a pip check in a fresh conda environment with latest pip==24.2 reports a problem that's likely caused by invalid wheel metadata. More info and discussion can be found on this issue:
pypa/pip#11054

To reproduce

$ conda create -n test pip=22.4 upf-to-json
$ conda activate test
$ pip check
upf-to-json 0.9.2 is not supported on this platform

Note that pip check does not fail if the upf-to-json package is installed with pip from PYPI.

@danielhollas
Copy link
Contributor Author

Looks like just rebuilding the package solves this issue. I've opened #5 and added pip check to tests.

@simonpintarelli
Copy link
Contributor

Thank you @danielhollas for the help.

@danielhollas
Copy link
Contributor Author

It looks like the problem is an incorrect Python version tag is specified in the *.dist-info/WHEEL file. Here's the content of the file in the current build.

Wheel-Version: 1.0
Generator: bdist_wheel (0.33.6)
Root-Is-Purelib: true
Tag: cp27-none-any

cp27 means that the package is restricted to CPython 2.7. Instead, to support both Python 2 to and Python 3, the platform tag should be py2.py3 per specification here: https://packaging.python.org/en/latest/specifications/platform-compatibility-tags/#python-tag

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
2 participants