bpo-40360: Deprecate the lib2to3 package (GH-28116)

This commit is contained in:
Victor Stinner 2021-09-02 11:46:47 +02:00 committed by GitHub
parent 679cb4781e
commit d589a7e7eb
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
4 changed files with 8 additions and 2 deletions

View File

@ -276,6 +276,9 @@ Build Changes
Deprecated
==========
* The :mod:`lib2to3` package is now deprecated and may not be able to parse
Python 3.10 or newer. See the :pep:`617` (New PEG parser for CPython).
(Contributed by Victor Stinner in :issue:`40360`.)
Removed

View File

@ -3,6 +3,6 @@
warnings.warn(
"lib2to3 package is deprecated and may not be able to parse Python 3.10+",
PendingDeprecationWarning,
DeprecationWarning,
stacklevel=2,
)

View File

@ -2,7 +2,7 @@
from test.support.import_helper import import_fresh_module
from test.support.warnings_helper import check_warnings
with check_warnings(("", PendingDeprecationWarning)):
with check_warnings(("", DeprecationWarning)):
load_tests = import_fresh_module('lib2to3.tests', fresh=['lib2to3']).load_tests
if __name__ == '__main__':

View File

@ -0,0 +1,3 @@
The :mod:`lib2to3` package is now deprecated and may not be able to parse
Python 3.10 or newer. See the :pep:`617` (New PEG parser for CPython). Patch
by Victor Stinner.