-
-
Notifications
You must be signed in to change notification settings - Fork 30.4k
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
PYTHON_FOR_REGEN only works with Python 3.10 or newer #104487
Comments
(FWIW, this issue was originally highlighted by running mypy on |
cc. @gvanrossum and @iritkatriel for |
I’m reluctant to have to dumb down the cases generator to 3.8. Can we please just bump the required version to 3.10? As you say there isn’t much need for earlier versions, apparently. |
I've updated my PR with Python 3.10 as the minimum version, and I also included Python 3.12 in the list. |
I also agree with bumping minimal version to 3.10 (as I said in the original issue). Plus, this makes writting code much more pleasant due to new typing + syntax features. @erlend-aasland thanks for raising this! 👍 |
Bootstrapping Python on a new platform. Come to think of it, you probably won't use |
Also include Python 3.12 in the list of accepted versions.
* main: (29 commits) pythongh-101819: Fix _io clinic input for unused base class method stubs (python#104418) pythongh-101819: Isolate `_io` (python#101948) Bump mypy from 1.2.0 to 1.3.0 in /Tools/clinic (python#104501) pythongh-104494: Update certain Tkinter pack/place tests for Tk 8.7 errors (python#104495) pythongh-104050: Run mypy on `clinic.py` in CI (python#104421) pythongh-104490: Consistently define phony make targets (python#104491) pythongh-67056: document that registering/unregistering an atexit func from within an atexit func is undefined (python#104473) pythongh-104487: PYTHON_FOR_REGEN must be minimum Python 3.10 (python#104488) pythongh-101282: move BOLT config after PGO (pythongh-104493) pythongh-104469 Convert _testcapi/float.c to use AC (pythongh-104470) pythongh-104456: Fix ref leak in _ctypes.COMError (python#104457) pythongh-98539: Make _SSLTransportProtocol.abort() safe to call when closed (python#104474) pythongh-104337: Clarify random.gammavariate doc entry (python#104410) Minor improvements to typing docs (python#104465) pythongh-87092: avoid gcc warning on uninitialized struct field in assemble.c (python#104460) pythonGH-71383: IDLE - Document testing subsets of modules (python#104463) pythongh-104454: Fix refleak in AttributeError_reduce (python#104455) pythongh-75710: IDLE - add docstrings and comments to editor module (python#104446) pythongh-91896: Revert some very noisy DeprecationWarnings for `ByteString` (python#104424) Add a mention of PYTHONBREAKPOINT to breakpoint() docs (python#104430) ...
* main: (204 commits) pythongh-101819: Fix _io clinic input for unused base class method stubs (python#104418) pythongh-101819: Isolate `_io` (python#101948) Bump mypy from 1.2.0 to 1.3.0 in /Tools/clinic (python#104501) pythongh-104494: Update certain Tkinter pack/place tests for Tk 8.7 errors (python#104495) pythongh-104050: Run mypy on `clinic.py` in CI (python#104421) pythongh-104490: Consistently define phony make targets (python#104491) pythongh-67056: document that registering/unregistering an atexit func from within an atexit func is undefined (python#104473) pythongh-104487: PYTHON_FOR_REGEN must be minimum Python 3.10 (python#104488) pythongh-101282: move BOLT config after PGO (pythongh-104493) pythongh-104469 Convert _testcapi/float.c to use AC (pythongh-104470) pythongh-104456: Fix ref leak in _ctypes.COMError (python#104457) pythongh-98539: Make _SSLTransportProtocol.abort() safe to call when closed (python#104474) pythongh-104337: Clarify random.gammavariate doc entry (python#104410) Minor improvements to typing docs (python#104465) pythongh-87092: avoid gcc warning on uninitialized struct field in assemble.c (python#104460) pythonGH-71383: IDLE - Document testing subsets of modules (python#104463) pythongh-104454: Fix refleak in AttributeError_reduce (python#104455) pythongh-75710: IDLE - add docstrings and comments to editor module (python#104446) pythongh-91896: Revert some very noisy DeprecationWarnings for `ByteString` (python#104424) Add a mention of PYTHONBREAKPOINT to breakpoint() docs (python#104430) ...
On current
main
,PYTHON_FOR_REGEN
only works with Python 3.10 or newer.Previously, we've tried to maintain backwards compatibility with older Python versions in our build system. Last time we adjusted
PYTHON_FOR_REGEN
(gh-98988), we deliberately did not bump the minimal version requirements; ourconfigure
checks for Python 3.11 through Python 3.6.While working on gh-104050, a discussion about version requirements came up, and we found out that on
main
,make clinic
only works whenPYTHON_FOR_REGEN
is Python 3.10 or newer. Also, the newly introduced "generate cases script" uses pattern matching and uses newly introduced typing features. Per now,PYTHON_FOR_REGEN
must be 3.10 or newer.There are two solution to this:
PYTHON_FOR_REGEN
version requirements to 3.10 inconfigure
Personally, I think I'm leaning towards the former. Apparently no core dev, triager or other contributor has noticed this issue until now. No buildbot has failed (we don't test the minimum required version; perhaps we should). OTOH, I understand that it makes stuff like bootstrapping slightly more cumbersome.
Anyway, we should probably at least bump the version requirement from Python 3.6 to 3.8.
Linked PRs
The text was updated successfully, but these errors were encountered: