This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

classification
Title: sysconfig.get_config_var("py_version_nodot") should return 3_10
Type: behavior Stage: resolved
Components: Installation Versions: Python 3.10
process
Status: closed Resolution: rejected
Dependencies: Superseder:
Assigned To: Nosy List: Mark.Shannon, The Compiler, lukasz.langa, mattip, pablogsal, steve.dower, vstinner
Priority: normal Keywords: patch

Created on 2020-05-23 20:47 by mattip, last changed 2022-04-11 14:59 by admin. This issue is now closed.

Pull Requests
URL Status Linked Edit
PR 20333 closed mattip, 2020-05-23 20:56
PR 22858 closed steve.dower, 2020-10-21 16:25
Messages (4)
msg369750 - (view) Author: mattip (mattip) * Date: 2020-05-23 20:47
Over in packaging, that code expects `sysconfig.get_config_var("py_version_nodot")` to be consistent with `tags._version_nodot`, which expects 3_10 for python 3.10. See https://github.com/pypa/packaging/issues/308. The current value of `sysconfig.get_config_var("py_version_nodot")` (which comes from https://github.com/python/cpython/blob/master/Lib/sysconfig.py#L89) is `310` which is ambiguous.
msg380344 - (view) Author: STINNER Victor (vstinner) * (Python committer) Date: 2020-11-04 17:10
Links about the "AssertionError: would build wheel with unsupported tag ('cp310', 'cp310', 'linux_x86_64')" error:

* PEP 641 -- Using an underscore in the version portion of Python 3.10 compatibility tags
  https://www.python.org/dev/peps/pep-0641/
* PEP 641 discussion:
  https://discuss.python.org/t/pep-641-using-an-underscore-in-the-version-portion-of-python-3-10-compatibility-tags/5513
* CPython PR 20333: "bpo-40747: Make py_version_nodot 3_10 not 310"
  https://github.com/python/cpython/pull/20333
* wheel: "Fails to build wheel for Python 3.10"
  https://github.com/pypa/wheel/issues/354
* python3-setuptools: "python-setuptools fails to build with Python 3.10: AssertionError: would build wheel with unsupported tag ('cp310', 'cp310', 'linux_x86_64')"
https://bugzilla.redhat.com/show_bug.cgi?id=1891840
msg382797 - (view) Author: Mark Shannon (Mark.Shannon) * (Python committer) Date: 2020-12-09 18:29
What's blocking this?
It is a real pain not to be able to install packages for 3.10.

I don't much care what the format is, but since there seems to be some difficulty in changing it, why not leave the output as `310`?

It isn't ambiguous, as long as we specify how to parse the number:
2 digits: XY.  X = major, Y = minor
3 digits: XYY. X = major, YY = minor
4 digits: XXYY. XX = major, YY = minor

So 31.0 will be `3100`.

That should be good for a millenium or so :)
msg382857 - (view) Author: Steve Dower (steve.dower) * (Python committer) Date: 2020-12-11 00:42
This has been blocking it: https://discuss.python.org/t/pep-641-using-an-underscore-in-the-version-portion-of-python-3-10-compatibility-tags/5513

Pablo (PEP delegate) has just posted his rejection though, so it will be fixed when packaging changes back to "310" from "3_10" and updates percolate out through the ecosystem.

Since moving to "4.x" is a breaking change, we can change to any system we like at that point. Well in advance of 31.0 being ambiguous.
History
Date User Action Args
2022-04-11 14:59:31adminsetgithub: 84924
2020-12-11 00:42:46steve.dowersetstatus: open -> closed
resolution: rejected
messages: + msg382857

stage: patch review -> resolved
2020-12-09 18:29:43Mark.Shannonsetnosy: + Mark.Shannon
messages: + msg382797
2020-11-04 17:10:03vstinnersetnosy: + vstinner
messages: + msg380344
2020-10-21 16:25:00steve.dowersetnosy: + steve.dower
pull_requests: + pull_request21801
2020-10-08 20:28:59The Compilersetnosy: + The Compiler
2020-05-24 00:44:58ned.deilysetnosy: + lukasz.langa, pablogsal
2020-05-23 20:56:52mattipsetkeywords: + patch
stage: patch review
pull_requests: + pull_request19601
2020-05-23 20:47:46mattipcreate