@@ -1274,13 +1274,19 @@ although there is currently no date scheduled for their removal.
1274
1274
Removed
1275
1275
=======
1276
1276
1277
- * ``asynchat `` and ``asyncore ``: These two modules have been removed
1277
+ asynchat and asyncore
1278
+ ---------------------
1279
+
1280
+ * These two modules have been removed
1278
1281
according to the schedule in :pep: `594 `,
1279
1282
having been deprecated in Python 3.6.
1280
1283
Use :mod: `asyncio ` instead.
1281
1284
(Contributed by Nikita Sobolev in :gh: `96580 `.)
1282
1285
1283
- * :mod: `configparser `: Several names deprecated in the :mod: `configparser ` way back in 3.2 have
1286
+ configparser
1287
+ ------------
1288
+
1289
+ * Several names deprecated in the :mod: `configparser ` way back in 3.2 have
1284
1290
been removed per :gh: `89336 `:
1285
1291
1286
1292
* :class: `configparser.ParsingError ` no longer has a ``filename `` attribute
@@ -1290,13 +1296,19 @@ Removed
1290
1296
* :class: `configparser.ConfigParser ` no longer has a ``readfp `` method.
1291
1297
Use :meth: `~configparser.ConfigParser.read_file ` instead.
1292
1298
1293
- * ``distutils ``: Remove the ``distutils `` package. It was deprecated in Python 3.10 by
1299
+ distutils
1300
+ ---------
1301
+
1302
+ * Remove the :py:mod: `!distutils ` package. It was deprecated in Python 3.10 by
1294
1303
:pep: `632 ` "Deprecate distutils module". For projects still using
1295
1304
``distutils `` and cannot be updated to something else, the ``setuptools ``
1296
1305
project can be installed: it still provides ``distutils ``.
1297
1306
(Contributed by Victor Stinner in :gh: `92584 `.)
1298
1307
1299
- * :mod: `ensurepip `: Remove the bundled setuptools wheel from :mod: `ensurepip `,
1308
+ ensurepip
1309
+ ---------
1310
+
1311
+ * Remove the bundled setuptools wheel from :mod: `ensurepip `,
1300
1312
and stop installing setuptools in environments created by :mod: `venv `.
1301
1313
1302
1314
``pip (>= 22.1) `` does not require setuptools to be installed in the
@@ -1314,27 +1326,42 @@ Removed
1314
1326
1315
1327
(Contributed by Pradyun Gedam in :gh: `95299 `.)
1316
1328
1317
- * :mod: `enum `: Remove ``EnumMeta.__getattr__ ``, which is no longer needed for
1329
+ enum
1330
+ ----
1331
+
1332
+ * Remove :mod: `enum `'s ``EnumMeta.__getattr__ ``, which is no longer needed for
1318
1333
enum attribute access.
1319
1334
(Contributed by Ethan Furman in :gh: `95083 `.)
1320
1335
1321
- * :mod: `ftplib `: Remove the ``FTP_TLS.ssl_version `` class attribute: use the
1336
+ ftplib
1337
+ ------
1338
+
1339
+ * Remove :mod: `ftplib `'s ``FTP_TLS.ssl_version `` class attribute: use the
1322
1340
*context * parameter instead.
1323
1341
(Contributed by Victor Stinner in :gh: `94172 `.)
1324
1342
1325
- * :mod: `gzip `: Remove the ``filename `` attribute of :class: `gzip.GzipFile `,
1343
+ gzip
1344
+ ----
1345
+
1346
+ * Remove the ``filename `` attribute of :mod: `gzip `'s :class: `gzip.GzipFile `,
1326
1347
deprecated since Python 2.6, use the :attr: `~gzip.GzipFile.name ` attribute
1327
1348
instead. In write mode, the ``filename `` attribute added ``'.gz' `` file
1328
1349
extension if it was not present.
1329
1350
(Contributed by Victor Stinner in :gh: `94196 `.)
1330
1351
1331
- * :mod: `hashlib `: Remove the pure Python implementation of
1352
+ hashlib
1353
+ -------
1354
+
1355
+ * Remove the pure Python implementation of :mod: `hashlib `'s
1332
1356
:func: `hashlib.pbkdf2_hmac() `, deprecated in Python 3.10. Python 3.10 and
1333
1357
newer requires OpenSSL 1.1.1 (:pep: `644 `): this OpenSSL version provides
1334
1358
a C implementation of :func: `~hashlib.pbkdf2_hmac() ` which is faster.
1335
1359
(Contributed by Victor Stinner in :gh: `94199 `.)
1336
1360
1337
- * :mod: `importlib `: Many previously deprecated cleanups in :mod: `importlib ` have now been
1361
+ importlib
1362
+ ---------
1363
+
1364
+ * Many previously deprecated cleanups in :mod: `importlib ` have now been
1338
1365
completed:
1339
1366
1340
1367
* References to, and support for :meth: `!module_repr() ` has been removed.
@@ -1350,10 +1377,13 @@ Removed
1350
1377
* ``importlib.abc.Finder ``, ``pkgutil.ImpImporter ``, and ``pkgutil.ImpLoader ``
1351
1378
have been removed. (Contributed by Barry Warsaw in :gh: `98040 `.)
1352
1379
1353
- * The :mod: ` ! imp` module has been removed. (Contributed by Barry Warsaw in
1354
- :gh: ` 98040 `.)
1380
+ imp
1381
+ ---
1355
1382
1356
- * Replace removed :mod: `!imp ` functions with :mod: `importlib ` functions:
1383
+ * The :mod: `!imp ` module has been removed. (Contributed by Barry Warsaw in
1384
+ :gh: `98040 `.)
1385
+
1386
+ * Replace removed :mod: `!imp ` functions with :mod: `importlib ` functions:
1357
1387
1358
1388
================================= =======================================
1359
1389
imp importlib
@@ -1370,7 +1400,7 @@ Removed
1370
1400
``imp.source_from_cache() `` :func: `importlib.util.source_from_cache `
1371
1401
================================= =======================================
1372
1402
1373
- * Replace ``imp.load_source() `` with::
1403
+ * Replace ``imp.load_source() `` with::
1374
1404
1375
1405
import importlib.util
1376
1406
import importlib.machinery
@@ -1385,28 +1415,34 @@ Removed
1385
1415
loader.exec_module(module)
1386
1416
return module
1387
1417
1388
- * Removed :mod: `!imp ` functions and attributes with no replacements:
1418
+ * Removed :mod: `!imp ` functions and attributes with no replacements:
1419
+
1420
+ * undocumented functions:
1389
1421
1390
- * undocumented functions:
1422
+ * ``imp.init_builtin() ``
1423
+ * ``imp.load_compiled() ``
1424
+ * ``imp.load_dynamic() ``
1425
+ * ``imp.load_package() ``
1391
1426
1392
- * ``imp.init_builtin() ``
1393
- * ``imp.load_compiled() ``
1394
- * ``imp.load_dynamic() ``
1395
- * ``imp.load_package() ``
1427
+ * ``imp.lock_held() ``, ``imp.acquire_lock() ``, ``imp.release_lock() ``:
1428
+ the locking scheme has changed in Python 3.3 to per-module locks.
1429
+ * ``imp.find_module() `` constants: ``SEARCH_ERROR ``, ``PY_SOURCE ``,
1430
+ ``PY_COMPILED ``, ``C_EXTENSION ``, ``PY_RESOURCE ``, ``PKG_DIRECTORY ``,
1431
+ ``C_BUILTIN ``, ``PY_FROZEN ``, ``PY_CODERESOURCE ``, ``IMP_HOOK ``.
1396
1432
1397
- * ``imp.lock_held() ``, ``imp.acquire_lock() ``, ``imp.release_lock() ``:
1398
- the locking scheme has changed in Python 3.3 to per-module locks.
1399
- * ``imp.find_module() `` constants: ``SEARCH_ERROR ``, ``PY_SOURCE ``,
1400
- ``PY_COMPILED ``, ``C_EXTENSION ``, ``PY_RESOURCE ``, ``PKG_DIRECTORY ``,
1401
- ``C_BUILTIN ``, ``PY_FROZEN ``, ``PY_CODERESOURCE ``, ``IMP_HOOK ``.
1433
+ io
1434
+ --
1402
1435
1403
- * :mod: `io `: Remove ``io.OpenWrapper `` and ``_pyio.OpenWrapper ``, deprecated in Python
1436
+ * Remove :mod: `io `'s ``io.OpenWrapper `` and ``_pyio.OpenWrapper ``, deprecated in Python
1404
1437
3.10: just use :func: `open ` instead. The :func: `open ` (:func: `io.open `)
1405
1438
function is a built-in function. Since Python 3.10, :func: `!_pyio.open ` is
1406
1439
also a static method.
1407
1440
(Contributed by Victor Stinner in :gh: `94169 `.)
1408
1441
1409
- * :mod: `locale `: Remove the :func: `!locale.format ` function, deprecated in Python 3.7:
1442
+ locale
1443
+ ------
1444
+
1445
+ * Remove :mod: `locale `'s :func: `!locale.format ` function, deprecated in Python 3.7:
1410
1446
use :func: `locale.format_string ` instead.
1411
1447
(Contributed by Victor Stinner in :gh: `94226 `.)
1412
1448
@@ -1418,7 +1454,10 @@ Removed
1418
1454
1419
1455
.. _aiosmtpd : https://pypi.org/project/aiosmtpd/
1420
1456
1421
- * :mod: `sqlite3 `: The following undocumented :mod: `sqlite3 ` features, deprecated in Python
1457
+ sqlite3
1458
+ -------
1459
+
1460
+ * The following undocumented :mod: `sqlite3 ` features, deprecated in Python
1422
1461
3.10, are now removed:
1423
1462
1424
1463
* ``sqlite3.enable_shared_cache() ``
@@ -1434,30 +1473,34 @@ Removed
1434
1473
1435
1474
(Contributed by Erlend E. Aasland in :gh: `92548 `.)
1436
1475
1437
- * :mod: `ssl `:
1476
+ ssl
1477
+ ---
1438
1478
1439
- * Remove the :func: `!ssl.RAND_pseudo_bytes ` function, deprecated in Python 3.6:
1440
- use :func: `os.urandom ` or :func: `ssl.RAND_bytes ` instead.
1441
- (Contributed by Victor Stinner in :gh: `94199 `.)
1479
+ * Remove :mod: `ssl `'s :func: `!ssl.RAND_pseudo_bytes ` function, deprecated in Python 3.6:
1480
+ use :func: `os.urandom ` or :func: `ssl.RAND_bytes ` instead.
1481
+ (Contributed by Victor Stinner in :gh: `94199 `.)
1482
+
1483
+ * Remove the :func: `!ssl.match_hostname ` function.
1484
+ It was deprecated in Python 3.7. OpenSSL performs
1485
+ hostname matching since Python 3.7, Python no longer uses the
1486
+ :func: `!ssl.match_hostname ` function.
1487
+ (Contributed by Victor Stinner in :gh: `94199 `.)
1442
1488
1443
- * Remove the :func: `!ssl.match_hostname ` function.
1444
- It was deprecated in Python 3.7. OpenSSL performs
1445
- hostname matching since Python 3.7, Python no longer uses the
1446
- :func: `!ssl.match_hostname ` function.
1447
- (Contributed by Victor Stinner in :gh: `94199 `.)
1489
+ * Remove the :func: `!ssl.wrap_socket ` function, deprecated in Python 3.7:
1490
+ instead, create a :class: `ssl.SSLContext ` object and call its
1491
+ :class: `ssl.SSLContext.wrap_socket ` method. Any package that still uses
1492
+ :func: `!ssl.wrap_socket ` is broken and insecure. The function neither sends a
1493
+ SNI TLS extension nor validates server hostname. Code is subject to `CWE-295
1494
+ <https://cwe.mitre.org/data/definitions/295.html> `_: Improper Certificate
1495
+ Validation.
1496
+ (Contributed by Victor Stinner in :gh: `94199 `.)
1448
1497
1449
- * Remove the :func: `!ssl.wrap_socket ` function, deprecated in Python 3.7:
1450
- instead, create a :class: `ssl.SSLContext ` object and call its
1451
- :class: `ssl.SSLContext.wrap_socket ` method. Any package that still uses
1452
- :func: `!ssl.wrap_socket ` is broken and insecure. The function neither sends a
1453
- SNI TLS extension nor validates server hostname. Code is subject to `CWE-295
1454
- <https://cwe.mitre.org/data/definitions/295.html> `_: Improper Certificate
1455
- Validation.
1456
- (Contributed by Victor Stinner in :gh: `94199 `.)
1498
+ unittest
1499
+ --------
1457
1500
1458
- * :mod: ` unittest `: Removed many old deprecated :mod: `unittest ` features:
1501
+ * Removed many old deprecated :mod: `unittest ` features:
1459
1502
1460
- - A number of :class: `~unittest.TestCase ` method aliases:
1503
+ * A number of :class: `~unittest.TestCase ` method aliases:
1461
1504
1462
1505
============================ =============================== ===============
1463
1506
Deprecated alias Method Name Deprecated in
@@ -1482,33 +1525,45 @@ Removed
1482
1525
You can use https://github.com/isidentical/teyit to automatically modernise
1483
1526
your unit tests.
1484
1527
1485
- - Undocumented and broken :class: `~unittest.TestCase ` method
1528
+ * Undocumented and broken :class: `~unittest.TestCase ` method
1486
1529
``assertDictContainsSubset `` (deprecated in Python 3.2).
1487
1530
1488
- - Undocumented :meth: `TestLoader.loadTestsFromModule
1531
+ * Undocumented :meth: `TestLoader.loadTestsFromModule
1489
1532
<unittest.TestLoader.loadTestsFromModule> ` parameter *use_load_tests *
1490
1533
(deprecated and ignored since Python 3.2).
1491
1534
1492
- - An alias of the :class: `~unittest.TextTestResult ` class:
1535
+ * An alias of the :class: `~unittest.TextTestResult ` class:
1493
1536
``_TextTestResult `` (deprecated in Python 3.2).
1494
1537
1495
1538
(Contributed by Serhiy Storchaka in :issue: `45162 `.)
1496
1539
1497
- * :mod: `webbrowser `: Remove support for obsolete browsers from :mod: `webbrowser `.
1540
+ webbrowser
1541
+ ----------
1542
+
1543
+ * Remove support for obsolete browsers from :mod: `webbrowser `.
1498
1544
Removed browsers include: Grail, Mosaic, Netscape, Galeon, Skipstone,
1499
1545
Iceape, Firebird, and Firefox versions 35 and below (:gh: `102871 `).
1500
1546
1501
- * :mod: `xml.etree.ElementTree `: Remove the ``ElementTree.Element.copy() `` method of the
1547
+ xml.etree.ElementTree
1548
+ ---------------------
1549
+
1550
+ * Remove the ``ElementTree.Element.copy() `` method of the
1502
1551
pure Python implementation, deprecated in Python 3.10, use the
1503
1552
:func: `copy.copy ` function instead. The C implementation of :mod: `xml.etree.ElementTree `
1504
1553
has no ``copy() `` method, only a ``__copy__() `` method.
1505
1554
(Contributed by Victor Stinner in :gh: `94383 `.)
1506
1555
1507
- * :mod: `zipimport `: Remove ``find_loader() `` and ``find_module() `` methods,
1556
+ zipimport
1557
+ ---------
1558
+
1559
+ * Remove :mod: `zipimport `'s ``find_loader() `` and ``find_module() `` methods,
1508
1560
deprecated in Python 3.10: use the ``find_spec() `` method instead. See
1509
1561
:pep: `451 ` for the rationale.
1510
1562
(Contributed by Victor Stinner in :gh: `94379 `.)
1511
1563
1564
+ Others
1565
+ ------
1566
+
1512
1567
* Removed the ``suspicious `` rule from the documentation Makefile, and
1513
1568
removed ``Doc/tools/rstlint.py ``, both in favor of `sphinx-lint
1514
1569
<https://github.com/sphinx-contrib/sphinx-lint> `_.
0 commit comments