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

Add packaging.tags.interpreter_abi #610

Open
FFY00 opened this issue Nov 8, 2022 · 5 comments · May be fixed by #611
Open

Add packaging.tags.interpreter_abi #610

FFY00 opened this issue Nov 8, 2022 · 5 comments · May be fixed by #611

Comments

@FFY00
Copy link
Member

FFY00 commented Nov 8, 2022

Build backends that build extension modules will want to know the interpreter tag for the current interpreter.

Currently, the easiest way to achieve that is via sys_tags:

next(tags.sys_tags()).abi

packaging could provide a packaging.tags.interpreter_tag function that avoids going through sys_tags.

@FFY00 FFY00 changed the title Add packaging.tags.interpreter_tag Add packaging.tags.interpreter_abi Nov 9, 2022
@brettcannon
Copy link
Member

So you just want the running interpreter's most strict ABI tag? Or are you after all supported ABI tags?

@FFY00
Copy link
Member Author

FFY00 commented Nov 9, 2022

Yes. In practice, this is only relevant to CPython right now, where debug builds can load both debug and non-debug modules, but we want the debug tag in that case.

@brettcannon
Copy link
Member

Yes.

"Yes", which? Most strict or all tags?

@mayeut
Copy link
Member

mayeut commented Aug 20, 2023

xref python/cpython#103483

In any case, packaging will probably end up implementing the linked issue in order to provide a backport for currently supported python interpreters ?

The question raised by @brettcannon leads me to other questions.

I guess the original intent is for most specific tag in order to ease non-pure wheel building/tagging: ref python/cpython#99560 (cc @mattip)

Does this means that cp3?-abi3- will be left-out or should multiple tags be reported ?

@mattip
Copy link
Contributor

mattip commented Aug 20, 2023

I would think "most strict" would be sufficient for packaging to determine the logic for the rest of the tags, as is done in PR #611.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants