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

bdist_wheel does not work with multiple --plat-name tags #394

Open
pombredanne opened this issue Feb 20, 2021 · 1 comment
Open

bdist_wheel does not work with multiple --plat-name tags #394

pombredanne opened this issue Feb 20, 2021 · 1 comment

Comments

@pombredanne
Copy link

pombredanne commented Feb 20, 2021

There are times (like right now with macOS bigsur triggering several issues) where having a wheel built with more than one plat-name tag would help and be required. These tag names should end up as a dot-separated platform tag. BUT:

  • using bdist_wheel --plat-name a --plat-name b will only consider b and ignore a
  • using bdist_wheel --plat-name a.b will create an a_b tag instead of an a.b tag

The only sane ways I found are:

  1. rename the wheel with a proper dot-separated tag. This works but the WHEEL Tag is not updated
  2. use wheel unpack then update the .dist-info/WHEEL Tag then wheel pack. Here the WHEEL file content and wheel file name are in sync.

We should be able to do better!

I suggest that no transformation be applied to the --plat-name option value OR that at least .dots are not replaced by _underscores.

Possibly here https://github.com/pypa/wheel/blob/master/src/wheel/bdist_wheel.py#L104 or/and here https://github.com/pypa/wheel/blob/master/src/wheel/bdist_wheel.py#L265

These small but important changes would mean that we can allow multiples platforms in a single --plat-name option. This would be the preferred way as the use of --plat-name is not a noob option so having it allow advanced values for proper control should be fine.

Alternatively the bdist_wheel --plat-name option should accept multiple values, either coma-separated as in --plat-name=a,b or with multiple --plat-name a --plat-name b

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

No branches or pull requests

1 participant