1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
1001
1002
1003
1004
1005
1006
1007
1008
1009
1010
1011
1012
1013
1014
1015
1016
1017
1018
1019
1020
1021
1022
1023
1024
1025
1026
1027
1028
1029
1030
1031
1032
1033
1034
1035
1036
1037
1038
1039
1040
1041
1042
1043
1044
1045
1046
1047
1048
1049
1050
1051
1052
1053
1054
1055
1056
1057
1058
1059
1060
1061
1062
1063
1064
1065
1066
1067
1068
1069
1070
1071
1072
1073
1074
1075
1076
1077
1078
1079
1080
1081
1082
1083
1084
1085
1086
1087
1088
1089
1090
1091
1092
1093
1094
1095
1096
1097
1098
1099
1100
1101
1102
1103
1104
1105
1106
1107
1108
1109
1110
1111
1112
1113
1114
1115
1116
1117
1118
1119
1120
1121
1122
1123
1124
1125
1126
1127
1128
1129
1130
1131
1132
1133
1134
1135
1136
1137
1138
1139
1140
1141
1142
1143
1144
1145
1146
1147
1148
1149
1150
1151
1152
1153
1154
1155
1156
1157
1158
1159
1160
1161
1162
1163
1164
1165
1166
1167
1168
1169
1170
1171
1172
1173
1174
1175
1176
1177
1178
1179
1180
1181
1182
1183
1184
1185
1186
1187
1188
1189
1190
1191
1192
1193
1194
1195
1196
1197
1198
1199
1200
1201
1202
1203
1204
1205
1206
1207
1208
1209
1210
1211
1212
1213
1214
1215
1216
1217
1218
1219
1220
1221
1222
1223
1224
1225
1226
1227
1228
1229
1230
1231
1232
1233
1234
1235
1236
1237
1238
1239
1240
1241
1242
1243
1244
1245
1246
1247
1248
1249
1250
1251
1252
1253
1254
1255
1256
1257
1258
1259
1260
1261
1262
1263
1264
1265
1266
1267
1268
1269
1270
1271
1272
1273
1274
1275
1276
1277
1278
1279
1280
1281
1282
1283
1284
1285
1286
1287
1288
1289
1290
1291
1292
1293
1294
1295
1296
1297
1298
1299
1300
1301
1302
1303
1304
1305
1306
1307
1308
1309
1310
1311
1312
1313
1314
1315
1316
1317
1318
1319
1320
1321
1322
1323
1324
1325
1326
1327
1328
1329
1330
1331
1332
1333
1334
1335
1336
1337
1338
1339
1340
1341
1342
1343
1344
1345
1346
1347
1348
1349
1350
1351
1352
1353
1354
1355
1356
1357
1358
1359
1360
1361
1362
1363
1364
1365
1366
1367
1368
1369
1370
1371
1372
1373
1374
1375
1376
1377
1378
1379
1380
1381
1382
1383
1384
1385
1386
1387
1388
1389
1390
1391
1392
1393
1394
1395
1396
1397
1398
1399
1400
1401
1402
1403
1404
1405
1406
1407
1408
1409
1410
1411
1412
1413
1414
1415
1416
1417
1418
1419
1420
1421
1422
1423
1424
1425
1426
1427
1428
1429
1430
1431
1432
1433
1434
1435
1436
1437
1438
1439
1440
1441
1442
1443
1444
1445
1446
1447
1448
1449
1450
1451
1452
1453
1454
1455
1456
1457
1458
1459
1460
1461
1462
1463
1464
1465
1466
1467
1468
1469
1470
1471
1472
1473
1474
1475
1476
1477
1478
1479
1480
1481
1482
1483
1484
1485
1486
1487
1488
1489
1490
1491
1492
1493
1494
1495
1496
1497
1498
1499
1500
1501
1502
1503
1504
1505
1506
1507
1508
1509
1510
1511
1512
1513
1514
1515
1516
1517
1518
1519
1520
1521
1522
1523
1524
1525
1526
1527
1528
1529
1530
1531
1532
1533
1534
1535
1536
1537
1538
1539
1540
1541
1542
1543
1544
1545
1546
1547
1548
1549
1550
1551
1552
1553
1554
1555
1556
1557
1558
1559
1560
1561
1562
1563
1564
1565
1566
1567
1568
1569
1570
1571
1572
1573
1574
1575
1576
1577
1578
1579
1580
1581
1582
1583
1584
1585
1586
1587
1588
1589
1590
1591
1592
1593
1594
1595
1596
1597
1598
1599
1600
1601
1602
1603
1604
1605
1606
1607
1608
1609
1610
1611
1612
1613
1614
1615
1616
1617
1618
1619
1620
1621
1622
1623
1624
1625
1626
1627
1628
1629
1630
1631
1632
1633
1634
1635
1636
1637
1638
1639
1640
1641
1642
1643
1644
1645
1646
1647
1648
1649
1650
1651
1652
1653
1654
1655
1656
1657
1658
1659
1660
1661
1662
1663
1664
1665
1666
1667
1668
1669
1670
1671
1672
1673
1674
1675
1676
1677
1678
1679
1680
1681
1682
1683
1684
1685
1686
1687
1688
1689
1690
1691
1692
1693
1694
1695
1696
1697
1698
1699
1700
1701
1702
1703
1704
1705
1706
1707
1708
1709
1710
1711
1712
1713
1714
1715
1716
1717
1718
1719
1720
1721
1722
1723
1724
1725
1726
1727
1728
1729
1730
1731
1732
1733
1734
1735
1736
1737
1738
1739
1740
1741
1742
1743
1744
1745
1746
1747
1748
1749
1750
1751
1752
1753
1754
1755
1756
1757
1758
1759
1760
1761
1762
1763
1764
1765
1766
1767
1768
1769
1770
1771
1772
1773
1774
1775
1776
1777
1778
1779
1780
1781
1782
1783
1784
1785
1786
1787
1788
1789
1790
1791
1792
1793
1794
1795
1796
1797
1798
1799
1800
1801
1802
1803
1804
1805
1806
1807
1808
1809
1810
1811
1812
1813
1814
1815
1816
1817
1818
1819
1820
1821
1822
1823
1824
1825
1826
1827
1828
1829
1830
1831
1832
1833
1834
1835
1836
1837
1838
1839
1840
1841
1842
1843
1844
1845
1846
1847
1848
1849
1850
1851
1852
1853
1854
1855
1856
1857
1858
1859
1860
1861
1862
1863
1864
1865
1866
1867
1868
1869
1870
1871
1872
1873
1874
1875
1876
1877
1878
1879
1880
1881
1882
1883
1884
1885
1886
1887
1888
1889
1890
1891
1892
1893
1894
1895
1896
1897
1898
1899
1900
1901
1902
1903
1904
1905
1906
1907
1908
1909
1910
1911
1912
1913
1914
1915
1916
1917
1918
1919
1920
1921
1922
1923
1924
1925
1926
1927
1928
1929
1930
1931
1932
1933
1934
1935
1936
1937
1938
1939
1940
1941
1942
1943
1944
1945
1946
1947
1948
1949
1950
1951
1952
1953
1954
1955
1956
1957
1958
1959
1960
1961
1962
1963
1964
1965
1966
1967
1968
1969
1970
1971
1972
1973
1974
1975
1976
1977
1978
1979
1980
1981
1982
1983
1984
1985
1986
1987
1988
1989
1990
1991
1992
1993
1994
1995
1996
1997
1998
1999
2000
2001
2002
2003
2004
2005
2006
2007
2008
2009
2010
2011
2012
2013
2014
2015
2016
2017
2018
2019
2020
2021
2022
2023
2024
2025
2026
2027
2028
2029
2030
2031
2032
2033
2034
2035
2036
2037
2038
2039
2040
2041
2042
2043
2044
2045
2046
2047
2048
2049
2050
2051
2052
2053
2054
2055
2056
2057
2058
2059
2060
2061
2062
2063
2064
2065
2066
2067
2068
2069
2070
2071
2072
2073
2074
2075
2076
2077
2078
2079
2080
2081
2082
2083
2084
2085
2086
2087
2088
2089
2090
2091
2092
2093
2094
2095
2096
2097
2098
2099
2100
2101
2102
2103
2104
2105
2106
2107
2108
2109
2110
2111
2112
2113
2114
2115
2116
2117
2118
2119
2120
2121
2122
2123
2124
2125
2126
2127
2128
2129
2130
2131
2132
2133
2134
2135
2136
2137
2138
2139
2140
2141
2142
2143
2144
2145
2146
2147
2148
2149
2150
2151
2152
2153
2154
2155
2156
2157
2158
2159
2160
2161
2162
2163
2164
2165
2166
2167
2168
2169
2170
2171
2172
2173
2174
2175
2176
2177
2178
2179
2180
2181
2182
2183
2184
2185
2186
2187
2188
2189
2190
2191
2192
2193
2194
2195
2196
2197
2198
2199
2200
2201
2202
2203
2204
2205
2206
2207
2208
2209
2210
2211
2212
2213
2214
2215
2216
2217
2218
2219
2220
2221
2222
2223
2224
2225
2226
2227
2228
2229
2230
2231
2232
2233
2234
2235
2236
2237
2238
2239
2240
2241
2242
2243
2244
2245
2246
2247
2248
2249
2250
2251
2252
2253
2254
2255
2256
2257
2258
2259
2260
2261
2262
2263
2264
2265
2266
2267
2268
2269
2270
2271
2272
2273
2274
2275
2276
2277
2278
2279
2280
2281
2282
2283
2284
2285
2286
2287
2288
2289
2290
2291
2292
2293
2294
2295
2296
2297
2298
2299
2300
2301
2302
2303
2304
2305
2306
2307
2308
2309
2310
2311
2312
2313
2314
2315
2316
2317
2318
2319
2320
2321
2322
2323
2324
2325
2326
2327
2328
2329
2330
2331
2332
2333
2334
2335
2336
2337
2338
2339
2340
2341
2342
2343
2344
2345
2346
2347
2348
2349
2350
2351
2352
2353
2354
2355
2356
2357
2358
2359
2360
2361
2362
2363
2364
2365
2366
2367
2368
2369
2370
2371
2372
2373
2374
2375
2376
2377
2378
2379
2380
2381
2382
2383
2384
2385
2386
2387
2388
2389
2390
2391
2392
2393
2394
2395
2396
2397
2398
2399
2400
2401
2402
2403
2404
2405
2406
2407
2408
2409
2410
2411
2412
2413
2414
2415
2416
2417
2418
2419
2420
2421
2422
2423
2424
2425
2426
2427
2428
2429
2430
2431
2432
2433
2434
2435
2436
2437
2438
2439
2440
2441
2442
2443
2444
2445
2446
2447
2448
2449
2450
2451
2452
2453
2454
2455
2456
2457
2458
2459
2460
2461
2462
2463
2464
2465
2466
2467
2468
2469
2470
2471
2472
2473
2474
2475
2476
2477
2478
2479
2480
2481
2482
2483
2484
2485
2486
2487
2488
2489
2490
2491
2492
2493
2494
2495
2496
2497
2498
2499
2500
2501
2502
2503
2504
2505
2506
2507
2508
2509
2510
2511
2512
2513
2514
2515
2516
2517
2518
2519
2520
2521
2522
2523
2524
2525
2526
2527
2528
2529
2530
2531
2532
2533
2534
2535
2536
2537
2538
2539
2540
2541
2542
2543
2544
2545
2546
2547
2548
2549
2550
2551
2552
2553
2554
2555
2556
2557
2558
2559
2560
2561
2562
2563
2564
2565
2566
2567
2568
2569
2570
2571
2572
2573
2574
2575
2576
2577
2578
2579
2580
2581
2582
2583
2584
2585
2586
2587
2588
2589
2590
2591
2592
2593
2594
2595
2596
2597
2598
2599
2600
2601
2602
2603
2604
2605
2606
2607
2608
2609
2610
2611
2612
2613
2614
2615
2616
2617
2618
2619
2620
2621
2622
2623
2624
2625
2626
2627
2628
2629
2630
2631
2632
2633
2634
2635
2636
2637
2638
2639
2640
2641
2642
2643
2644
2645
2646
2647
2648
2649
2650
2651
2652
2653
2654
2655
2656
2657
2658
2659
2660
2661
2662
2663
2664
2665
2666
2667
2668
2669
2670
2671
2672
2673
2674
2675
2676
2677
2678
2679
2680
2681
2682
2683
2684
2685
2686
2687
2688
2689
2690
2691
2692
2693
2694
2695
2696
2697
2698
2699
2700
2701
2702
2703
2704
2705
2706
2707
2708
2709
2710
2711
2712
2713
2714
2715
2716
2717
2718
2719
2720
2721
2722
2723
2724
2725
2726
2727
2728
2729
2730
2731
2732
2733
2734
2735
2736
2737
2738
2739
2740
2741
2742
2743
2744
2745
2746
2747
2748
2749
2750
2751
2752
2753
2754
2755
2756
2757
2758
2759
2760
2761
2762
2763
2764
2765
2766
2767
2768
2769
2770
2771
2772
2773
2774
2775
2776
2777
2778
2779
2780
2781
2782
2783
2784
2785
2786
2787
2788
2789
2790
2791
2792
2793
2794
2795
2796
2797
2798
2799
2800
2801
2802
2803
2804
2805
2806
2807
2808
2809
2810
2811
2812
2813
2814
2815
2816
2817
2818
2819
2820
2821
2822
2823
2824
2825
2826
2827
2828
2829
2830
2831
2832
2833
2834
2835
2836
2837
2838
2839
2840
2841
2842
2843
2844
2845
2846
2847
2848
2849
2850
2851
2852
2853
2854
2855
2856
2857
2858
2859
2860
2861
2862
2863
2864
2865
2866
2867
2868
2869
2870
2871
2872
2873
2874
2875
2876
2877
2878
2879
2880
2881
2882
2883
2884
2885
2886
2887
2888
2889
2890
2891
2892
2893
2894
2895
2896
2897
2898
2899
2900
2901
2902
2903
2904
2905
2906
2907
2908
2909
2910
2911
2912
2913
2914
2915
2916
2917
2918
2919
2920
2921
2922
2923
2924
2925
2926
2927
2928
2929
2930
2931
2932
2933
2934
2935
2936
2937
2938
2939
2940
2941
2942
2943
2944
2945
2946
2947
2948
2949
2950
2951
2952
2953
2954
2955
2956
2957
2958
2959
2960
2961
2962
2963
2964
2965
2966
2967
2968
2969
2970
2971
2972
2973
2974
2975
2976
2977
2978
2979
2980
2981
2982
2983
2984
2985
2986
2987
2988
2989
2990
2991
2992
2993
2994
2995
2996
2997
2998
2999
3000
3001
3002
3003
3004
3005
3006
3007
3008
3009
3010
3011
3012
3013
3014
3015
3016
3017
3018
3019
3020
3021
3022
3023
3024
3025
3026
3027
3028
3029
3030
3031
3032
3033
3034
3035
3036
3037
3038
3039
3040
3041
3042
3043
3044
3045
3046
3047
3048
3049
3050
3051
3052
3053
3054
3055
3056
3057
3058
3059
3060
3061
3062
3063
3064
3065
3066
3067
3068
3069
3070
3071
3072
3073
3074
3075
3076
3077
3078
3079
3080
3081
3082
3083
3084
3085
3086
3087
3088
3089
3090
3091
3092
3093
3094
3095
3096
3097
3098
3099
3100
3101
3102
3103
3104
3105
3106
3107
3108
3109
3110
3111
3112
3113
3114
3115
3116
3117
3118
3119
3120
3121
3122
3123
3124
3125
3126
3127
3128
3129
3130
3131
3132
3133
3134
3135
3136
3137
3138
3139
3140
3141
3142
3143
3144
3145
3146
3147
3148
3149
3150
3151
3152
3153
3154
3155
3156
3157
3158
3159
3160
3161
3162
3163
3164
3165
3166
3167
3168
3169
3170
3171
3172
3173
3174
3175
3176
3177
3178
3179
3180
3181
3182
3183
3184
3185
3186
3187
3188
3189
3190
3191
3192
3193
3194
3195
3196
3197
3198
3199
3200
3201
3202
3203
3204
3205
3206
3207
3208
3209
3210
3211
3212
3213
3214
3215
3216
3217
3218
3219
3220
3221
3222
3223
3224
3225
3226
3227
3228
3229
3230
3231
3232
3233
3234
3235
3236
3237
3238
3239
3240
3241
3242
3243
3244
3245
3246
3247
3248
3249
3250
3251
3252
3253
3254
3255
3256
3257
3258
3259
3260
3261
3262
3263
3264
3265
3266
3267
3268
3269
3270
3271
3272
3273
3274
3275
3276
3277
3278
3279
3280
3281
3282
3283
3284
3285
3286
3287
3288
3289
3290
3291
3292
3293
3294
3295
3296
3297
3298
3299
3300
3301
3302
3303
3304
3305
3306
3307
3308
3309
3310
3311
3312
3313
3314
3315
3316
3317
3318
3319
3320
3321
3322
3323
3324
3325
3326
3327
3328
3329
3330
3331
3332
3333
3334
3335
3336
3337
3338
3339
3340
3341
3342
3343
3344
3345
3346
3347
3348
3349
3350
3351
3352
3353
3354
3355
3356
3357
3358
3359
3360
3361
3362
3363
3364
3365
3366
3367
3368
3369
3370
3371
3372
3373
3374
3375
3376
3377
3378
3379
3380
3381
3382
3383
3384
3385
3386
3387
3388
3389
3390
3391
3392
3393
3394
3395
3396
3397
3398
3399
3400
3401
3402
3403
3404
3405
3406
3407
3408
3409
3410
3411
3412
3413
3414
3415
3416
3417
3418
3419
3420
3421
3422
3423
3424
3425
3426
3427
3428
3429
3430
3431
3432
3433
3434
3435
3436
3437
3438
3439
3440
3441
3442
3443
3444
3445
3446
3447
3448
3449
3450
3451
3452
3453
3454
3455
3456
3457
3458
3459
3460
3461
3462
3463
3464
3465
3466
3467
3468
3469
3470
3471
3472
3473
3474
3475
3476
3477
3478
3479
3480
3481
3482
3483
3484
3485
3486
3487
3488
3489
3490
3491
3492
3493
3494
3495
3496
3497
3498
3499
3500
3501
3502
3503
3504
3505
3506
3507
3508
3509
3510
3511
3512
3513
3514
3515
3516
3517
3518
3519
3520
3521
3522
3523
3524
3525
3526
3527
3528
3529
3530
3531
3532
3533
3534
3535
3536
3537
3538
3539
3540
3541
3542
3543
3544
3545
3546
3547
3548
3549
3550
3551
3552
3553
3554
3555
3556
3557
3558
3559
3560
3561
3562
3563
3564
3565
3566
3567
3568
3569
3570
3571
3572
3573
3574
3575
3576
3577
3578
3579
3580
3581
3582
3583
3584
3585
3586
3587
3588
3589
3590
3591
3592
3593
3594
3595
3596
3597
3598
3599
3600
3601
3602
3603
3604
3605
3606
3607
3608
3609
3610
3611
3612
3613
3614
3615
3616
3617
3618
3619
3620
3621
3622
3623
3624
3625
3626
3627
3628
3629
3630
3631
3632
3633
3634
3635
3636
3637
3638
3639
3640
3641
3642
3643
3644
3645
3646
3647
3648
3649
3650
3651
3652
3653
3654
3655
3656
3657
3658
3659
3660
3661
3662
3663
3664
3665
3666
3667
3668
3669
3670
3671
3672
3673
3674
3675
3676
3677
3678
3679
3680
3681
3682
3683
3684
3685
3686
3687
3688
3689
3690
3691
3692
3693
3694
3695
3696
3697
3698
3699
3700
3701
3702
3703
3704
3705
3706
3707
3708
3709
3710
3711
3712
3713
3714
3715
3716
3717
3718
3719
3720
3721
3722
3723
3724
3725
3726
3727
3728
3729
3730
3731
3732
3733
3734
3735
3736
3737
3738
3739
3740
3741
3742
3743
3744
3745
3746
3747
3748
3749
3750
3751
3752
3753
3754
3755
3756
3757
3758
3759
3760
3761
3762
3763
3764
3765
3766
3767
3768
3769
3770
3771
3772
3773
3774
3775
3776
3777
3778
3779
3780
3781
3782
3783
3784
3785
3786
3787
3788
3789
3790
3791
3792
3793
3794
3795
3796
3797
3798
3799
3800
3801
3802
3803
3804
3805
3806
3807
3808
3809
3810
3811
3812
3813
3814
3815
3816
3817
3818
3819
3820
3821
3822
3823
3824
3825
3826
3827
3828
3829
3830
3831
3832
3833
3834
3835
3836
3837
3838
3839
3840
3841
3842
3843
3844
3845
3846
3847
3848
3849
3850
3851
3852
3853
3854
3855
3856
3857
3858
3859
3860
3861
3862
3863
3864
3865
3866
3867
3868
3869
3870
3871
3872
3873
3874
3875
3876
3877
3878
3879
3880
3881
3882
3883
3884
3885
3886
3887
3888
3889
3890
3891
3892
3893
3894
3895
3896
3897
3898
3899
3900
3901
3902
3903
3904
3905
3906
3907
3908
3909
3910
3911
3912
3913
3914
3915
3916
3917
3918
3919
3920
3921
3922
3923
3924
3925
3926
3927
3928
3929
3930
3931
3932
3933
3934
3935
3936
3937
3938
3939
3940
3941
3942
3943
3944
3945
3946
3947
3948
3949
3950
3951
3952
3953
3954
3955
3956
3957
3958
3959
3960
3961
3962
3963
3964
3965
3966
3967
3968
3969
3970
3971
3972
3973
3974
3975
3976
3977
3978
3979
3980
3981
3982
3983
3984
3985
3986
3987
3988
3989
3990
3991
3992
3993
3994
3995
3996
3997
3998
3999
4000
4001
4002
4003
4004
4005
4006
4007
4008
4009
4010
4011
4012
4013
4014
4015
4016
4017
4018
4019
4020
4021
4022
4023
4024
4025
4026
4027
4028
4029
4030
4031
4032
4033
4034
4035
4036
4037
4038
4039
4040
4041
4042
4043
4044
4045
4046
4047
4048
4049
4050
4051
4052
4053
4054
4055
4056
4057
4058
4059
4060
4061
4062
4063
4064
4065
4066
4067
4068
4069
4070
4071
4072
4073
4074
4075
4076
4077
4078
4079
4080
4081
4082
4083
4084
4085
4086
4087
4088
4089
4090
4091
4092
4093
4094
4095
4096
4097
4098
4099
4100
4101
4102
4103
4104
4105
4106
4107
4108
4109
4110
4111
4112
4113
4114
4115
4116
4117
4118
4119
4120
4121
4122
4123
4124
4125
4126
4127
4128
4129
4130
4131
4132
4133
4134
4135
4136
4137
4138
4139
4140
4141
4142
4143
4144
4145
4146
4147
4148
4149
4150
4151
4152
4153
4154
4155
4156
4157
4158
4159
4160
4161
4162
4163
4164
4165
4166
4167
4168
4169
4170
4171
4172
4173
4174
4175
4176
4177
4178
4179
4180
4181
4182
4183
4184
4185
4186
4187
4188
4189
4190
4191
4192
4193
4194
4195
4196
4197
4198
4199
4200
4201
4202
4203
4204
4205
4206
4207
4208
4209
4210
4211
4212
4213
4214
4215
4216
4217
4218
4219
4220
4221
4222
4223
4224
4225
4226
4227
4228
4229
4230
4231
4232
4233
4234
4235
4236
4237
4238
4239
4240
4241
4242
4243
4244
4245
4246
4247
4248
4249
4250
4251
4252
4253
4254
4255
4256
4257
4258
4259
4260
4261
4262
4263
4264
4265
4266
4267
4268
4269
4270
4271
4272
4273
4274
4275
4276
4277
4278
4279
4280
4281
4282
4283
4284
4285
4286
4287
4288
4289
4290
4291
4292
4293
4294
4295
4296
4297
4298
4299
4300
4301
4302
4303
4304
4305
4306
4307
4308
4309
4310
4311
4312
4313
4314
4315
4316
4317
4318
4319
4320
4321
4322
4323
4324
4325
4326
4327
4328
4329
4330
4331
4332
4333
4334
4335
4336
4337
4338
4339
4340
4341
4342
4343
4344
4345
4346
4347
4348
4349
4350
4351
4352
4353
4354
4355
4356
4357
4358
4359
4360
4361
4362
4363
4364
4365
4366
4367
4368
4369
4370
4371
4372
4373
4374
4375
4376
4377
4378
4379
4380
4381
4382
4383
4384
4385
4386
4387
4388
4389
4390
4391
4392
4393
4394
4395
4396
4397
4398
4399
4400
4401
4402
4403
4404
4405
4406
4407
4408
4409
4410
4411
4412
4413
4414
4415
4416
4417
4418
4419
4420
4421
4422
4423
4424
4425
4426
4427
4428
4429
4430
4431
4432
4433
4434
4435
4436
4437
4438
4439
4440
4441
4442
4443
4444
4445
4446
4447
4448
4449
4450
4451
4452
4453
4454
4455
4456
4457
4458
4459
4460
4461
4462
4463
4464
4465
4466
4467
4468
4469
4470
4471
4472
4473
4474
4475
4476
4477
4478
4479
4480
4481
4482
4483
4484
4485
4486
4487
4488
4489
4490
4491
4492
4493
4494
4495
4496
4497
4498
4499
4500
4501
4502
4503
4504
4505
4506
4507
4508
4509
4510
4511
4512
4513
4514
4515
4516
4517
4518
4519
4520
4521
4522
4523
4524
4525
4526
4527
4528
4529
4530
4531
4532
4533
4534
4535
4536
4537
4538
4539
4540
4541
4542
4543
4544
4545
4546
4547
4548
4549
4550
4551
4552
4553
4554
4555
4556
4557
4558
4559
4560
4561
4562
4563
4564
4565
4566
4567
4568
4569
4570
4571
4572
4573
4574
4575
4576
4577
4578
4579
4580
4581
4582
4583
4584
4585
4586
4587
4588
4589
4590
4591
4592
4593
4594
4595
4596
4597
4598
4599
4600
4601
4602
4603
4604
4605
4606
4607
4608
4609
4610
4611
4612
4613
4614
4615
4616
4617
4618
4619
4620
4621
4622
4623
4624
4625
4626
4627
4628
4629
4630
4631
4632
4633
4634
4635
4636
4637
4638
4639
4640
4641
4642
4643
4644
4645
4646
4647
4648
4649
4650
4651
4652
4653
4654
4655
4656
4657
4658
4659
4660
4661
4662
4663
4664
4665
4666
4667
4668
4669
4670
4671
4672
4673
4674
4675
4676
4677
4678
4679
4680
4681
4682
4683
4684
4685
4686
4687
4688
4689
4690
4691
4692
4693
4694
4695
4696
4697
4698
4699
4700
4701
4702
4703
4704
4705
4706
4707
4708
4709
4710
4711
4712
4713
4714
4715
4716
4717
4718
4719
4720
4721
4722
4723
4724
4725
4726
4727
4728
4729
4730
4731
4732
4733
4734
4735
4736
4737
4738
4739
4740
4741
4742
4743
4744
4745
4746
4747
4748
4749
4750
4751
4752
4753
4754
4755
4756
4757
4758
4759
4760
4761
4762
4763
4764
4765
4766
4767
4768
4769
4770
4771
4772
4773
4774
4775
4776
4777
4778
4779
4780
4781
4782
4783
4784
4785
4786
4787
4788
4789
4790
4791
4792
4793
4794
4795
4796
4797
4798
4799
4800
4801
4802
4803
4804
4805
4806
4807
4808
4809
4810
4811
4812
4813
4814
4815
4816
4817
4818
4819
4820
4821
4822
4823
4824
4825
4826
4827
4828
4829
4830
4831
4832
4833
4834
4835
4836
4837
4838
4839
4840
4841
4842
4843
4844
4845
4846
4847
4848
4849
4850
4851
4852
4853
4854
4855
4856
4857
4858
4859
4860
4861
4862
4863
4864
4865
4866
4867
4868
4869
4870
4871
4872
4873
4874
4875
4876
4877
4878
4879
4880
4881
4882
4883
4884
4885
4886
4887
4888
4889
4890
4891
4892
4893
4894
4895
4896
4897
4898
4899
4900
4901
4902
4903
4904
4905
4906
4907
4908
4909
4910
4911
4912
4913
4914
4915
4916
4917
4918
4919
4920
4921
4922
4923
4924
4925
4926
4927
4928
4929
4930
4931
4932
4933
4934
4935
4936
4937
4938
4939
4940
4941
4942
4943
4944
4945
4946
4947
4948
4949
4950
4951
4952
4953
4954
4955
4956
4957
4958
4959
4960
4961
4962
4963
4964
4965
4966
4967
4968
4969
4970
4971
4972
4973
4974
4975
4976
4977
4978
4979
4980
4981
4982
4983
4984
4985
4986
4987
4988
4989
4990
4991
4992
4993
4994
4995
4996
4997
4998
4999
5000
5001
5002
5003
5004
5005
5006
5007
5008
5009
5010
5011
5012
5013
5014
5015
5016
5017
5018
5019
5020
5021
5022
5023
5024
5025
5026
5027
5028
5029
5030
5031
5032
5033
5034
5035
5036
5037
5038
5039
5040
5041
5042
5043
5044
5045
5046
5047
5048
5049
5050
5051
5052
5053
5054
5055
5056
5057
5058
5059
5060
5061
5062
5063
5064
5065
5066
5067
5068
5069
5070
5071
5072
5073
5074
5075
5076
5077
5078
5079
5080
5081
5082
5083
5084
5085
5086
5087
5088
5089
5090
5091
5092
5093
5094
5095
5096
5097
5098
5099
5100
5101
5102
5103
5104
5105
5106
5107
5108
5109
5110
5111
5112
5113
5114
5115
5116
5117
5118
5119
5120
5121
5122
5123
5124
5125
5126
5127
5128
5129
5130
5131
5132
5133
5134
5135
5136
5137
5138
5139
5140
5141
5142
5143
5144
5145
5146
5147
5148
5149
5150
5151
5152
5153
5154
5155
5156
5157
5158
5159
5160
5161
5162
5163
5164
5165
5166
5167
5168
5169
5170
5171
5172
5173
5174
5175
5176
5177
5178
5179
5180
5181
5182
5183
5184
5185
5186
5187
5188
5189
5190
5191
5192
5193
5194
5195
5196
5197
5198
5199
5200
5201
5202
5203
5204
5205
5206
5207
5208
5209
5210
5211
5212
5213
5214
5215
5216
5217
5218
5219
5220
5221
5222
5223
5224
5225
5226
5227
5228
5229
5230
5231
5232
5233
5234
5235
5236
5237
5238
5239
5240
5241
5242
5243
5244
5245
5246
5247
5248
5249
5250
5251
5252
5253
5254
5255
5256
5257
5258
5259
5260
5261
5262
5263
5264
5265
5266
5267
5268
5269
5270
5271
5272
5273
5274
5275
5276
5277
5278
5279
5280
5281
5282
5283
5284
5285
5286
5287
5288
5289
5290
5291
5292
5293
5294
5295
5296
5297
5298
5299
5300
5301
5302
5303
5304
5305
5306
5307
5308
5309
5310
5311
5312
5313
5314
5315
5316
5317
5318
5319
5320
5321
5322
5323
5324
5325
5326
5327
5328
5329
5330
5331
5332
5333
5334
5335
5336
5337
5338
5339
5340
5341
5342
5343
5344
5345
5346
5347
5348
5349
5350
5351
5352
5353
5354
5355
5356
5357
5358
5359
5360
5361
5362
5363
5364
5365
5366
5367
5368
5369
5370
5371
5372
5373
5374
5375
5376
5377
5378
5379
5380
5381
5382
5383
5384
5385
5386
5387
5388
5389
5390
5391
5392
5393
5394
5395
5396
5397
5398
5399
5400
5401
5402
5403
5404
5405
5406
5407
5408
5409
5410
5411
5412
5413
5414
5415
5416
5417
5418
5419
5420
5421
5422
5423
5424
5425
5426
5427
5428
5429
5430
5431
5432
5433
5434
5435
5436
5437
5438
5439
5440
5441
5442
5443
5444
5445
5446
5447
5448
5449
5450
5451
5452
5453
5454
5455
5456
5457
5458
5459
5460
5461
5462
5463
5464
5465
5466
5467
5468
5469
5470
5471
5472
5473
5474
5475
5476
5477
5478
5479
5480
5481
5482
5483
5484
5485
5486
5487
5488
5489
5490
5491
5492
5493
5494
5495
5496
5497
5498
5499
5500
5501
5502
5503
5504
5505
5506
5507
5508
5509
5510
5511
5512
5513
5514
5515
5516
5517
5518
5519
5520
5521
5522
5523
5524
5525
5526
5527
5528
5529
5530
5531
5532
5533
5534
5535
5536
5537
5538
5539
5540
5541
5542
5543
5544
5545
5546
5547
5548
5549
5550
5551
5552
5553
5554
5555
5556
5557
5558
5559
5560
5561
5562
5563
5564
5565
5566
5567
5568
5569
5570
5571
5572
5573
5574
5575
5576
5577
5578
5579
5580
5581
5582
5583
5584
5585
5586
5587
5588
5589
5590
5591
5592
5593
5594
5595
5596
5597
5598
5599
5600
5601
5602
5603
5604
5605
5606
5607
5608
5609
5610
5611
5612
5613
5614
5615
5616
5617
5618
5619
5620
5621
5622
5623
5624
5625
5626
5627
5628
5629
5630
5631
5632
5633
5634
5635
5636
5637
5638
5639
5640
5641
5642
5643
5644
5645
5646
5647
5648
5649
5650
5651
5652
5653
5654
5655
5656
5657
5658
5659
5660
5661
5662
5663
5664
5665
5666
5667
5668
5669
5670
5671
5672
5673
5674
5675
5676
5677
5678
5679
5680
5681
5682
5683
5684
5685
5686
5687
5688
5689
5690
5691
5692
5693
5694
5695
5696
5697
5698
5699
5700
5701
5702
5703
5704
5705
5706
5707
5708
5709
5710
5711
5712
5713
5714
5715
5716
5717
5718
5719
5720
5721
5722
5723
5724
5725
5726
5727
5728
5729
5730
5731
5732
5733
5734
5735
5736
5737
5738
5739
5740
5741
5742
5743
5744
5745
5746
5747
5748
5749
5750
5751
5752
5753
5754
5755
5756
5757
5758
5759
5760
5761
5762
5763
5764
5765
5766
5767
5768
5769
5770
5771
5772
5773
5774
5775
5776
5777
5778
5779
5780
5781
5782
5783
5784
5785
5786
5787
5788
5789
5790
5791
5792
5793
5794
5795
5796
5797
5798
5799
5800
5801
5802
5803
5804
5805
5806
5807
5808
5809
5810
5811
5812
5813
5814
5815
5816
5817
5818
5819
5820
5821
5822
5823
5824
5825
5826
5827
5828
5829
5830
5831
5832
5833
5834
5835
5836
5837
5838
5839
5840
5841
5842
5843
5844
5845
5846
5847
5848
5849
5850
5851
5852
5853
5854
5855
5856
5857
5858
5859
5860
5861
5862
5863
5864
5865
5866
5867
5868
5869
5870
5871
5872
5873
5874
5875
5876
5877
5878
5879
5880
5881
5882
5883
5884
5885
5886
5887
5888
5889
5890
5891
5892
5893
5894
5895
5896
5897
5898
5899
5900
5901
5902
5903
5904
5905
5906
5907
5908
5909
5910
5911
5912
5913
5914
5915
5916
5917
5918
5919
5920
5921
5922
5923
5924
5925
5926
5927
5928
5929
5930
5931
5932
5933
5934
5935
5936
5937
5938
5939
5940
5941
5942
5943
5944
5945
5946
5947
5948
5949
5950
5951
5952
5953
5954
5955
5956
5957
5958
5959
5960
5961
5962
5963
5964
5965
5966
5967
5968
5969
5970
5971
5972
5973
5974
5975
5976
5977
5978
5979
5980
5981
5982
5983
5984
5985
5986
5987
5988
5989
5990
5991
5992
5993
5994
5995
5996
5997
5998
5999
6000
6001
6002
6003
6004
6005
6006
6007
6008
6009
6010
6011
6012
6013
6014
6015
6016
6017
6018
6019
6020
6021
6022
6023
6024
6025
6026
6027
6028
6029
6030
6031
6032
6033
6034
6035
6036
6037
6038
6039
6040
6041
6042
6043
6044
6045
6046
6047
6048
6049
6050
6051
6052
6053
6054
6055
6056
6057
6058
6059
6060
6061
6062
6063
6064
6065
6066
6067
6068
6069
6070
6071
6072
6073
6074
6075
6076
6077
6078
6079
6080
6081
6082
6083
6084
6085
6086
6087
6088
6089
6090
6091
6092
6093
6094
6095
6096
6097
6098
6099
6100
6101
6102
6103
6104
6105
6106
6107
6108
6109
6110
6111
6112
6113
6114
6115
6116
6117
6118
6119
6120
6121
6122
6123
6124
6125
6126
6127
6128
6129
6130
6131
6132
6133
6134
6135
6136
6137
6138
6139
6140
6141
6142
6143
6144
6145
6146
6147
6148
6149
6150
6151
6152
6153
6154
6155
6156
6157
6158
6159
6160
6161
6162
6163
6164
6165
6166
6167
6168
6169
6170
6171
6172
6173
6174
6175
6176
6177
6178
6179
6180
6181
6182
6183
6184
6185
6186
6187
6188
6189
6190
6191
6192
6193
6194
|
.. date: 2022-09-28-17-09-37
.. gh-issue: 97616
.. nonce: K1e3Xs
.. release date: 2022-10-25
.. section: Security
Fix multiplying a list by an integer (``list *= int``): detect the integer
overflow when the new allocated length is close to the maximum size. Issue
reported by Jordan Limor. Patch by Victor Stinner.
..
.. date: 2022-09-07-10-42-00
.. gh-issue: 97514
.. nonce: Yggdsl
.. section: Security
On Linux the :mod:`multiprocessing` module returns to using filesystem
backed unix domain sockets for communication with the *forkserver* process
instead of the Linux abstract socket namespace. Only code that chooses to
use the :ref:`"forkserver" start method <multiprocessing-start-methods>` is
affected.
Abstract sockets have no permissions and could allow any user on the system
in the same `network namespace
<https://man7.org/linux/man-pages/man7/network_namespaces.7.html>`_ (often
the whole system) to inject code into the multiprocessing *forkserver*
process. This was a potential privilege escalation. Filesystem based socket
permissions restrict this to the *forkserver* process user as was the
default in Python 3.8 and earlier.
This prevents Linux `CVE-2022-42919
<https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2022-42919>`_.
..
.. date: 2022-06-15-20-09-23
.. gh-issue: 87389
.. nonce: QVaC3f
.. section: Security
:mod:`http.server`: Fix an open redirection vulnerability in the HTTP server
when an URI path starts with ``//``. Vulnerability discovered, and initial
fix proposed, by Hamza Avvan.
..
.. date: 2022-06-03-12-52-53
.. gh-issue: 79096
.. nonce: YVoxgC
.. section: Security
LWPCookieJar and MozillaCookieJar create files with file mode 600 instead of
644 (Microsoft Windows is not affected)
..
.. date: 2022-05-19-08-53-07
.. gh-issue: 92888
.. nonce: TLtR9W
.. section: Security
Fix ``memoryview`` use after free when accessing the backing buffer in
certain cases.
..
.. date: 2022-04-27-18-25-30
.. gh-issue: 68966
.. nonce: gjS8zs
.. section: Security
The deprecated mailcap module now refuses to inject unsafe text (filenames,
MIME types, parameters) into shell commands. Instead of using such text, it
will warn and act as if a match was not found (or for test commands, as if
the test failed).
..
.. date: 2022-10-19-23-48-46
.. gh-issue: 98374
.. nonce: eOBh8M
.. section: Core and Builtins
Suppress ImportError for invalid query for help() command. Patch by Dong-hee
Na.
..
.. date: 2022-10-19-20-53-38
.. gh-issue: 98461
.. nonce: iNmPDV
.. section: Core and Builtins
Fix source location in bytecode for list, set and dict comprehensions as
well as generator expressions.
..
.. date: 2022-10-19-18-03-28
.. gh-issue: 98354
.. nonce: GRGta3
.. section: Core and Builtins
Added unicode check for ``name`` attribute of ``spec`` argument passed in
:func:`_imp.create_builtin` function.
..
.. date: 2022-10-18-16-17-44
.. gh-issue: 98398
.. nonce: x4rYK_
.. section: Core and Builtins
Fix source location of 'assert' bytecodes.
..
.. date: 2022-10-18-14-11-32
.. gh-issue: 98390
.. nonce: H1sxJu
.. section: Core and Builtins
Fix location of sub-expressions of boolean expressions, by reducing their
scope to that of the sub-expression.
..
.. date: 2022-10-13-23-23-01
.. gh-issue: 98254
.. nonce: bC8IKt
.. section: Core and Builtins
Modules from the standard library are now potentially suggested as part of
the error messages displayed by the interpreter when an :exc:`NameError` is
raised to the top level. Patch by Pablo Galindo
..
.. date: 2022-10-06-23-13-34
.. gh-issue: 97997
.. nonce: JQaJKF
.. section: Core and Builtins
Add running column offset to the tokenizer state to avoid calculating AST
column information with pointer arithmetic.
..
.. date: 2022-10-06-20-41-29
.. gh-issue: 97973
.. nonce: gB-xWi
.. section: Core and Builtins
Modify the tokenizer to return all necessary information the parser needs to
set location information in the AST nodes, so that the parser does not have
to calculate those doing pointer arithmetic.
..
.. date: 2022-10-06-15-45-57
.. gh-issue: 96078
.. nonce: fS-6mU
.. section: Core and Builtins
:func:`os.sched_yield` now release the GIL while calling sched_yield(2).
Patch by Dong-hee Na.
..
.. date: 2022-10-06-14-14-28
.. gh-issue: 97955
.. nonce: Nq5VXD
.. section: Core and Builtins
Migrate :mod:`zoneinfo` to Argument Clinic.
..
.. date: 2022-10-06-06-36-29
.. gh-issue: 97912
.. nonce: jGRJpa
.. section: Core and Builtins
The compiler now avoids quadratic behavior when finding which instructions
should use the :opcode:`LOAD_FAST_CHECK` opcode.
..
.. date: 2022-10-06-02-11-34
.. gh-issue: 97002
.. nonce: Zvsk71
.. section: Core and Builtins
Fix an issue where several frame objects could be backed by the same
interpreter frame, possibly leading to corrupted memory and hard crashes of
the interpreter.
..
.. date: 2022-10-05-17-02-22
.. gh-issue: 97943
.. nonce: LYAWlE
.. section: Core and Builtins
Bugfix: :func:`PyFunction_GetAnnotations` should return a borrowed
reference. It was returning a new reference.
..
.. date: 2022-10-05-11-37-15
.. gh-issue: 97922
.. nonce: Zu9Bge
.. section: Core and Builtins
The Garbage Collector now runs only on the eval breaker mechanism of the
Python bytecode evaluation loop instead on object allocations. The GC can
also run when :c:func:`PyErr_CheckSignals` is called so C extensions that
need to run for a long time without executing any Python code also have a
chance to execute the GC periodically.
..
.. date: 2022-10-05-00-37-27
.. gh-issue: 65961
.. nonce: z0Ys0y
.. section: Core and Builtins
When ``__package__`` is different than ``__spec__.parent``, raise a
``DeprecationWarning`` instead of ``ImportWarning``.
Also remove ``importlib.util.set_package()`` which was scheduled for
removal.
..
.. date: 2022-10-04-17-02-18
.. gh-issue: 97850
.. nonce: E3QTRA
.. section: Core and Builtins
Long deprecated, ``module_repr()`` should now be completely eradicated.
..
.. date: 2022-10-04-14-04-40
.. gh-issue: 86298
.. nonce: QVM7G1
.. section: Core and Builtins
In cases where ``warnings.warn_explicit()`` consults the module's loader, an
``DeprecationWarning`` is issued when ``m.__loader__`` differs from
``m.__spec__.loader``.
..
.. date: 2022-10-04-02-00-10
.. gh-issue: 97779
.. nonce: f3N1hI
.. section: Core and Builtins
Ensure that all Python frame objects are backed by "complete" frames.
..
.. date: 2022-10-03-16-12-39
.. gh-issue: 91052
.. nonce: MsYL9d
.. section: Core and Builtins
Add API for subscribing to modification events on selected dictionaries.
..
.. date: 2022-10-03-13-35-48
.. gh-issue: 97752
.. nonce: 0xTjJY
.. section: Core and Builtins
Fix possible data corruption or crashes when accessing the ``f_back`` member
of newly-created generator or coroutine frames.
..
.. date: 2022-10-01-08-55-09
.. gh-issue: 97591
.. nonce: pw6kkH
.. section: Core and Builtins
Fixed a missing incref/decref pair in ``Exception.__setstate__()``. Patch by
Ofey Chan.
..
.. date: 2022-09-30-13-26-58
.. gh-issue: 97670
.. nonce: n61vMR
.. section: Core and Builtins
Remove the :func:`sys.getdxp` function and the
``Tools/scripts/analyze_dxp.py`` script. DXP stands for "dynamic execution
pairs". They were related to ``DYNAMIC_EXECUTION_PROFILE`` and ``DXPAIRS``
macros which have been removed in Python 3.11. Python can now be built with
:option:`./configure --enable-pystats <--enable-pystats>` to gather
statistics on Python opcodes. Patch by Victor Stinner.
..
.. date: 2022-09-29-15-19-29
.. gh-issue: 94526
.. nonce: wq5m6T
.. section: Core and Builtins
Fix the Python path configuration used to initialized :data:`sys.path` at
Python startup. Paths are no longer encoded to UTF-8/strict to avoid
encoding errors if it contains surrogate characters (bytes paths are decoded
with the surrogateescape error handler). Patch by Victor Stinner.
..
.. date: 2022-09-27-11-59-13
.. gh-issue: 96670
.. nonce: XrBBit
.. section: Core and Builtins
The parser now raises :exc:`SyntaxError` when parsing source code containing
null bytes. Patch by Pablo Galindo
..
.. date: 2022-09-21-16-06-37
.. gh-issue: 96975
.. nonce: BmE0XY
.. section: Core and Builtins
Fix a crash occurring when :c:func:`PyEval_GetFrame` is called while the
topmost Python frame is in a partially-initialized state.
..
.. date: 2022-09-21-14-38-31
.. gh-issue: 96848
.. nonce: WuoLzU
.. section: Core and Builtins
Fix command line parsing: reject :option:`-X int_max_str_digits <-X>` option
with no value (invalid) when the :envvar:`PYTHONINTMAXSTRDIGITS` environment
variable is set to a valid limit. Patch by Victor Stinner.
..
.. date: 2022-09-20-11-06-45
.. gh-issue: 95921
.. nonce: dkcRQn
.. section: Core and Builtins
Fix overly-broad source position information for chained comparisons used as
branching conditions.
..
.. date: 2022-09-19-03-35-01
.. gh-issue: 96821
.. nonce: izK6JA
.. section: Core and Builtins
Fix undefined behaviour in ``audioop.c``.
..
.. date: 2022-09-18-08-47-40
.. gh-issue: 96821
.. nonce: Co2iOq
.. section: Core and Builtins
Fix undefined behaviour in ``_testcapimodule.c``.
..
.. date: 2022-09-16-19-02-40
.. gh-issue: 95778
.. nonce: cJmnst
.. section: Core and Builtins
When :exc:`ValueError` is raised if an integer is larger than the limit,
mention the :func:`sys.set_int_max_str_digits` function in the error
message. Patch by Victor Stinner.
..
.. date: 2022-09-16-16-54-35
.. gh-issue: 96387
.. nonce: GRzewg
.. section: Core and Builtins
At Python exit, sometimes a thread holding the GIL can wait forever for a
thread (usually a daemon thread) which requested to drop the GIL, whereas
the thread already exited. To fix the race condition, the thread which
requested the GIL drop now resets its request before exiting. Issue
discovered and analyzed by Mingliang ZHAO. Patch by Victor Stinner.
..
.. date: 2022-09-16-12-36-13
.. gh-issue: 96864
.. nonce: PLU3i8
.. section: Core and Builtins
Fix a possible assertion failure, fatal error, or :exc:`SystemError` if a
line tracing event raises an exception while opcode tracing is enabled.
..
.. date: 2022-09-13-21-45-07
.. gh-issue: 95778
.. nonce: Oll4_5
.. section: Core and Builtins
The ``PyLong_FromString`` function was refactored to make it more
maintainable and extensible.
..
.. date: 2022-09-13-12-06-46
.. gh-issue: 96678
.. nonce: NqGFyb
.. section: Core and Builtins
Fix undefined behaviour in C code of null pointer arithmetic.
..
.. date: 2022-09-12-16-58-22
.. gh-issue: 96754
.. nonce: 0GRme5
.. section: Core and Builtins
Make sure that all frame objects created are created from valid interpreter
frames. Prevents the possibility of invalid frames in backtraces and signal
handlers.
..
.. date: 2022-09-12-15-15-04
.. gh-issue: 90997
.. nonce: sZO8c9
.. section: Core and Builtins
Improve the performance of reading and writing inline bytecode caches on
some platforms.
..
.. date: 2022-09-11-12-43-43
.. gh-issue: 96751
.. nonce: anRT6a
.. section: Core and Builtins
Remove dead code from ``CALL_FUNCTION_EX`` opcode.
..
.. date: 2022-09-11-00-37-50
.. gh-issue: 90751
.. nonce: VE8-zf
.. section: Core and Builtins
:class:`memoryview` now supports half-floats. Patch by Dong-hee Na and
Antoine Pitrou.
..
.. date: 2022-09-09-13-13-27
.. gh-issue: 96678
.. nonce: vMxi9F
.. section: Core and Builtins
Fix case of undefined behavior in ceval.c
..
.. date: 2022-09-08-20-58-10
.. gh-issue: 64373
.. nonce: AfCi36
.. section: Core and Builtins
Convert :mod:`_functools` to argument clinic.
..
.. date: 2022-09-07-13-38-37
.. gh-issue: 96641
.. nonce: wky0Fc
.. section: Core and Builtins
Do not expose ``KeyWrapper`` in :mod:`_functools`.
..
.. date: 2022-09-07-12-02-11
.. gh-issue: 96636
.. nonce: YvN-K6
.. section: Core and Builtins
Ensure that tracing, ``sys.setrace()``, is turned on immediately. In
pre-release versions of 3.11, some tracing events might have been lost when
turning on tracing in a ``__del__`` method or interrupt.
..
.. date: 2022-09-06-16-54-49
.. gh-issue: 96572
.. nonce: 8DRsaW
.. section: Core and Builtins
Fix use after free in trace refs build mode. Patch by Kumar Aditya.
..
.. date: 2022-09-06-16-22-13
.. gh-issue: 96611
.. nonce: 14wIX8
.. section: Core and Builtins
When loading a file with invalid UTF-8 inside a multi-line string, a correct
SyntaxError is emitted.
..
.. date: 2022-09-06-14-26-36
.. gh-issue: 96612
.. nonce: P4ZbeY
.. section: Core and Builtins
Make sure that incomplete frames do not show up in tracemalloc traces.
..
.. date: 2022-09-06-11-19-03
.. gh-issue: 90230
.. nonce: YOtzs5
.. section: Core and Builtins
Fix compiler warnings and test failures when building with
``--enable-pystats``.
..
.. date: 2022-09-05-19-20-44
.. gh-issue: 96587
.. nonce: bVxhX2
.. section: Core and Builtins
Correctly raise ``SyntaxError`` on exception groups (:pep:`654`) on python
versions prior to 3.11
..
.. date: 2022-09-05-16-43-44
.. gh-issue: 96569
.. nonce: 9lmTCC
.. section: Core and Builtins
Remove two cases of undefined behavoir, by adding NULL checks.
..
.. date: 2022-09-05-15-07-25
.. gh-issue: 96582
.. nonce: HEsL5s
.. section: Core and Builtins
Fix possible ``NULL`` pointer dereference in ``_PyThread_CurrentFrames``.
Patch by Kumar Aditya.
..
.. date: 2022-09-05-09-56-32
.. gh-issue: 91079
.. nonce: H4-DdU
.. section: Core and Builtins
Separate Python recursion checking from C recursion checking which reduces
the chance of C stack overflow and allows the recursion limit to be
increased safely.
..
.. date: 2022-09-02-16-47-52
.. gh-issue: 93911
.. nonce: vF-GWe
.. section: Core and Builtins
Fix an issue that could prevent :opcode:`LOAD_ATTR` from specializing
properly when accessing properties.
..
.. date: 2022-08-31-18-46-13
.. gh-issue: 96348
.. nonce: xzCoTP
.. section: Core and Builtins
Emit a DeprecationWarning when :meth:`~generator.throw`,
:meth:`~coroutine.throw` or :meth:`~agen.athrow` are called with more than
one argument.
..
.. date: 2022-08-29-13-06-58
.. gh-issue: 95196
.. nonce: eGRR4b
.. section: Core and Builtins
Disable incorrect pickling of the C implemented classmethod descriptors.
..
.. date: 2022-08-29-00-37-21
.. gh-issue: 96364
.. nonce: c-IVyb
.. section: Core and Builtins
Fix text signatures of ``list.__getitem__`` and ``dict.__getitem__``.
..
.. date: 2022-08-28-10-51-19
.. gh-issue: 96352
.. nonce: jTLD2d
.. section: Core and Builtins
Fix :exc:`AttributeError` missing ``name`` and ``obj`` attributes in
:meth:`object.__getattribute__`. Patch by Philip Georgi.
..
.. date: 2022-08-26-18-46-32
.. gh-issue: 93554
.. nonce: QEaCcK
.. section: Core and Builtins
Change the jump opcodes so that all conditional jumps are forward jumps.
Backward jumps are converted by the assembler into a conditional forward
jump whose target is the fallthrough block (and with a reversed condition),
followed by an unconditional backward jump. For example:
``POP_JUMP_IF_TRUE BACKWARD_TARGET`` becomes ``POP_JUMP_IF_FALSE NEXT_BLOCK;
JUMP BACKWARD_TARGET``.
All the directed conditional jump opcodes were removed:
``POP_JUMP_FORWARD_IF_TRUE``, ``POP_JUMP_BACKWARD_IF_TRUE``,
``POP_JUMP_FORWARD_IF_FALSE``, ``POP_JUMP_BACKWARD_IF_FALSE``,
``POP_JUMP_FORWARD_IF_NONE``, ``POP_JUMP_BACKWARD_IF_NONE``,
``POP_JUMP_FORWARD_IF_NOT_NONE``, ``POP_JUMP_BACKWARD_IF_NOT_NONE``.
The corresponding opcodes without direction are no longer
pseudo-instructions, and they implement the forward conditional jumps.
..
.. date: 2022-08-25-10-19-34
.. gh-issue: 96268
.. nonce: AbYrLB
.. section: Core and Builtins
Loading a file with invalid UTF-8 will now report the broken character at
the correct location.
..
.. date: 2022-08-24-14-30-26
.. gh-issue: 96237
.. nonce: msif5f
.. section: Core and Builtins
The internal field ``_PyInterpreterFrame.f_func`` is renamed to
``_PyInterpreterFrame.f_funcobj`` and may be any object. The ``f_globals``
and ``f_builtin`` fields may hold junk values.
It is safest to treat the ``_PyInterpreterFrame`` struct as opaque.
..
.. date: 2022-08-22-21-33-28
.. gh-issue: 96187
.. nonce: W_6SRG
.. section: Core and Builtins
Fixed a bug that caused ``_PyCode_GetExtra`` to return garbage for negative
indexes. Patch by Pablo Galindo
..
.. date: 2022-08-20-18-36-40
.. gh-issue: 96143
.. nonce: nh3GFM
.. section: Core and Builtins
Add a new ``-X perf`` Python command line option as well as
:func:`sys.activate_stack_trampoline` and
:func:`sys.deactivate_stack_trampoline` function in the :mod:`sys` module
that allows to set/unset the interpreter in a way that the Linux ``perf``
profiler can detect Python calls. The new
:func:`sys.is_stack_trampoline_active` function allows to query the state of
the perf trampoline. Design by Pablo Galindo. Patch by Pablo Galindo and
Christian Heimes with contributions from Gregory P. Smith [Google] and Mark
Shannon.
..
.. date: 2022-08-19-06-51-17
.. gh-issue: 96071
.. nonce: mVgPAo
.. section: Core and Builtins
Fix a deadlock in :c:func:`PyGILState_Ensure` when allocating new thread
state. Patch by Kumar Aditya.
..
.. date: 2022-08-18-13-47-59
.. gh-issue: 96046
.. nonce: 5Hqbka
.. section: Core and Builtins
:c:func:`PyType_Ready` now initializes ``ht_cached_keys`` and performs
additional checks to ensure that type objects are properly configured. This
avoids crashes in 3rd party packages that don't use regular API to create
new types.
..
.. date: 2022-08-15-21-08-11
.. gh-issue: 96005
.. nonce: 6eoc8k
.. section: Core and Builtins
On WASI :data:`~errno.ENOTCAPABLE` is now mapped to :exc:`PermissionError`.
The :mod:`errno` modules exposes the new error number. ``getpath.py`` now
ignores :exc:`PermissionError` when it cannot open landmark files
``pybuilddir.txt`` and ``pyenv.cfg``.
..
.. date: 2022-08-15-20-52-41
.. gh-issue: 93678
.. nonce: X7GuIJ
.. section: Core and Builtins
Added test a harness for direct unit tests of the compiler's optimization
stage. The ``_testinternalcapi.optimize_cfg()`` function runs the optimiser
on a sequence of instructions. The ``CfgOptimizationTestCase`` class in
``test.support`` has utilities for invoking the optimizer and checking the
output.
..
.. date: 2022-08-15-12-41-14
.. gh-issue: 95245
.. nonce: N4gOUV
.. section: Core and Builtins
Reduces the size of a "simple" Python object from 8 to 6 words by moving the
weakreflist pointer into the pre-header directly before the object's
dict/values pointer.
..
.. date: 2022-08-15-11-58-05
.. gh-issue: 90997
.. nonce: bWwV8Q
.. section: Core and Builtins
Compile virtual :keyword:`try`/:keyword:`except` blocks to handle exceptions
raised during :meth:`~generator.close` or :meth:`~generator.throw` calls
through a suspended frame.
..
.. date: 2022-08-14-10-04-44
.. gh-issue: 95977
.. nonce: gCTZb9
.. section: Core and Builtins
Optimized calling :meth:`~object.__get__` with vectorcall. Patch by Kumar
Aditya.
..
.. date: 2022-08-12-18-13-49
.. gh-issue: 91210
.. nonce: AWMSLj
.. section: Core and Builtins
Improve error message when a parameter without a default value follows one
with a default value, and show the same message, even when the
non-default/default sequence is preceded by positional-only parameters.
..
.. date: 2022-08-12-13-04-25
.. gh-issue: 95922
.. nonce: YNCtyX
.. section: Core and Builtins
Fixed bug where the compiler's ``eliminate_empty_basic_blocks`` function
ignores the last block of the code unit.
..
.. date: 2022-08-11-11-01-56
.. gh-issue: 95818
.. nonce: iClLdl
.. section: Core and Builtins
Skip over incomplete frames in :c:func:`PyThreadState_GetFrame`.
..
.. date: 2022-08-11-09-19-55
.. gh-issue: 95876
.. nonce: YpQfoV
.. section: Core and Builtins
Fix format string in ``_PyPegen_raise_error_known_location`` that can lead
to memory corruption on some 64bit systems. The function was building a
tuple with ``i`` (int) instead of ``n`` (Py_ssize_t) for Py_ssize_t
arguments.
..
.. date: 2022-08-04-18-46-54
.. gh-issue: 95605
.. nonce: FbpCoG
.. section: Core and Builtins
Fix misleading contents of error message when converting an all-whitespace
string to :class:`float`.
..
.. date: 2022-07-31-13-23-12
.. gh-issue: 95150
.. nonce: 67FXVo
.. section: Core and Builtins
Update code object hashing and equality to consider all debugging and
exception handling tables. This fixes an issue where certain non-identical
code objects could be "deduplicated" during compilation.
..
.. date: 2022-07-31-03-22-58
.. gh-issue: 91146
.. nonce: Y2Hziy
.. section: Core and Builtins
Reduce allocation size of :class:`list` from :meth:`str.split` and
:meth:`str.rsplit`. Patch by Dong-hee Na and Inada Naoki.
..
.. date: 2022-07-28-19-07-06
.. gh-issue: 87092
.. nonce: 73IPS1
.. section: Core and Builtins
Create a 'jump target label' abstraction in the compiler so that the
compiler's codegen stage does not work directly with basic blocks. This
prepares the code for changes to the underlying CFG generation mechanism.
..
.. date: 2022-07-28-08-33-31
.. gh-issue: 95355
.. nonce: yN4XVk
.. section: Core and Builtins
``_PyPegen_Parser_New`` now properly detects token memory allocation errors.
Patch by Honglin Zhu.
..
.. date: 2022-07-27-14-21-57
.. gh-issue: 90081
.. nonce: HVAS5x
.. section: Core and Builtins
Run Python code in tracer/profiler function at full speed. Fixes slowdown in
earlier versions of 3.11.
..
.. date: 2022-07-27-14-05-07
.. gh-issue: 95324
.. nonce: 28Q5u7
.. section: Core and Builtins
Emit a warning in debug mode if an object does not call
:c:func:`PyObject_GC_UnTrack` before deallocation. Patch by Pablo Galindo.
..
.. date: 2022-07-26-12-59-03
.. gh-issue: 95245
.. nonce: GHWczn
.. section: Core and Builtins
Merge managed dict and values pointer into a single tagged pointer to save
one word in the pre-header.
..
.. date: 2022-07-26-09-31-12
.. gh-issue: 93678
.. nonce: W8vvgT
.. section: Core and Builtins
Add cfg_builder struct and refactor the relevant code so that a cfg can be
constructed without an instance of the compiler struct.
..
.. date: 2022-07-24-00-27-47
.. gh-issue: 95185
.. nonce: ghYTZx
.. section: Core and Builtins
Prevented crashes in the AST constructor when compiling some absurdly long
expressions like ``"+0"*1000000``. :exc:`RecursionError` is now raised
instead. Patch by Pablo Galindo
..
.. date: 2022-07-23-19-16-25
.. gh-issue: 93351
.. nonce: 0Jyvu-
.. section: Core and Builtins
:class:`ast.AST` node positions are now validated when provided to
:func:`compile` and other related functions. If invalid positions are
detected, a :exc:`ValueError` will be raised.
..
.. date: 2022-07-22-12-53-34
.. gh-issue: 94438
.. nonce: hNqACc
.. section: Core and Builtins
Fix an issue that caused extended opcode arguments and some conditional pops
to be ignored when calculating valid jump targets for assignments to the
``f_lineno`` attribute of frame objects. In some cases, this could cause
inconsistent internal state, resulting in a hard crash of the interpreter.
..
.. date: 2022-07-21-19-19-20
.. gh-issue: 95060
.. nonce: 4xdT1f
.. section: Core and Builtins
Undocumented ``PyCode_Addr2Location`` function now properly returns when
``addrq`` argument is less than zero.
..
.. date: 2022-07-21-17-54-52
.. gh-issue: 95113
.. nonce: NnSLpT
.. section: Core and Builtins
Replace all ``EXTENDED_ARG_QUICK`` instructions with basic
:opcode:`EXTENDED_ARG` instructions in unquickened code. Consumers of
non-adaptive bytecode should be able to handle extended arguments the same
way they were handled in CPython 3.10 and older.
..
.. date: 2022-07-20-13-46-01
.. gh-issue: 91409
.. nonce: dhL8Zo
.. section: Core and Builtins
Fix incorrect source location info caused by certain optimizations in the
bytecode compiler.
..
.. date: 2022-07-20-09-04-55
.. gh-issue: 95023
.. nonce: bs-xd7
.. section: Core and Builtins
Implement :func:`os.setns` and :func:`os.unshare` for Linux. Patch by Noam
Cohen.
..
.. date: 2022-07-19-16-30-59
.. gh-issue: 94036
.. nonce: _6Utkm
.. section: Core and Builtins
Fix incorrect source location info for some multi-line attribute accesses
and method calls.
..
.. date: 2022-07-19-09-41-55
.. gh-issue: 94938
.. nonce: xYBlM7
.. section: Core and Builtins
Fix error detection in some builtin functions when keyword argument name is
an instance of a str subclass with overloaded ``__eq__`` and ``__hash__``.
Previously it could cause SystemError or other undesired behavior.
..
.. date: 2022-07-19-04-34-56
.. gh-issue: 94996
.. nonce: dV564A
.. section: Core and Builtins
:func:`ast.parse` will no longer parse function definitions with
positional-only params when passed ``feature_version`` less than ``(3, 8)``.
Patch by Shantanu Jain.
..
.. date: 2022-07-18-14-19-21
.. gh-issue: 94739
.. nonce: NQJQi7
.. section: Core and Builtins
Allow jumping within, out of, and across exception handlers in the debugger.
..
.. date: 2022-07-18-05-10-29
.. gh-issue: 94949
.. nonce: OsZ7_s
.. section: Core and Builtins
:func:`ast.parse` will no longer parse parenthesized context managers when
passed ``feature_version`` less than ``(3, 9)``. Patch by Shantanu Jain.
..
.. date: 2022-07-18-04-48-34
.. gh-issue: 94947
.. nonce: df9gUw
.. section: Core and Builtins
:func:`ast.parse` will no longer parse assignment expressions when passed
``feature_version`` less than ``(3, 8)``. Patch by Shantanu Jain.
..
.. date: 2022-07-17-15-54-29
.. gh-issue: 91256
.. nonce: z7i7Q5
.. section: Core and Builtins
Ensures the program name is known for help text during interpreter startup.
..
.. date: 2022-07-16-08-14-17
.. gh-issue: 94869
.. nonce: eRwMsX
.. section: Core and Builtins
Fix the column offsets for some expressions in multi-line f-strings
:mod:`ast` nodes. Patch by Pablo Galindo.
..
.. date: 2022-07-15-22-47-44
.. gh-issue: 94893
.. nonce: YiJYcW
.. section: Core and Builtins
Fix an issue where frame object manipulations could corrupt inline bytecode
caches.
..
.. date: 2022-07-15-22-16-08
.. gh-issue: 94822
.. nonce: zRRzBN
.. section: Core and Builtins
Fix an issue where lookups of metaclass descriptors may be ignored when an
identically-named attribute also exists on the class itself.
..
.. date: 2022-07-15-16-15-04
.. gh-issue: 91153
.. nonce: HiBmtt
.. section: Core and Builtins
Fix an issue where a :class:`bytearray` item assignment could crash if it's
resized by the new value's :meth:`__index__` method.
..
.. date: 2022-07-14-10-07-53
.. gh-issue: 90699
.. nonce: x3aG9m
.. section: Core and Builtins
Fix reference counting bug in :meth:`bool.__repr__`. Patch by Kumar Aditya.
..
.. date: 2022-07-08-16-44-11
.. gh-issue: 94694
.. nonce: VkL2CM
.. section: Core and Builtins
Fix an issue that could cause code with multi-line method lookups to have
misleading or incorrect column offset information. In some cases (when
compiling a hand-built AST) this could have resulted in a hard crash of the
interpreter.
..
.. date: 2022-07-08-11-44-45
.. gh-issue: 93252
.. nonce: i2358c
.. section: Core and Builtins
Fix an issue that caused internal frames to outlive failed Python function
calls, possibly resulting in memory leaks or hard interpreter crashes.
..
.. date: 2022-07-07-21-13-25
.. gh-issue: 94215
.. nonce: _Sv9Ms
.. section: Core and Builtins
Fix an issue where exceptions raised by line-tracing events would cause
frames to be left in an invalid state, possibly resulting in a hard crash of
the interpreter.
..
.. date: 2022-07-06-14-02-26
.. gh-issue: 92228
.. nonce: 44Cbly
.. section: Core and Builtins
Disable the compiler's inline-small-exit-blocks optimization for exit blocks
that are associated with source code lines. This fixes a bug where the
debugger cannot tell where an exception handler ends and the following code
block begins.
..
.. date: 2022-07-01-20-00-19
.. gh-issue: 94485
.. nonce: mo5st7
.. section: Core and Builtins
Line number of a module's ``RESUME`` instruction is set to 0 as specified in
:pep:`626`.
..
.. date: 2022-06-30-15-07-26
.. gh-issue: 94438
.. nonce: btzHSk
.. section: Core and Builtins
Account for instructions that can push NULL to the stack when setting line
number in a frame. Prevents some (unlikely) crashes.
..
.. date: 2022-06-29-22-18-36
.. gh-issue: 91719
.. nonce: 3APYYI
.. section: Core and Builtins
Reload ``opcode`` when raising ``unknown opcode error`` in the interpreter
main loop, for C compilers to generate dispatching code independently.
..
.. date: 2022-06-29-15-45-04
.. gh-issue: 94329
.. nonce: olUQyk
.. section: Core and Builtins
Compile and run code with unpacking of extremely large sequences (1000s of
elements). Such code failed to compile. It now compiles and runs correctly.
..
.. date: 2022-06-28-14-20-36
.. gh-issue: 94360
.. nonce: DiEnen
.. section: Core and Builtins
Fixed a tokenizer crash when reading encoded files with syntax errors from
``stdin`` with non utf-8 encoded text. Patch by Pablo Galindo
..
.. date: 2022-06-28-12-41-17
.. gh-issue: 88116
.. nonce: A7fEl_
.. section: Core and Builtins
Fix an issue when reading line numbers from code objects if the encoded line
numbers are close to ``INT_MIN``. Patch by Pablo Galindo
..
.. date: 2022-06-28-10-08-06
.. gh-issue: 94262
.. nonce: m-HWUZ
.. section: Core and Builtins
Don't create frame objects for incomplete frames. Prevents the creation of
generators and closures from being observable to Python and C extensions,
restoring the behavior of 3.10 and earlier.
..
.. date: 2022-06-26-14-37-03
.. gh-issue: 94192
.. nonce: ab7tn7
.. section: Core and Builtins
Fix error for dictionary literals with invalid expression as value.
..
.. date: 2022-06-25-10-19-43
.. gh-issue: 87995
.. nonce: aMDHnp
.. section: Core and Builtins
:class:`types.MappingProxyType` instances are now hashable if the underlying
mapping is hashable.
..
.. date: 2022-06-24-14-06-20
.. gh-issue: 93883
.. nonce: 8jVQQ4
.. section: Core and Builtins
Revise the display strategy of traceback enhanced error locations. The
indicators are only shown when the location doesn't span the whole line.
..
.. date: 2022-06-23-12-10-39
.. gh-issue: 94163
.. nonce: SqAfQq
.. section: Core and Builtins
Add :opcode:`BINARY_SLICE` and :opcode:`STORE_SLICE` instructions for more
efficient handling and better specialization of slicing operations, where
the slice is explicit in the source code.
..
.. date: 2022-06-20-13-48-57
.. gh-issue: 94021
.. nonce: o78q3G
.. section: Core and Builtins
Fix unreachable code warning in ``Python/specialize.c``.
..
.. date: 2022-06-18-17-00-33
.. gh-issue: 93911
.. nonce: y286of
.. section: Core and Builtins
Specialize ``LOAD_ATTR`` for objects with custom ``__getattribute__``.
..
.. date: 2022-06-17-16-30-24
.. gh-issue: 93955
.. nonce: LmiAe9
.. section: Core and Builtins
Improve performance of attribute lookups on objects with custom
``__getattribute__`` and ``__getattr__``. Patch by Ken Jin.
..
.. date: 2022-06-16-16-53-22
.. gh-issue: 93911
.. nonce: RDwIiK
.. section: Core and Builtins
Specialize ``LOAD_ATTR`` for ``property()`` attributes.
..
.. date: 2022-06-15-16-45-53
.. gh-issue: 93678
.. nonce: 1I_ZT3
.. section: Core and Builtins
Refactor compiler optimisation code so that it no longer needs the ``struct
assembler`` and ``struct compiler`` passed around. Instead, each function
takes the CFG and other data that it actually needs. This will make it
possible to test this code directly.
..
.. date: 2022-06-15-11-16-13
.. gh-issue: 93841
.. nonce: 06zqX3
.. section: Core and Builtins
When built with ``-enable-pystats``, ``sys._stats_on()``,
``sys._stats_off()``, ``sys._stats_clear()`` and ``sys._stats_dump()``
functions have been added to enable gathering stats for parts of programs.
..
.. date: 2022-06-13-13-55-34
.. gh-issue: 93516
.. nonce: HILrDl
.. section: Core and Builtins
Store offset of first traceable instruction in code object to avoid having
to recompute it for each instruction when tracing.
..
.. date: 2022-06-13-10-48-09
.. gh-issue: 93516
.. nonce: yJSait
.. section: Core and Builtins
Lazily create a table mapping bytecode offsets to line numbers to speed up
calculation of line numbers when tracing.
..
.. date: 2022-06-12-19-31-56
.. gh-issue: 89828
.. nonce: bq02M7
.. section: Core and Builtins
:class:`types.GenericAlias` no longer relays the ``__class__`` attribute.
For example, ``isinstance(list[int], type)`` no longer returns ``True``.
..
.. date: 2022-06-10-16-57-35
.. gh-issue: 93678
.. nonce: 1WBnHt
.. section: Core and Builtins
Refactor the compiler to reduce boilerplate and repetition.
..
.. date: 2022-06-10-12-03-17
.. gh-issue: 93671
.. nonce: idkQqG
.. section: Core and Builtins
Fix some exponential backtrace case happening with deeply nested sequence
patterns in match statements. Patch by Pablo Galindo
..
.. date: 2022-06-10-10-31-18
.. gh-issue: 93662
.. nonce: -7RSC1
.. section: Core and Builtins
Make sure that the end column offsets are correct in multi-line method
calls. Previously, the end column could precede the column offset.
..
.. date: 2022-06-09-19-19-02
.. gh-issue: 93461
.. nonce: 5DqP1e
.. section: Core and Builtins
:func:`importlib.invalidate_caches` now drops entries from
:data:`sys.path_importer_cache` with a relative path as name. This solves a
caching issue when a process changes its current working directory.
``FileFinder`` no longer inserts a dot in the path, e.g. ``/egg/./spam`` is
now ``/egg/spam``.
..
.. date: 2022-06-09-09-08-29
.. gh-issue: 93621
.. nonce: -_Pn1d
.. section: Core and Builtins
Change order of bytecode instructions emitted for :keyword:`with` and
:keyword:`async with` to reduce the number of entries in the exception
table.
..
.. date: 2022-06-06-14-28-24
.. gh-issue: 93533
.. nonce: lnC0CC
.. section: Core and Builtins
Reduce the size of the inline cache for ``LOAD_METHOD`` by 2 bytes.
..
.. date: 2022-06-02-23-00-08
.. gh-issue: 93444
.. nonce: m63DIs
.. section: Core and Builtins
Removed redundant fields from the compiler's basicblock struct:
``b_nofallthrough``, ``b_exit``, ``b_return``. They can be easily calculated
from the opcode of the last instruction of the block.
..
.. date: 2022-06-02-08-28-55
.. gh-issue: 93429
.. nonce: DZTWHx
.. section: Core and Builtins
``LOAD_METHOD`` instruction has been removed. It was merged back into
``LOAD_ATTR``.
..
.. date: 2022-06-01-17-47-40
.. gh-issue: 93418
.. nonce: 24dJuc
.. section: Core and Builtins
Fixed an assert where an f-string has an equal sign '=' following an
expression, but there's no trailing brace. For example, f"{i=".
..
.. date: 2022-05-31-16-36-30
.. gh-issue: 93382
.. nonce: Jf6gAj
.. section: Core and Builtins
Cache the result of :c:func:`PyCode_GetCode` function to restore the O(1)
lookup of the :attr:`~types.CodeType.co_code` attribute.
..
.. date: 2022-05-30-19-00-38
.. gh-issue: 93359
.. nonce: zXV3A0
.. section: Core and Builtins
Ensure that custom :mod:`ast` nodes without explicit end positions can be
compiled. Patch by Pablo Galindo.
..
.. date: 2022-05-30-15-51-11
.. gh-issue: 93356
.. nonce: l5wnzW
.. section: Core and Builtins
Code for exception handlers is emitted at the end of the code unit's
bytecode. This avoids one jump when no exception is raised.
..
.. date: 2022-05-30-15-35-42
.. gh-issue: 93354
.. nonce: RZk8gs
.. section: Core and Builtins
Use exponential backoff for specialization counters in the interpreter. Can
reduce the number of failed specializations significantly and avoid slowdown
for those parts of a program that are not suitable for specialization.
..
.. date: 2022-05-30-14-50-03
.. gh-issue: 93283
.. nonce: XDO2ZQ
.. section: Core and Builtins
Improve error message for invalid syntax of conversion character in f-string
expressions.
..
.. date: 2022-05-30-10-22-46
.. gh-issue: 93345
.. nonce: gi1A4L
.. section: Core and Builtins
Fix a crash in substitution of a ``TypeVar`` in nested generic alias after
``TypeVarTuple``.
..
.. date: 2022-05-25-21-56-25
.. gh-issue: 93223
.. nonce: gTOGVZ
.. section: Core and Builtins
When a bytecode instruction jumps to an unconditional jump instruction, the
first instruction can often be optimized to target the unconditional jump's
target directly. For tracing reasons, this would previously only occur if
both instructions have the same line number. This also now occurs if the
unconditional jump is artificial, i.e., if it has no associated line number.
..
.. date: 2022-05-25-12-30-12
.. gh-issue: 84694
.. nonce: 5sjy2w
.. section: Core and Builtins
The ``--experimental-isolated-subinterpreters`` configure option and
``EXPERIMENTAL_ISOLATED_SUBINTERPRETERS`` macro have been removed.
..
.. date: 2022-05-25-04-07-22
.. gh-issue: 91924
.. nonce: -UyO4q
.. section: Core and Builtins
Fix ``__lltrace__`` debug feature if the stdout encoding is not UTF-8. Patch
by Victor Stinner.
..
.. date: 2022-05-24-14-35-48
.. gh-issue: 93040
.. nonce: 9X6Ofu
.. section: Core and Builtins
Wraps unused parameters in ``Objects/obmalloc.c`` with ``Py_UNUSED``.
..
.. date: 2022-05-23-18-36-07
.. gh-issue: 93143
.. nonce: X1Yqxm
.. section: Core and Builtins
Avoid ``NULL`` checks for uninitialized local variables by determining at
compile time which variables must be initialized.
..
.. date: 2022-05-22-02-37-50
.. gh-issue: 93061
.. nonce: r70Imp
.. section: Core and Builtins
Backward jumps after ``async for`` loops are no longer given dubious line
numbers.
..
.. date: 2022-05-21-23-21-37
.. gh-issue: 93065
.. nonce: 5I18WC
.. section: Core and Builtins
Fix contextvars HAMT implementation to handle iteration over deep trees.
The bug was discovered and fixed by Eli Libman. See
`MagicStack/immutables#84
<https://github.com/MagicStack/immutables/issues/84>`_ for more details.
..
.. date: 2022-05-20-13-32-24
.. gh-issue: 93012
.. nonce: e9B-pv
.. section: Core and Builtins
Added the new function :c:func:`PyType_FromMetaclass`, which generalizes the
existing :c:func:`PyType_FromModuleAndSpec` using an additional metaclass
argument. This is useful for language binding tools, where it can be used to
intercept type-related operations like subclassing or static attribute
access by specifying a metaclass with custom slots.
Importantly, :c:func:`PyType_FromMetaclass` is available in the Limited API,
which provides a path towards migrating more binding tools onto the Stable
ABI.
..
.. date: 2022-05-20-09-25-34
.. gh-issue: 93021
.. nonce: k3Aji2
.. section: Core and Builtins
Fix the :attr:`__text_signature__` for :meth:`__get__` methods implemented
in C. Patch by Jelle Zijlstra.
..
.. date: 2022-05-19-15-29-53
.. gh-issue: 89914
.. nonce: 8bAffH
.. section: Core and Builtins
The operand of the ``YIELD_VALUE`` instruction is set to the stack depth.
This is done to help frame handling on ``yield`` and may assist debuggers.
..
.. date: 2022-05-19-13-25-50
.. gh-issue: 92955
.. nonce: kmNV33
.. section: Core and Builtins
Fix memory leak in code object's lines and positions iterators as they were
not finalized at exit. Patch by Kumar Aditya.
..
.. date: 2022-05-18-18-34-45
.. gh-issue: 92930
.. nonce: kpYPOb
.. section: Core and Builtins
Fixed a crash in ``_pickle.c`` from mutating collections during
``__reduce__`` or ``persistent_id``.
..
.. date: 2022-05-18-12-55-35
.. gh-issue: 90690
.. nonce: TKuoTa
.. section: Core and Builtins
The PRECALL instruction has been removed. It offered only a small advantage
for specialization and is not needed in the vast majority of cases.
..
.. date: 2022-05-18-08-32-33
.. gh-issue: 92914
.. nonce: tJUeTD
.. section: Core and Builtins
Always round the allocated size for lists up to the nearest even number.
..
.. date: 2022-05-17-20-41-43
.. gh-issue: 92858
.. nonce: eIXJTn
.. section: Core and Builtins
Improve error message for some suites with syntax error before ':'
..
.. date: 2022-05-15-15-25-05
.. gh-issue: 90473
.. nonce: MoPHYW
.. section: Core and Builtins
Decrease default recursion limit on WASI to address limited call stack size.
..
.. date: 2022-05-14-13-22-11
.. gh-issue: 92804
.. nonce: rAqpI2
.. section: Core and Builtins
Fix memory leak in ``memoryview`` iterator as it was not finalized at exit.
Patch by Kumar Aditya.
..
.. date: 2022-05-13-12-36-10
.. gh-issue: 92777
.. nonce: Odo4vP
.. section: Core and Builtins
Specialize ``LOAD_METHOD`` for objects with lazy dictionaries. Patch by Ken
Jin.
..
.. date: 2022-05-13-00-57-18
.. gh-issue: 92658
.. nonce: YdhFE2
.. section: Core and Builtins
Add support for connecting and binding to Hyper-V sockets on Windows Hyper-V
hosts and guests.
..
.. date: 2022-05-12-13-23-19
.. gh-issue: 92236
.. nonce: sDRzUe
.. section: Core and Builtins
Remove spurious "LINE" event when starting a generator or coroutine, visible
tracing functions implemented in C.
..
.. date: 2022-05-11-09-16-54
.. gh-issue: 91102
.. nonce: lenv9h
.. section: Core and Builtins
:meth:`_warnings.warn_explicit` is ported to Argument Clinic.
..
.. date: 2022-05-10-11-34-35
.. gh-issue: 92619
.. nonce: u0V0lY
.. section: Core and Builtins
Make the compiler duplicate an exit block only if none of its instructions
have a lineno (previously only the first instruction in the block was
checked, leading to unnecessarily duplicated blocks).
..
.. date: 2022-05-08-19-43-31
.. gh-issue: 88750
.. nonce: 1BjJg-
.. section: Core and Builtins
The deprecated debug build only ``PYTHONTHREADDEBUG`` environment variable
no longer does anything.
..
.. date: 2022-05-03-20-12-18
.. gh-issue: 92261
.. nonce: aigLnb
.. section: Core and Builtins
Fix hang when trying to iterate over a ``typing.Union``.
..
.. date: 2022-04-24-02-22-10
.. gh-issue: 91432
.. nonce: YPJAK6
.. section: Core and Builtins
Specialized the :opcode:`FOR_ITER` opcode using the PEP 659 machinery
..
.. date: 2022-04-16-15-37-55
.. gh-issue: 91399
.. nonce: trLbK6
.. section: Core and Builtins
Removed duplicate '{0, 0, 0, 0, 0, 0}' entry in 'Objects/unicodetype_db.h'.
..
.. date: 2022-04-15-22-12-53
.. gh-issue: 91578
.. nonce: rDOtyK
.. section: Core and Builtins
Updates the error message for abstract class.
..
.. bpo: 47091
.. date: 2022-03-22-13-12-27
.. nonce: tJcy-P
.. section: Core and Builtins
Improve performance of repetition of :class:`list` and :class:`tuple` by
using ``memcpy`` to copy data and performing the reference increments in one
step.
..
.. bpo: 46142
.. date: 2022-01-02-14-53-59
.. nonce: WayjgT
.. section: Core and Builtins
Make ``--help`` output shorter by moving some info to the new ``--help-env``
and ``--help-xoptions`` command-line options. Also add ``--help-all`` option
to print complete usage.
..
.. bpo: 42316
.. date: 2020-11-15-02-08-43
.. nonce: LqdkWK
.. section: Core and Builtins
Document some places where an assignment expression needs parentheses.
..
.. date: 2022-10-23-18-30-39
.. gh-issue: 89237
.. nonce: kBui30
.. section: Library
Fix hang on Windows in ``subprocess.wait_closed()`` in :mod:`asyncio` with
:class:`~asyncio.ProactorEventLoop`. Patch by Kumar Aditya.
..
.. date: 2022-10-19-09-29-12
.. gh-issue: 97928
.. nonce: xj3im7
.. section: Library
:meth:`tkinter.Text.count` raises now an exception for options starting with
"-" instead of silently ignoring them.
..
.. date: 2022-10-18-15-41-37
.. gh-issue: 98393
.. nonce: vhPu4L
.. section: Library
The :mod:`os` module no longer accepts bytes-like paths, like
:class:`bytearray` and :class:`memoryview` types: only the exact
:class:`bytes` type is accepted for bytes strings. Patch by Victor Stinner.
..
.. date: 2022-10-17-12-49-02
.. gh-issue: 98363
.. nonce: aFmSP-
.. section: Library
Added itertools.batched() to batch data into lists of a given length with
the last list possibly being shorter than the others.
..
.. date: 2022-10-16-15-31-50
.. gh-issue: 98331
.. nonce: Y5kPOX
.. section: Library
Update the bundled copies of pip and setuptools to versions 22.3 and 65.5.0
respectively.
..
.. date: 2022-10-16-06-18-59
.. gh-issue: 98307
.. nonce: b2_CDu
.. section: Library
A :meth:`~logging.handlers.SysLogHandler.createSocket` method was added to
:class:`~logging.handlers.SysLogHandler`.
..
.. date: 2022-10-14-19-57-37
.. gh-issue: 96035
.. nonce: 0xcX-p
.. section: Library
Fix bug in :func:`urllib.parse.urlparse` that causes certain port numbers
containing whitespace, underscores, plus and minus signs, or non-ASCII
digits to be incorrectly accepted.
..
.. date: 2022-10-14-12-29-05
.. gh-issue: 98257
.. nonce: aMSMs2
.. section: Library
Make :func:`sys.setprofile` and :func:`sys.settrace` functions reentrant.
They can no long fail with: ``RuntimeError("Cannot install a trace function
while another trace function is being installed")``. Patch by Victor
Stinner.
..
.. date: 2022-10-14-11-46-31
.. gh-issue: 98251
.. nonce: Uxc9al
.. section: Library
Allow :mod:`venv` to pass along :envvar:`PYTHON*` variables to ``ensurepip``
and ``pip`` when they do not impact path resolution
..
.. date: 2022-10-12-11-20-54
.. gh-issue: 94597
.. nonce: GYJZlb
.. section: Library
Deprecated :meth:`asyncio.AbstractEventLoopPolicy.get_child_watcher` and
:meth:`asyncio.AbstractEventLoopPolicy.set_child_watcher` methods to be
removed in Python 3.14. Patch by Kumar Aditya.
..
.. date: 2022-10-12-10-00-40
.. gh-issue: 98178
.. nonce: hspH51
.. section: Library
On macOS, fix a crash in :func:`syslog.syslog` in multi-threaded
applications. On macOS, the libc ``syslog()`` function is not thread-safe,
so :func:`syslog.syslog` no longer releases the GIL to call it. Patch by
Victor Stinner.
..
.. date: 2022-10-10-09-52-21
.. gh-issue: 44098
.. nonce: okcqJt
.. section: Library
Release the GIL when creating :class:`mmap.mmap` objects on Unix.
..
.. date: 2022-10-09-12-12-38
.. gh-issue: 87730
.. nonce: ClgP3f
.. section: Library
Wrap network errors consistently in urllib FTP support, so the test suite
doesn't fail when a network is available but the public internet is not
reachable.
..
.. date: 2022-10-08-06-59-46
.. gh-issue: 94597
.. nonce: TsS0oT
.. section: Library
The child watcher classes :class:`~asyncio.MultiLoopChildWatcher`,
:class:`~asyncio.FastChildWatcher` and :class:`~asyncio.SafeChildWatcher`
are deprecated and will be removed in Python 3.14. Patch by Kumar Aditya.
..
.. date: 2022-10-07-09-52-37
.. gh-issue: 98023
.. nonce: aliEcl
.. section: Library
Change default child watcher to :class:`~asyncio.PidfdChildWatcher` on Linux
systems which supports it. Patch by Kumar Aditya.
..
.. date: 2022-10-06-23-42-00
.. gh-issue: 90985
.. nonce: s280JY
.. section: Library
Earlier in 3.11 we deprecated ``asyncio.Task.cancel("message")``. We
realized we were too harsh, and have undeprecated it.
..
.. date: 2022-10-06-17-59-22
.. gh-issue: 65961
.. nonce: SXlQnI
.. section: Library
Do not rely solely on ``__cached__`` on modules; code will also support
``__spec__.cached``.
..
.. date: 2022-10-05-20-52-17
.. gh-issue: 97646
.. nonce: Q4fVww
.. section: Library
Replace deprecated ``application/javascript`` with ``text/javascript`` in
:mod:`mimetypes`. See :rfc:`9239`. Patch by Noam Cohen.
..
.. date: 2022-10-05-16-10-24
.. gh-issue: 97930
.. nonce: NPSrzE
.. section: Library
Apply changes from importlib_resources 5.8 and 5.9: ``Traversable.joinpath``
provides a concrete implementation. ``as_file`` now supports directories of
resources.
..
.. date: 2022-10-05-11-40-02
.. gh-issue: 97850
.. nonce: NzdREm
.. section: Library
Remove deprecated :func:`importlib.utils.set_loader` and
:func:`importlib.utils.module_for_loader` from :mod:`importlib.utils`.
..
.. date: 2022-10-04-21-21-41
.. gh-issue: 97837
.. nonce: 19q-eg
.. section: Library
Change deprecate warning message in :mod:`unittest` from
``It is deprecated to return a value!=None``
to
``It is deprecated to return a value that is not None from a test case``
..
.. date: 2022-10-04-07-55-19
.. gh-issue: 97825
.. nonce: mNdv1l
.. section: Library
Fixes :exc:`AttributeError` when :meth:`subprocess.check_output` is used
with argument ``input=None`` and either of the arguments *encoding* or
*errors* are used.
..
.. date: 2022-10-04-00-43-43
.. gh-issue: 97008
.. nonce: 3rjtt6
.. section: Library
:exc:`NameError` and :exc:`AttributeError` spelling suggestions provided
since :gh:`82711` are now also emitted by the pure Python :mod:`traceback`
module. Tests for those suggestions now exercise both implementations to
ensure they are equivalent. Patch by Carl Friedrich Bolz-Tereick and Łukasz
Langa.
..
.. date: 2022-10-03-14-42-13
.. gh-issue: 97799
.. nonce: Y1iJvf
.. section: Library
:mod:`dataclass` now uses :func:`inspect.get_annotations` to examine the
annotations on class objects.
..
.. date: 2022-10-03-13-25-19
.. gh-issue: 97781
.. nonce: gCLLef
.. section: Library
Removed deprecated interfaces in ``importlib.metadata`` (entry points
accessed as dictionary, implicit dictionary construction of sequence of
``EntryPoint`` objects, mutablility of ``EntryPoints`` result, access of
entry point by index). ``entry_points`` now has a simpler, more
straightforward API (returning ``EntryPoints``).
..
.. date: 2022-09-30-15-56-20
.. gh-issue: 96827
.. nonce: lzy1iw
.. section: Library
Avoid spurious tracebacks from :mod:`asyncio` when default executor cleanup
is delayed until after the event loop is closed (e.g. as the result of a
keyboard interrupt).
..
.. date: 2022-09-30-09-22-37
.. gh-issue: 95534
.. nonce: ndEfPj
.. section: Library
:meth:`gzip.GzipFile.read` reads 10% faster.
..
.. date: 2022-09-29-23-22-24
.. gh-issue: 97592
.. nonce: tpJg_J
.. section: Library
Avoid a crash in the C version of
:meth:`asyncio.Future.remove_done_callback` when an evil argument is passed.
..
.. date: 2022-09-29-08-15-55
.. gh-issue: 97639
.. nonce: JSjWYW
.. section: Library
Remove ``tokenize.NL`` check from :mod:`tabnanny`.
..
.. date: 2022-09-25-23-24-52
.. gh-issue: 97545
.. nonce: HZLSNt
.. section: Library
Make Semaphore run faster.
..
.. date: 2022-09-25-20-42-33
.. gh-issue: 73588
.. nonce: uVtjEA
.. section: Library
Fix generation of the default name of :class:`tkinter.Checkbutton`.
Previously, checkbuttons in different parent widgets could have the same
short name and share the same state if arguments "name" and "variable" are
not specified. Now they are globally unique.
..
.. date: 2022-09-24-18-56-23
.. gh-issue: 96865
.. nonce: o9WUkW
.. section: Library
fix Flag to use boundary CONFORM
This restores previous Flag behavior of allowing flags with non-sequential
values to be combined; e.g.
class Skip(Flag): TWO = 2 EIGHT = 8
Skip.TWO | Skip.EIGHT -> <Skip.TWO|EIGHT: 10>
..
.. date: 2022-09-22-14-35-02
.. gh-issue: 97005
.. nonce: yf21Q7
.. section: Library
Update bundled libexpat to 2.4.9
..
.. date: 2022-09-22-11-50-29
.. gh-issue: 85760
.. nonce: DETTPd
.. section: Library
Fix race condition in :mod:`asyncio` where
:meth:`~asyncio.SubprocessProtocol.process_exited` called before the
:meth:`~asyncio.SubprocessProtocol.pipe_data_received` leading to
inconsistent output. Patch by Kumar Aditya.
..
.. date: 2022-09-18-04-51-30
.. gh-issue: 96704
.. nonce: DmamRX
.. section: Library
Pass the correct ``contextvars.Context`` when a ``asyncio`` exception
handler is called on behalf of a task or callback handle. This adds a new
``Task`` method, ``get_context``, and also a new ``Handle`` method with the
same name. If this method is not found on a task object (perhaps because it
is a third-party library that does not yet provide this method), the context
prevailing at the time the exception handler is called is used.
..
.. date: 2022-09-17-13-15-10
.. gh-issue: 96819
.. nonce: 6RfqM7
.. section: Library
Fixed check in :mod:`multiprocessing.resource_tracker` that guarantees that
the length of a write to a pipe is not greater than ``PIPE_BUF``.
..
.. date: 2022-09-16-07-53-29
.. gh-issue: 95865
.. nonce: oHjX0A
.. section: Library
Reduce :func:`urllib.parse.quote_from_bytes` memory use on large values.
Contributed by Dennis Sweeney.
..
.. date: 2022-09-15-00-37-33
.. gh-issue: 96741
.. nonce: 4b6czN
.. section: Library
Corrected type annotation for dataclass attribute
``pstats.FunctionProfile.ncalls`` to be ``str``.
..
.. date: 2022-09-13-15-12-31
.. gh-issue: 96734
.. nonce: G08vjz
.. section: Library
Update :mod:`unicodedata` database to Unicode 15.0.0.
..
.. date: 2022-09-10-16-46-16
.. gh-issue: 96735
.. nonce: 0YzJuG
.. section: Library
Fix undefined behaviour in :func:`struct.unpack`.
..
.. date: 2022-09-08-20-12-48
.. gh-issue: 46412
.. nonce: r_cfTh
.. section: Library
Improve performance of ``bool(db)`` for large ndb/gdb databases. Previously
this would call ``len(db)`` which would iterate over all keys -- the answer
(empty or not) is known after the first key.
..
.. date: 2022-09-07-22-49-37
.. gh-issue: 96652
.. nonce: YqOKxI
.. section: Library
Fix the faulthandler implementation of ``faulthandler.register(signal,
chain=True)`` if the ``sigaction()`` function is not available: don't call
the previous signal handler if it's NULL. Patch by Victor Stinner.
..
.. date: 2022-09-04-12-32-52
.. gh-issue: 68163
.. nonce: h6TJCc
.. section: Library
Correct conversion of :class:`numbers.Rational`'s to :class:`float`.
..
.. date: 2022-09-03-18-39-05
.. gh-issue: 96538
.. nonce: W156-D
.. section: Library
Speed up ``bisect.bisect()`` functions by taking advantage of
type-stability.
..
.. date: 2022-09-01-13-54-38
.. gh-issue: 96465
.. nonce: 0IJmrH
.. section: Library
Fraction hashes are now cached.
..
.. date: 2022-08-31-11-10-21
.. gh-issue: 96079
.. nonce: uqrXdJ
.. section: Library
In :mod:`typing`, fix missing field ``name`` and incorrect ``__module__`` in
_AnnotatedAlias.
..
.. date: 2022-08-30-12-32-00
.. gh-issue: 96415
.. nonce: 6W7ORH
.. section: Library
Remove ``types._cell_factory`` from module namespace.
..
.. date: 2022-08-30-11-46-36
.. gh-issue: 95987
.. nonce: CV7_u4
.. section: Library
Fix ``repr`` of ``Any`` subclasses.
..
.. date: 2022-08-29-16-54-36
.. gh-issue: 96388
.. nonce: dCpJcu
.. section: Library
Work around missing socket functions in :class:`~socket.socket`'s
``__repr__``.
..
.. date: 2022-08-29-15-28-39
.. gh-issue: 96385
.. nonce: uLRTsf
.. section: Library
Fix ``TypeVarTuple.__typing_prepare_subst__``. ``TypeError`` was not raised
when using more than one ``TypeVarTuple``, like ``[*T, *V]`` in type alias
substitutions.
..
.. date: 2022-08-29-12-49-30
.. gh-issue: 96142
.. nonce: PdCMez
.. section: Library
Add ``match_args``, ``kw_only``, ``slots``, and ``weakref_slot`` to
``_DataclassParams``.
..
.. date: 2022-08-29-12-35-28
.. gh-issue: 96073
.. nonce: WaGstf
.. section: Library
In :mod:`inspect`, fix overeager replacement of "``typing.``" in formatting
annotations.
..
.. date: 2022-08-29-07-04-03
.. gh-issue: 89258
.. nonce: ri7ncj
.. section: Library
Added a :meth:`~logging.Logger.getChildren` method to
:class:`logging.Logger`, to get the immediate child loggers of a logger.
..
.. date: 2022-08-27-23-16-09
.. gh-issue: 96346
.. nonce: jJX14I
.. section: Library
Use double caching for compiled RE patterns.
..
.. date: 2022-08-27-21-26-52
.. gh-issue: 96349
.. nonce: XyYLlO
.. section: Library
Fixed a minor performance regression in :func:`threading.Event.__init__`
..
.. date: 2022-08-27-14-38-49
.. gh-issue: 90467
.. nonce: VOOB0p
.. section: Library
Fix :class:`asyncio.streams.StreamReaderProtocol` to keep a strong reference
to the created task, so that it's not garbage collected
..
.. date: 2022-08-23-13-30-30
.. gh-issue: 96172
.. nonce: 7WTHer
.. section: Library
Fix a bug in ``unicodedata``: ``east_asian_width`` used to return the wrong
value for unassigned characters; and for yet unassigned, but reserved
characters.
..
.. date: 2022-08-22-18-42-17
.. gh-issue: 96159
.. nonce: 3bFU39
.. section: Library
Fix a performance regression in logging TimedRotatingFileHandler. Only check
for special files when the rollover time has passed.
..
.. date: 2022-08-22-13-54-20
.. gh-issue: 96175
.. nonce: bH7zGU
.. section: Library
Fix unused ``localName`` parameter in the ``Attr`` class in
:mod:`xml.dom.minidom`.
..
.. date: 2022-08-20-12-56-15
.. gh-issue: 96145
.. nonce: 8ah3pE
.. section: Library
Add AttrDict to JSON module for use with object_hook.
..
.. date: 2022-08-20-10-31-01
.. gh-issue: 96052
.. nonce: a6FhaD
.. section: Library
Fix handling compiler warnings (SyntaxWarning and DeprecationWarning) in
:func:`codeop.compile_command` when checking for incomplete input.
Previously it emitted warnings and raised a SyntaxError. Now it always
returns ``None`` for incomplete input without emitting any warnings.
..
.. date: 2022-08-19-18-21-01
.. gh-issue: 96125
.. nonce: ODcF1Y
.. section: Library
Fix incorrect condition that causes ``sys.thread_info.name`` to be wrong on
pthread platforms.
..
.. date: 2022-08-19-10-19-32
.. gh-issue: 96019
.. nonce: b7uAVP
.. section: Library
Fix a bug in the ``makeunicodedata.py`` script leading to about 13 KiB of
space saving in the ``unicodedata`` module, specifically the character
decomposition data.
..
.. date: 2022-08-18-14-53-53
.. gh-issue: 95463
.. nonce: GpP05c
.. section: Library
Remove an incompatible change from :issue:`28080` that caused a regression
that ignored the utf8 in ``ZipInfo.flag_bits``. Patch by Pablo Galindo.
..
.. date: 2022-08-14-18-59-54
.. gh-issue: 69142
.. nonce: 6is5Pq
.. section: Library
Add ``%:z`` strftime format code (generates tzoffset with colons as
separator), see :ref:`strftime-strptime-behavior`.
..
.. date: 2022-08-11-18-52-17
.. gh-issue: 95899
.. nonce: _Bi4uG
.. section: Library
Fix :class:`asyncio.Runner` to call :func:`asyncio.set_event_loop` only once
to avoid calling :meth:`~asyncio.AbstractChildWatcher.attach_loop` multiple
times on child watchers. Patch by Kumar Aditya.
..
.. date: 2022-08-11-18-22-29
.. gh-issue: 95736
.. nonce: LzRZXe
.. section: Library
Fix :class:`unittest.IsolatedAsyncioTestCase` to set event loop before
calling setup functions. Patch by Kumar Aditya.
..
.. date: 2022-08-11-03-16-48
.. gh-issue: 95865
.. nonce: 0IOkFP
.. section: Library
Speed up :func:`urllib.parse.quote_from_bytes` by replacing a list
comprehension with ``map()``.
..
.. date: 2022-08-10-17-34-07
.. gh-issue: 95861
.. nonce: qv-T5s
.. section: Library
Add support for computing Spearman's correlation coefficient to the existing
statistics.correlation() function.
..
.. date: 2022-08-10-11-54-04
.. gh-issue: 95804
.. nonce: i5FCFK
.. section: Library
Fix ``logging`` shutdown handler so it respects
``MemoryHandler.flushOnClose``.
..
.. date: 2022-08-08-01-42-11
.. gh-issue: 95704
.. nonce: MOPFfX
.. section: Library
When a task catches :exc:`asyncio.CancelledError` and raises some other
error, the other error should generally not silently be suppressed.
..
.. date: 2022-08-07-14-56-23
.. gh-issue: 95149
.. nonce: U0c6Ib
.. section: Library
The :class:`HTTPStatus <http.HTTPStatus>` enum offers a couple of properties
to indicate the HTTP status category e.g. ``HTTPStatus.OK.is_success``.
..
.. date: 2022-08-03-21-01-17
.. gh-issue: 95609
.. nonce: xxyjyX
.. section: Library
Update bundled pip to 22.2.2.
..
.. date: 2022-08-03-16-52-32
.. gh-issue: 95289
.. nonce: FMnHlV
.. section: Library
Fix :class:`asyncio.TaskGroup` to propagate exception when
:exc:`asyncio.CancelledError` was replaced with another exception by a
context manger. Patch by Kumar Aditya and Guido van Rossum.
..
.. date: 2022-07-29-20-58-37
.. gh-issue: 94909
.. nonce: YjMusj
.. section: Library
Fix incorrect joining of relative Windows paths with drives in
:class:`pathlib.PurePath` initializer.
..
.. date: 2022-07-28-17-14-38
.. gh-issue: 95385
.. nonce: 6YlsDI
.. section: Library
Faster ``json.dumps()`` when sorting of keys is not requested (default).
..
.. date: 2022-07-27-19-47-51
.. gh-issue: 83901
.. nonce: OSw06c
.. section: Library
Improve :meth:`Signature.bind <inspect.Signature.bind>` error message for
missing keyword-only arguments.
..
.. date: 2022-07-27-19-43-07
.. gh-issue: 95339
.. nonce: NuVQ68
.. section: Library
Update bundled pip to 22.2.1.
..
.. date: 2022-07-27-11-35-45
.. gh-issue: 95045
.. nonce: iysT-Q
.. section: Library
Fix GC crash when deallocating ``_lsprof.Profiler`` by untracking it before
calling any callbacks. Patch by Kumar Aditya.
..
.. date: 2022-07-25-15-45-06
.. gh-issue: 95231
.. nonce: i807-g
.. section: Library
Fail gracefully if :data:`~errno.EPERM` or :data:`~errno.ENOSYS` is raised
when loading :mod:`crypt` methods. This may happen when trying to load
``MD5`` on a Linux kernel with :abbr:`FIPS (Federal Information Processing
Standard)` enabled.
..
.. date: 2022-07-24-18-00-42
.. gh-issue: 95097
.. nonce: lu5qNf
.. section: Library
Fix :func:`asyncio.run` for :class:`asyncio.Task` implementations without
:meth:`~asyncio.Task.uncancel` method. Patch by Kumar Aditya.
..
.. date: 2022-07-24-12-59-02
.. gh-issue: 95087
.. nonce: VvqXkN
.. section: Library
Fix IndexError in parsing invalid date in the :mod:`email` module.
..
.. date: 2022-07-24-12-00-06
.. gh-issue: 95199
.. nonce: -5A64k
.. section: Library
Upgrade bundled setuptools to 63.2.0.
..
.. date: 2022-07-24-09-15-35
.. gh-issue: 95194
.. nonce: ERVmqG
.. section: Library
Upgrade bundled pip to 22.2.
..
.. date: 2022-07-23-10-50-05
.. gh-issue: 93899
.. nonce: VT34A5
.. section: Library
Fix check for existence of :data:`os.EFD_CLOEXEC`, :data:`os.EFD_NONBLOCK`
and :data:`os.EFD_SEMAPHORE` flags on older kernel versions where these
flags are not present. Patch by Kumar Aditya.
..
.. date: 2022-07-23-10-42-05
.. gh-issue: 95166
.. nonce: xw6p3C
.. section: Library
Fix :meth:`concurrent.futures.Executor.map` to cancel the currently waiting
on future on an error - e.g. TimeoutError or KeyboardInterrupt.
..
.. date: 2022-07-22-21-18-17
.. gh-issue: 95132
.. nonce: n9anlw
.. section: Library
Fix a :mod:`sqlite3` regression where ``*args`` and ``**kwds`` were
incorrectly relayed from :py:func:`~sqlite3.connect` to the
:class:`~sqlite3.Connection` factory. The regression was introduced in
3.11a1 with PR 24421 (:gh:`85128`). Patch by Erlend E. Aasland.`
..
.. date: 2022-07-22-17-19-57
.. gh-issue: 93157
.. nonce: RXByAk
.. section: Library
Fix :mod:`fileinput` module didn't support ``errors`` option when
``inplace`` is true.
..
.. date: 2022-07-22-09-09-08
.. gh-issue: 91212
.. nonce: 53O8Ab
.. section: Library
Fixed flickering of the turtle window when the tracer is turned off. Patch
by Shin-myoung-serp.
..
.. date: 2022-07-22-00-58-49
.. gh-issue: 95077
.. nonce: 4Z6CNC
.. section: Library
Add deprecation warning for enum ``member.member`` access (e.g.
``Color.RED.BLUE``).
..
.. date: 2022-07-21-22-59-22
.. gh-issue: 95109
.. nonce: usxA9r
.. section: Library
Ensure that timeouts scheduled with :class:`asyncio.Timeout` that have
already expired are delivered promptly.
..
.. date: 2022-07-21-19-55-49
.. gh-issue: 95105
.. nonce: BIX2Km
.. section: Library
:meth:`wsgiref.types.InputStream.__iter__` should return
``Iterator[bytes]``, not ``Iterable[bytes]``. Patch by Shantanu Jain.
..
.. date: 2022-07-20-22-49-48
.. gh-issue: 95066
.. nonce: TuCu0E
.. section: Library
Replaced assert with exception in :func:`ast.parse`, when
``feature_version`` has an invalid major version. Patch by Shantanu Jain.
..
.. date: 2022-07-20-00-23-58
.. gh-issue: 77617
.. nonce: XGaqSQ
.. section: Library
Add :mod:`sqlite3` :ref:`command-line interface <sqlite3-cli>`. Patch by
Erlend Aasland.
..
.. date: 2022-07-19-15-37-11
.. gh-issue: 95005
.. nonce: iRmZ74
.. section: Library
Replace :c:expr:`_PyAccu` with :c:expr:`_PyUnicodeWriter` in JSON encoder
and StringIO and remove the :c:expr:`_PyAccu` implementation.
..
.. date: 2022-07-17-22-31-32
.. gh-issue: 90085
.. nonce: c4FWcS
.. section: Library
Remove ``-c/--clock`` and ``-t/--time`` CLI options of :mod:`timeit`. The
options had been deprecated since Python 3.3 and the functionality was
removed in Python 3.7. Patch by Shantanu Jain.
..
.. date: 2022-07-15-08-13-51
.. gh-issue: 94857
.. nonce: 9_KvZJ
.. section: Library
Fix refleak in ``_io.TextIOWrapper.reconfigure``. Patch by Kumar Aditya.
..
.. date: 2022-07-14-00-43-52
.. gh-issue: 94821
.. nonce: e17ghU
.. section: Library
Fix binding of unix socket to empty address on Linux to use an available
address from the abstract namespace, instead of "\0".
..
.. date: 2022-07-11-10-41-48
.. gh-issue: 94736
.. nonce: EbsgeK
.. section: Library
Fix crash when deallocating an instance of a subclass of
``_multiprocessing.SemLock``. Patch by Kumar Aditya.
..
.. date: 2022-07-09-15-17-02
.. gh-issue: 81620
.. nonce: L0O_bV
.. section: Library
Add random.binomialvariate().
..
.. date: 2022-07-09-08-55-04
.. gh-issue: 74116
.. nonce: 0XwYC1
.. section: Library
Allow :meth:`asyncio.StreamWriter.drain` to be awaited concurrently by
multiple tasks. Patch by Kumar Aditya.
..
.. date: 2022-07-08-17-49-12
.. gh-issue: 87822
.. nonce: F9dzkf
.. section: Library
When called with ``capture_locals=True``, the :mod:`traceback` module
functions swallow exceptions raised from calls to ``repr()`` on local
variables of frames. This is in order to prioritize the original exception
over rendering errors. An indication of the failure is printed in place of
the missing value. (Patch by Simon-Martin Schroeder).
..
.. date: 2022-07-08-08-39-35
.. gh-issue: 88050
.. nonce: 0aOC_m
.. section: Library
Fix :mod:`asyncio` subprocess transport to kill process cleanly when process
is blocked and avoid ``RuntimeError`` when loop is closed. Patch by Kumar
Aditya.
..
.. date: 2022-07-07-15-46-55
.. gh-issue: 94637
.. nonce: IYEiUM
.. section: Library
:meth:`SSLContext.set_default_verify_paths` now releases the GIL around
``SSL_CTX_set_default_verify_paths`` call. The function call performs I/O
and CPU intensive work.
..
.. date: 2022-07-06-22-41-51
.. gh-issue: 94309
.. nonce: _XswsX
.. section: Library
Deprecate aliases :class:`typing.Hashable` and :class:`typing.Sized`
..
.. date: 2022-07-06-21-24-03
.. gh-issue: 92546
.. nonce: s5Upkh
.. section: Library
An undocumented ``python -m pprint`` benchmark is moved into ``pprint``
suite of pyperformance. Patch by Oleg Iarygin.
..
.. date: 2022-07-06-16-01-08
.. gh-issue: 94607
.. nonce: Q6RYfz
.. section: Library
Fix subclassing complex generics with type variables in :mod:`typing`.
Previously an error message saying ``Some type variables ... are not listed
in Generic[...]`` was shown. :mod:`typing` no longer populates
``__parameters__`` with the ``__parameters__`` of a Python class.
..
.. date: 2022-07-06-14-57-33
.. gh-issue: 94619
.. nonce: PRqKVX
.. section: Library
Remove the long-deprecated ``module_repr()`` from :mod:`importlib`.
..
.. date: 2022-07-06-14-45-12
.. gh-issue: 93910
.. nonce: iZcp67
.. section: Library
The ability to access the other values of an enum on an enum (e.g.
``Color.RED.BLUE``) has been restored in order to fix a performance
regression.
..
.. date: 2022-07-06-06-02-02
.. gh-issue: 93896
.. nonce: vIgWGr
.. section: Library
Fix :func:`asyncio.run` and :class:`unittest.IsolatedAsyncioTestCase` to
always the set event loop as it was done in Python 3.10 and earlier. Patch
by Kumar Aditya.
..
.. date: 2022-07-05-17-22-00
.. gh-issue: 94343
.. nonce: kf4H5r
.. section: Library
Allow setting the attributes of ``reprlib.Repr`` during object
initialization
..
.. date: 2022-07-03-16-41-03
.. gh-issue: 94382
.. nonce: zuVZeM
.. section: Library
Port static types of ``_multiprocessing`` module to heap types. Patch by
Kumar Aditya.
..
.. date: 2022-07-03-16-26-35
.. gh-issue: 78724
.. nonce: XNiJzf
.. section: Library
Fix crash in :class:`struct.Struct` when it was not completely initialized
by initializing it in :meth:`~object.__new__``. Patch by Kumar Aditya.
..
.. date: 2022-07-02-19-46-30
.. gh-issue: 94510
.. nonce: xOatDC
.. section: Library
Re-entrant calls to :func:`sys.setprofile` and :func:`sys.settrace` now
raise :exc:`RuntimeError`. Patch by Pablo Galindo.
..
.. date: 2022-06-29-09-48-37
.. gh-issue: 92336
.. nonce: otA6c6
.. section: Library
Fix bug where :meth:`linecache.getline` fails on bad files with
:exc:`UnicodeDecodeError` or :exc:`SyntaxError`. It now returns an empty
string as per the documentation.
..
.. date: 2022-06-29-04-42-56
.. gh-issue: 94398
.. nonce: YOq_bJ
.. section: Library
Once a :class:`asyncio.TaskGroup` has started shutting down (i.e., at least
one task has failed and the task group has started cancelling the remaining
tasks), it should not be possible to add new tasks to the task group.
..
.. date: 2022-06-28-14-41-22
.. gh-issue: 94383
.. nonce: CXnquo
.. section: Library
:mod:`xml.etree`: Remove the ``ElementTree.Element.copy()`` method of the
pure Python implementation, deprecated in Python 3.10, use the
:func:`copy.copy` function instead. The C implementation of :mod:`xml.etree`
has no ``copy()`` method, only a ``__copy__()`` method. Patch by Victor
Stinner.
..
.. date: 2022-06-28-14-29-21
.. gh-issue: 94379
.. nonce: RrgKfh
.. section: Library
:mod:`zipimport`: Remove ``find_loader()`` and ``find_module()`` methods,
deprecated in Python 3.10: use the ``find_spec()`` method instead. See
:pep:`451` for the rationale. Patch by Victor Stinner.
..
.. date: 2022-06-28-00-24-48
.. gh-issue: 94352
.. nonce: JY1Ayt
.. section: Library
:func:`shlex.split`: Passing ``None`` for *s* argument now raises an
exception, rather than reading :data:`sys.stdin`. The feature was deprecated
in Python 3.9. Patch by Victor Stinner.
..
.. date: 2022-06-27-10-33-18
.. gh-issue: 94318
.. nonce: jR4_QV
.. section: Library
Strip trailing spaces in :mod:`pydoc` text output.
..
.. date: 2022-06-26-10-59-15
.. gh-issue: 89988
.. nonce: K8rnmt
.. section: Library
Fix memory leak in :class:`pickle.Pickler` when looking up
:attr:`dispatch_table`. Patch by Kumar Aditya.
..
.. date: 2022-06-25-23-44-44
.. gh-issue: 90016
.. nonce: EB409s
.. section: Library
Deprecate :mod:`sqlite3` :ref:`default adapters and converters
<sqlite3-default-converters>`. Patch by Erlend E. Aasland.
..
.. date: 2022-06-25-16-27-02
.. gh-issue: 94254
.. nonce: beP16v
.. section: Library
Fixed types of :mod:`struct` module to be immutable. Patch by Kumar Aditya.
..
.. date: 2022-06-25-13-38-53
.. gh-issue: 93259
.. nonce: FAGw-2
.. section: Library
Now raise ``ValueError`` when ``None`` or an empty string are passed to
``Distribution.from_name`` (and other callers).
..
.. date: 2022-06-25-09-12-23
.. gh-issue: 74696
.. nonce: fxC9ua
.. section: Library
:func:`shutil.make_archive` now passes the *root_dir* argument to custom
archivers which support it.
..
.. date: 2022-06-24-20-00-57
.. gh-issue: 94216
.. nonce: hxnQPu
.. section: Library
The :mod:`dis` module now has the opcodes for pseudo instructions (those
which are used by the compiler during code generation but then removed or
replaced by real opcodes before the final bytecode is emitted).
..
.. date: 2022-06-24-19-40-40
.. gh-issue: 93096
.. nonce: 3RlK2d
.. section: Library
Removed undocumented ``python -m codecs``. Use ``python -m unittest
test.test_codecs.EncodedFileTest`` instead.
..
.. date: 2022-06-24-19-23-59
.. gh-issue: 94207
.. nonce: VhS1eS
.. section: Library
Made :class:`_struct.Struct` GC-tracked in order to fix a reference leak in
the :mod:`_struct` module.
..
.. date: 2022-06-24-19-16-09
.. gh-issue: 93096
.. nonce: r1_oIc
.. section: Library
Removed undocumented ``-t`` argument of ``python -m base64``. Use ``python
-m unittest test.test_base64.LegacyBase64TestCase.test_encodebytes``
instead.
..
.. date: 2022-06-24-18-20-42
.. gh-issue: 94226
.. nonce: 8ZL4Fm
.. section: Library
Remove the :func:`locale.format` function, deprecated in Python 3.7: use
:func:`locale.format_string` instead. Patch by Victor Stinner.
..
.. date: 2022-06-24-17-11-33
.. gh-issue: 94199
.. nonce: 7releN
.. section: Library
Remove the :func:`ssl.match_hostname` function. The
:func:`ssl.match_hostname` was deprecated in Python 3.7. OpenSSL performs
hostname matching since Python 3.7, Python no longer uses the
:func:`ssl.match_hostname` function. Patch by Victor Stinner.
..
.. date: 2022-06-24-14-25-26
.. gh-issue: 94214
.. nonce: 03pXR5
.. section: Library
Document the ``context`` object used in the ``venv.EnvBuilder`` class, and
add the new environment's library path to it.
..
.. date: 2022-06-24-10-39-56
.. gh-issue: 94199
.. nonce: MIuckY
.. section: Library
Remove the :func:`ssl.wrap_socket` function, deprecated in Python 3.7:
instead, create a :class:`ssl.SSLContext` object and call its
:class:`ssl.SSLContext.wrap_socket` method. Any package that still uses
:func:`ssl.wrap_socket` is broken and insecure. The function neither sends a
SNI TLS extension nor validates server hostname. Code is subject to `CWE-295
<https://cwe.mitre.org/data/definitions/295.html>`_: Improper Certificate
Validation. Patch by Victor Stinner.
..
.. date: 2022-06-24-10-29-19
.. gh-issue: 94199
.. nonce: pfehmz
.. section: Library
Remove the :func:`ssl.RAND_pseudo_bytes` function, deprecated in Python 3.6:
use :func:`os.urandom` or :func:`ssl.RAND_bytes` instead. Patch by Victor
Stinner.
..
.. date: 2022-06-24-10-18-59
.. gh-issue: 94199
.. nonce: kYOo8g
.. section: Library
:mod:`hashlib`: Remove the pure Python implementation of
:func:`hashlib.pbkdf2_hmac()`, deprecated in Python 3.10. Python 3.10 and
newer requires OpenSSL 1.1.1 (:pep:`644`): this OpenSSL version provides a C
implementation of :func:`~hashlib.pbkdf2_hmac()` which is faster. Patch by
Victor Stinner.
..
.. date: 2022-06-24-09-41-41
.. gh-issue: 94196
.. nonce: r2KyfS
.. section: Library
:mod:`gzip`: Remove the ``filename`` attribute of :class:`gzip.GzipFile`,
deprecated since Python 2.6, use the :attr:`~gzip.GzipFile.name` attribute
instead. In write mode, the ``filename`` attribute added ``'.gz'`` file
extension if it was not present. Patch by Victor Stinner.
..
.. date: 2022-06-24-08-49-47
.. gh-issue: 94182
.. nonce: Wknau0
.. section: Library
run the :class:`asyncio.PidfdChildWatcher` on the running loop, this allows
event loops to run subprocesses when there is no default event loop running
on the main thread
..
.. date: 2022-06-23-14-35-10
.. gh-issue: 94169
.. nonce: jeba90
.. section: Library
Remove ``io.OpenWrapper`` and ``_pyio.OpenWrapper``, deprecated in Python
3.10: just use :func:`open` instead. The :func:`open` (:func:`io.open`)
function is a built-in function. Since Python 3.10, :func:`_pyio.open` is
also a static method. Patch by Victor Stinner.
..
.. date: 2022-06-23-13-12-05
.. gh-issue: 91742
.. nonce: sNytVX
.. section: Library
Fix :mod:`pdb` crash after jump caused by a null pointer dereference. Patch
by Kumar Aditya.
..
.. date: 2022-06-22-11-16-11
.. gh-issue: 94101
.. nonce: V9vDG8
.. section: Library
Manual instantiation of :class:`ssl.SSLSession` objects is no longer allowed
as it lead to misconfigured instances that crashed the interpreter when
attributes where accessed on them.
..
.. date: 2022-06-21-11-40-31
.. gh-issue: 84753
.. nonce: FW1pxO
.. section: Library
:func:`inspect.iscoroutinefunction`, :func:`inspect.isgeneratorfunction`,
and :func:`inspect.isasyncgenfunction` now properly return ``True`` for
duck-typed function-like objects like instances of
:class:`unittest.mock.AsyncMock`.
This makes :func:`inspect.iscoroutinefunction` consistent with the behavior
of :func:`asyncio.iscoroutinefunction`. Patch by Mehdi ABAAKOUK.
..
.. date: 2022-06-20-23-14-43
.. gh-issue: 94028
.. nonce: UofEcX
.. section: Library
Fix a regression in the :mod:`sqlite3` where statement objects were not
properly cleared and reset after use in cursor iters. The regression was
introduced by PR 27884 in Python 3.11a1. Patch by Erlend E. Aasland.
..
.. date: 2022-06-18-15-06-54
.. gh-issue: 93973
.. nonce: 4y6UQT
.. section: Library
Add keyword argument ``all_errors`` to ``asyncio.create_connection`` so that
multiple connection errors can be raised as an ``ExceptionGroup``.
..
.. date: 2022-06-17-16-00-55
.. gh-issue: 93963
.. nonce: 8YYZ-2
.. section: Library
Officially deprecate from ``importlib.abc`` classes moved to
``importlib.resources.abc``.
..
.. date: 2022-06-17-12-02-30
.. gh-issue: 93858
.. nonce: R49ARc
.. section: Library
Prevent error when activating venv in nested fish instances.
..
.. date: 2022-06-16-11-16-53
.. gh-issue: 93820
.. nonce: 00X0Y5
.. section: Library
Pickle :class:`enum.Flag` by name.
..
.. date: 2022-06-16-09-24-50
.. gh-issue: 93847
.. nonce: kuv8bN
.. section: Library
Fix repr of enum of generic aliases.
..
.. date: 2022-06-15-21-35-11
.. gh-issue: 91404
.. nonce: 39TZzW
.. section: Library
Revert the :mod:`re` memory leak when a match is terminated by a signal or
memory allocation failure as the implemented fix caused a major performance
regression.
..
.. date: 2022-06-15-21-28-16
.. gh-issue: 83499
.. nonce: u3DQJ-
.. section: Library
Fix double closing of file description in :mod:`tempfile`.
..
.. date: 2022-06-15-21-20-02
.. gh-issue: 93820
.. nonce: FAMLY8
.. section: Library
Fixed a regression when :func:`copy.copy`-ing :class:`enum.Flag` with
multiple flag members.
..
.. date: 2022-06-11-13-32-17
.. gh-issue: 79512
.. nonce: A1KTDr
.. section: Library
Fixed names and ``__module__`` value of :mod:`weakref` classes
:class:`~weakref.ReferenceType`, :class:`~weakref.ProxyType`,
:class:`~weakref.CallableProxyType`. It makes them pickleable.
..
.. date: 2022-06-09-17-15-26
.. gh-issue: 91389
.. nonce: OE4vS5
.. section: Library
Fix an issue where :mod:`dis` utilities could report missing or incorrect
position information in the presence of ``CACHE`` entries.
..
.. date: 2022-06-09-14-44-21
.. gh-issue: 93626
.. nonce: sfghs46
.. section: Library
Set ``__future__.annotations`` to have a ``None`` mandatoryRelease to
indicate that it is currently 'TBD'.
..
.. date: 2022-06-09-10-12-55
.. gh-issue: 90473
.. nonce: 683m_C
.. section: Library
Emscripten and WASI have no home directory and cannot provide :pep:`370`
user site directory.
..
.. date: 2022-06-08-20-11-02
.. gh-issue: 90494
.. nonce: LIZT85
.. section: Library
:func:`copy.copy` and :func:`copy.deepcopy` now always raise a TypeError if
``__reduce__()`` returns a tuple with length 6 instead of silently ignore
the 6th item or produce incorrect result.
..
.. date: 2022-06-07-14-53-46
.. gh-issue: 90549
.. nonce: T4FMKY
.. section: Library
Fix a multiprocessing bug where a global named resource (such as a
semaphore) could leak when a child process is spawned (as opposed to
forked).
..
.. date: 2022-06-06-13-19-43
.. gh-issue: 93521
.. nonce: _vE8m9
.. section: Library
Fixed a case where dataclasses would try to add ``__weakref__`` into the
``__slots__`` for a dataclass that specified ``weakref_slot=True`` when it
was already defined in one of its bases. This resulted in a ``TypeError``
upon the new class being created.
..
.. date: 2022-06-06-12-58-27
.. gh-issue: 79579
.. nonce: e8rB-M
.. section: Library
:mod:`sqlite3` now correctly detects DML queries with leading comments.
Patch by Erlend E. Aasland.
..
.. date: 2022-06-05-22-22-42
.. gh-issue: 93421
.. nonce: 43UO_8
.. section: Library
Update :data:`sqlite3.Cursor.rowcount` when a DML statement has run to
completion. This fixes the row count for SQL queries like ``UPDATE ...
RETURNING``. Patch by Erlend E. Aasland.
..
.. date: 2022-06-04-00-11-54
.. gh-issue: 93475
.. nonce: vffFw1
.. section: Library
Expose ``FICLONE`` and ``FICLONERANGE`` constants in :mod:`fcntl`. Patch by
Illia Volochii.
..
.. date: 2022-06-03-22-13-28
.. gh-issue: 93370
.. nonce: tjfu9L
.. section: Library
Deprecate :data:`sqlite3.version` and :data:`sqlite3.version_info`.
..
.. date: 2022-06-02-08-40-58
.. gh-issue: 91810
.. nonce: Gtk44w
.. section: Library
Suppress writing an XML declaration in open files in ``ElementTree.write()``
with ``encoding='unicode'`` and ``xml_declaration=None``.
..
.. date: 2022-06-01-11-24-13
.. gh-issue: 91162
.. nonce: NxvU_u
.. section: Library
Support splitting of unpacked arbitrary-length tuple over ``TypeVar`` and
``TypeVarTuple`` parameters. For example:
* ``A[T, *Ts][*tuple[int, ...]]`` -> ``A[int, *tuple[int, ...]]``
* ``A[*Ts, T][*tuple[int, ...]]`` -> ``A[*tuple[int, ...], int]``
..
.. date: 2022-05-31-14-58-40
.. gh-issue: 93353
.. nonce: 9Hvm6o
.. section: Library
Fix the :func:`importlib.resources.as_file` context manager to remove the
temporary file if destroyed late during Python finalization: keep a local
reference to the :func:`os.remove` function. Patch by Victor Stinner.
..
.. date: 2022-05-30-21-42-50
.. gh-issue: 83658
.. nonce: 01Ntx0
.. section: Library
Make :class:`multiprocessing.Pool` raise an exception if
``maxtasksperchild`` is not ``None`` or a positive int.
..
.. date: 2022-05-28-08-02-55
.. gh-issue: 93312
.. nonce: HY0Uzj
.. section: Library
Add :data:`os.PIDFD_NONBLOCK` flag to open a file descriptor for a process
with :func:`os.pidfd_open` in non-blocking mode. Patch by Kumar Aditya.
..
.. date: 2022-05-27-22-17-11
.. gh-issue: 88123
.. nonce: mkYl5q
.. section: Library
Implement Enum __contains__ that returns True or False to replace the
deprecated behaviour that would sometimes raise a TypeError.
..
.. date: 2022-05-27-13-18-18
.. gh-issue: 93297
.. nonce: e2zuHz
.. section: Library
Make asyncio task groups prevent child tasks from being GCed
..
.. date: 2022-05-27-10-52-06
.. gh-issue: 85308
.. nonce: K6r-tJ
.. section: Library
Changed :class:`argparse.ArgumentParser` to use :term:`filesystem encoding
and error handler` instead of default text encoding to read arguments from
file (e.g. ``fromfile_prefix_chars`` option). This change affects Windows;
argument file should be encoded with UTF-8 instead of ANSI Codepage.
..
.. date: 2022-05-26-23-10-55
.. gh-issue: 93156
.. nonce: 4XfDVN
.. section: Library
Accessing the :attr:`pathlib.PurePath.parents` sequence of an absolute path
using negative index values produced incorrect results.
..
.. date: 2022-05-26-09-24-41
.. gh-issue: 93162
.. nonce: W1VuhU
.. section: Library
Add the ability for :func:`logging.config.dictConfig` to usefully configure
:class:`~logging.handlers.QueueHandler` and
:class:`~logging.handlers.QueueListener` as a pair, and add
:func:`logging.getHandlerByName` and :func:`logging.getHandlerNames` APIs to
allow access to handlers by name.
..
.. date: 2022-05-26-08-41-34
.. gh-issue: 93243
.. nonce: uw6x5z
.. section: Library
The :mod:`smtpd` module was removed per the schedule in :pep:`594`.
..
.. date: 2022-05-25-22-09-38
.. gh-issue: 92886
.. nonce: ylwDSc
.. section: Library
Replace ``assert`` statements with ``raise AssertionError()`` in
:class:`~wsgiref.BaseHandler` so that the tested behaviour is maintained
running with optimizations ``(-O)``.
..
.. date: 2022-05-25-15-57-39
.. gh-issue: 90155
.. nonce: YMstB5
.. section: Library
Fix broken :class:`asyncio.Semaphore` when acquire is cancelled.
..
.. date: 2022-05-25-02-45-41
.. gh-issue: 90817
.. nonce: yxANgU
.. section: Library
The :func:`locale.resetlocale` function is deprecated and will be removed in
Python 3.13. Use ``locale.setlocale(locale.LC_ALL, "")`` instead. Patch by
Victor Stinner.
..
.. date: 2022-05-25-00-21-28
.. gh-issue: 91513
.. nonce: 9VyCT4
.. section: Library
Added ``taskName`` attribute to :mod:`logging` module for use with
:mod:`asyncio` tasks.
..
.. date: 2022-05-24-11-19-04
.. gh-issue: 74696
.. nonce: -cnf-A
.. section: Library
:func:`shutil.make_archive` no longer temporarily changes the current
working directory during creation of standard ``.zip`` or tar archives.
..
.. date: 2022-05-24-10-59-02
.. gh-issue: 92728
.. nonce: zxTifq
.. section: Library
The :func:`re.template` function and the corresponding :const:`re.TEMPLATE`
and :const:`re.T` flags are restored after they were removed in 3.11.0b1,
but they are now deprecated, so they might be removed from Python 3.13.
..
.. date: 2022-05-22-23-46-18
.. gh-issue: 93033
.. nonce: wZfiL-
.. section: Library
Search in some strings (platform dependent i.e [U+0xFFFF, U+0x0100] on
Windows or [U+0xFFFFFFFF, U+0x00010000] on Linux 64-bit) are now up to 10
times faster.
..
.. date: 2022-05-22-16-08-01
.. gh-issue: 89973
.. nonce: jc-Q4g
.. section: Library
Fix :exc:`re.error` raised in :mod:`fnmatch` if the pattern contains a
character range with upper bound lower than lower bound (e.g. ``[c-a]``).
Now such ranges are interpreted as empty ranges.
..
.. date: 2022-05-21-13-16-16
.. gh-issue: 93044
.. nonce: eJ_XkZ
.. section: Library
No longer convert the database argument of :func:`sqlite3.connect` to bytes
before passing it to the factory.
..
.. date: 2022-05-20-15-52-43
.. gh-issue: 93010
.. nonce: WF-cAc
.. section: Library
In a very special case, the email package tried to append the nonexistent
``InvalidHeaderError`` to the defect list. It should have been
``InvalidHeaderDefect``.
..
.. date: 2022-05-19-22-34-42
.. gh-issue: 92986
.. nonce: e6uKxj
.. section: Library
Fix :func:`ast.unparse` when ``ImportFrom.level`` is None
..
.. date: 2022-05-19-17-49-58
.. gh-issue: 92932
.. nonce: o2peTh
.. section: Library
Now :func:`~dis.dis` and :func:`~dis.get_instructions` handle operand values
for instructions prefixed by ``EXTENDED_ARG_QUICK``. Patch by Sam Gross and
Dong-hee Na.
..
.. date: 2022-05-19-13-33-18
.. gh-issue: 92675
.. nonce: ZeerMZ
.. section: Library
Fix :func:`venv.ensure_directories` to accept :class:`pathlib.Path`
arguments in addition to :class:`str` paths. Patch by David Foster.
..
.. date: 2022-05-18-21-04-09
.. gh-issue: 87901
.. nonce: lnf041
.. section: Library
Removed the ``encoding`` argument from :func:`os.popen` that was added in
3.11b1.
..
.. date: 2022-05-18-17-18-41
.. gh-issue: 91922
.. nonce: DwWIsJ
.. section: Library
Fix function :func:`sqlite.connect` and the :class:`sqlite.Connection`
constructor on non-UTF-8 locales. Also, they now support bytes paths
non-decodable with the current FS encoding.
..
.. date: 2022-05-17-06-27-39
.. gh-issue: 92869
.. nonce: t8oBkw
.. section: Library
Added :class:`~ctypes.c_time_t` to :mod:`ctypes`, which has the same size as
the :c:type:`time_t` type in C.
..
.. date: 2022-05-16-14-35-39
.. gh-issue: 92839
.. nonce: owSMyo
.. section: Library
Fixed crash resulting from calling bisect.insort() or bisect.insort_left()
with the key argument not equal to None.
..
.. date: 2022-05-14-11-41-23
.. gh-issue: 90473
.. nonce: kPdOZl
.. section: Library
:mod:`subprocess` now fails early on Emscripten and WASI platforms to work
around missing :func:`os.pipe` on WASI.
..
.. date: 2022-05-14-09-01-38
.. gh-issue: 89325
.. nonce: ys-2BZ
.. section: Library
Removed many old deprecated :mod:`unittest` features:
:class:`~unittest.TestCase` method aliases, undocumented and broken
:class:`~unittest.TestCase` method ``assertDictContainsSubset``,
undocumented :meth:`TestLoader.loadTestsFromModule
<unittest.TestLoader.loadTestsFromModule>` parameter *use_load_tests*, and
an underscored alias of the :class:`~unittest.TextTestResult` class.
..
.. date: 2022-05-12-15-19-00
.. gh-issue: 92734
.. nonce: d0wjDt
.. section: Library
Allow multi-element reprs emitted by :mod:`reprlib` to be pretty-printed
using configurable indentation.
..
.. date: 2022-05-11-19-33-27
.. gh-issue: 92671
.. nonce: KE4v6a
.. section: Library
Fixed :func:`ast.unparse` for empty tuples in the assignment target context.
..
.. date: 2022-05-11-14-34-09
.. gh-issue: 91581
.. nonce: glkou2
.. section: Library
:meth:`~datetime.datetime.utcfromtimestamp` no longer attempts to resolve
``fold`` in the pure Python implementation, since the fold is never 1 in
UTC. In addition to being slightly faster in the common case, this also
prevents some errors when the timestamp is close to :attr:`datetime.min
<datetime.datetime.min>`. Patch by Paul Ganssle.
..
.. date: 2022-05-11-10-06-31
.. gh-issue: 86388
.. nonce: 7ivUtT
.. section: Library
Removed randrange() functionality deprecated since Python 3.10. Formerly,
randrange(10.0) losslessly converted to randrange(10). Now, it raises a
TypeError. Also, the exception raised for non-integral values such as
randrange(10.5) or randrange('10') has been changed from ValueError to
TypeError.
..
.. date: 2022-05-10-16-30-40
.. gh-issue: 90385
.. nonce: 1_wBRQ
.. section: Library
Add :meth:`pathlib.Path.walk` as an alternative to :func:`os.walk`.
..
.. date: 2022-05-10-07-57-27
.. gh-issue: 92550
.. nonce: Rk_UzM
.. section: Library
Fix :meth:`pathlib.Path.rglob` for empty pattern.
..
.. date: 2022-05-09-22-27-11
.. gh-issue: 92591
.. nonce: V7RCk2
.. section: Library
Allow :mod:`logging` filters to return a :class:`logging.LogRecord` instance
so that filters attached to :class:`logging.Handler`\ s can enrich records
without side effects on other handlers.
..
.. date: 2022-05-09-21-31-41
.. gh-issue: 92445
.. nonce: tJosdm
.. section: Library
Fix a bug in :mod:`argparse` where ``nargs="*"`` would raise an error
instead of returning an empty list when 0 arguments were supplied if choice
was also defined in ``parser.add_argument``.
..
.. date: 2022-05-09-11-55-04
.. gh-issue: 92547
.. nonce: CzVZft
.. section: Library
Remove undocumented :mod:`sqlite3` features deprecated in Python 3.10:
* ``sqlite3.enable_shared_cache()``
* ``sqlite3.OptimizedUnicode``
Patch by Erlend E. Aasland.
..
.. date: 2022-05-09-09-28-02
.. gh-issue: 92530
.. nonce: M4Q1RS
.. section: Library
Fix an issue that occurred after interrupting
:func:`threading.Condition.notify`.
..
.. date: 2022-05-09-01-27-25
.. gh-issue: 92531
.. nonce: vV7S_O
.. section: Library
The statistics.median_grouped() function now always return a float.
Formerly, it did not convert the input type when for sequences of length
one.
..
.. date: 2022-05-08-19-21-14
.. gh-issue: 84131
.. nonce: rG5kI7
.. section: Library
The :class:`pathlib.Path` deprecated method ``link_to`` has been removed.
Use 3.10's :meth:`~pathlib.Path.hardlink_to` method instead as its semantics
are consistent with that of :meth:`~pathlib.Path.symlink_to`.
..
.. date: 2022-05-08-18-51-14
.. gh-issue: 89336
.. nonce: TL6ip7
.. section: Library
Removed :mod:`configparser` module APIs: the ``SafeConfigParser`` class
alias, the ``ParsingError.filename`` property and parameter, and the
``ConfigParser.readfp`` method, all of which were deprecated since Python
3.2.
..
.. date: 2022-05-06-13-00-57
.. gh-issue: 92391
.. nonce: s-Lase
.. section: Library
Add :meth:`~object.__class_getitem__` to :class:`csv.DictReader` and
:class:`csv.DictWriter`, allowing them to be parameterized at runtime. Patch
by Marc Mueller.
..
.. date: 2022-04-26-18-37-24
.. gh-issue: 91968
.. nonce: fuuH1_
.. section: Library
Add ``SO_RTABLE`` and ``SO_USER_COOKIE`` constants to :mod:`socket`.
..
.. date: 2022-04-25-10-23-01
.. gh-issue: 91810
.. nonce: DOHa6B
.. section: Library
:class:`~xml.etree.ElementTree.ElementTree` method
:meth:`~xml.etree.ElementTree.ElementTree.write` and function
:func:`~xml.etree.ElementTree.tostring` now use the text file's encoding
("UTF-8" if not available) instead of locale encoding in XML declaration
when ``encoding="unicode"`` is specified.
..
.. date: 2022-04-24-22-26-45
.. gh-issue: 81790
.. nonce: M5Rvpm
.. section: Library
:func:`os.path.splitdrive` now understands DOS device paths with UNC links
(beginning ``\\?\UNC\``). Contributed by Barney Gale.
..
.. date: 2022-04-21-19-14-29
.. gh-issue: 91760
.. nonce: 54AR-m
.. section: Library
Apply more strict rules for numerical group references and group names in
regular expressions. Only sequence of ASCII digits is now accepted as a
numerical reference. The group name in bytes patterns and replacement
strings can now only contain ASCII letters and digits and underscore.
..
.. date: 2022-04-15-22-07-36
.. gh-issue: 90622
.. nonce: 0C6l8h
.. section: Library
Worker processes for :class:`concurrent.futures.ProcessPoolExecutor` are no
longer spawned on demand (a feature added in 3.9) when the multiprocessing
context start method is ``"fork"`` as that can lead to deadlocks in the
child processes due to a fork happening while threads are running.
..
.. date: 2022-04-15-17-38-55
.. gh-issue: 91577
.. nonce: Ah7cLL
.. section: Library
Move imports in :class:`~multiprocessing.SharedMemory` methods to module
level so that they can be executed late in python finalization.
..
.. date: 2022-04-15-13-16-25
.. gh-issue: 91581
.. nonce: 9OGsrN
.. section: Library
Remove an unhandled error case in the C implementation of calls to
:meth:`datetime.fromtimestamp <datetime.datetime.fromtimestamp>` with no
time zone (i.e. getting a local time from an epoch timestamp). This should
have no user-facing effect other than giving a possibly more accurate error
message when called with timestamps that fall on 10000-01-01 in the local
time. Patch by Paul Ganssle.
..
.. date: 2022-04-15-11-29-38
.. gh-issue: 91539
.. nonce: 7WgVuA
.. section: Library
Improve performance of ``urllib.request.getproxies_environment`` when there
are many environment variables
..
.. date: 2022-04-14-08-37-16
.. gh-issue: 91524
.. nonce: g8PiIu
.. section: Library
Speed up the regular expression substitution (functions :func:`re.sub` and
:func:`re.subn` and corresponding :class:`re.Pattern` methods) for
replacement strings containing group references by 2--3 times.
..
.. date: 2022-04-12-18-05-40
.. gh-issue: 91447
.. nonce: N_Fs4H
.. section: Library
Fix findtext in the xml module to only give an empty string when the text
attribute is set to None.
..
.. date: 2022-04-11-16-55-41
.. gh-issue: 91456
.. nonce: DK3KKl
.. section: Library
Deprecate current default auto() behavior: In 3.13 the default will be for
for auto() to always return the largest member value incremented by 1, and
to raise if incompatible value types are used.
..
.. bpo: 47231
.. date: 2022-04-08-22-12-11
.. nonce: lvyglt
.. section: Library
Fixed an issue with inconsistent trailing slashes in tarfile longname
directories.
..
.. bpo: 39064
.. date: 2022-04-03-19-40-09
.. nonce: 76PbIz
.. section: Library
:class:`zipfile.ZipFile` now raises :exc:`zipfile.BadZipFile` instead of
``ValueError`` when reading a corrupt zip file in which the central
directory offset is negative.
..
.. bpo: 41287
.. date: 2022-04-03-11-25-02
.. nonce: 8CTdwf
.. section: Library
Fix handling of the ``doc`` argument in subclasses of :func:`property`.
..
.. date: 2022-04-01-12-35-44
.. gh-issue: 90005
.. nonce: pvaLHQ
.. section: Library
:mod:`ctypes` dependency ``libffi`` is now detected with ``pkg-config``.
..
.. bpo: 32547
.. date: 2022-04-01-09-43-54
.. nonce: NIUiNC
.. section: Library
The constructors for :class:`~csv.DictWriter` and :class:`~csv.DictReader`
now coerce the ``fieldnames`` argument to a :class:`list` if it is an
iterator.
..
.. bpo: 35540
.. date: 2022-03-22-18-28-55
.. nonce: nyijX9
.. section: Library
Fix :func:`dataclasses.asdict` crash when :class:`collections.defaultdict`
is present in the attributes.
..
.. bpo: 47063
.. date: 2022-03-19-04-41-42
.. nonce: nwRfUo
.. section: Library
Add an index_pages parameter to support using non-default index page names.
..
.. bpo: 47025
.. date: 2022-03-16-14-24-14
.. nonce: qtT3CE
.. section: Library
Drop support for :class:`bytes` on :attr:`sys.path`.
..
.. bpo: 46951
.. date: 2022-03-08-04-46-44
.. nonce: SWAz97
.. section: Library
Order the contents of zipapp archives, to make builds more reproducible.
..
.. bpo: 42777
.. date: 2022-02-21-01-37-00
.. nonce: nWK3E6
.. section: Library
Implement :meth:`pathlib.Path.is_mount` for Windows paths.
..
.. bpo: 46755
.. date: 2022-02-15-12-40-48
.. nonce: zePJfx
.. section: Library
In :class:`QueueHandler`, clear ``stack_info`` from :class:`LogRecord` to
prevent stack trace from being written twice.
..
.. bpo: 45393
.. date: 2022-02-09-23-44-27
.. nonce: 9v5Y8U
.. section: Library
Fix the formatting for ``await x`` and ``not x`` in the operator precedence
table when using the :func:`help` system.
..
.. bpo: 46642
.. date: 2022-02-05-18-46-54
.. nonce: YI6nHQ
.. section: Library
Improve error message when trying to subclass an instance of
:data:`typing.TypeVar`, :data:`typing.ParamSpec`,
:data:`typing.TypeVarTuple`, etc. Based on patch by Gregory Beauregard.
..
.. bpo: 46364
.. date: 2022-01-14-10-49-20
.. nonce: SzhlU9
.. section: Library
Restrict use of sockets instead of pipes for stdin of subprocesses created
by :mod:`asyncio` to AIX platform only.
..
.. bpo: 28249
.. date: 2022-01-09-14-23-00
.. nonce: 4dzB80
.. section: Library
Set :attr:`doctest.DocTest.lineno` to ``None`` when object does not have
:attr:`__doc__`.
..
.. bpo: 46197
.. date: 2022-01-03-15-07-06
.. nonce: Z0djv6
.. section: Library
Fix :mod:`ensurepip` environment isolation for subprocess running ``pip``.
..
.. bpo: 45924
.. date: 2021-12-27-15-32-15
.. nonce: 0ZpHX2
.. section: Library
Fix :mod:`asyncio` incorrect traceback when future's exception is raised
multiple times. Patch by Kumar Aditya.
..
.. bpo: 45046
.. date: 2021-08-29-19-59-16
.. nonce: eGq0NC
.. section: Library
Add support of context managers in :mod:`unittest`: methods
:meth:`~unittest.TestCase.enterContext` and
:meth:`~unittest.TestCase.enterClassContext` of class
:class:`~unittest.TestCase`, method
:meth:`~unittest.IsolatedAsyncioTestCase.enterAsyncContext` of class
:class:`~unittest.IsolatedAsyncioTestCase` and function
:func:`unittest.enterModuleContext`.
..
.. bpo: 44173
.. date: 2021-08-27-18-07-35
.. nonce: oW92Ev
.. section: Library
Enable fast seeking of uncompressed unencrypted :class:`zipfile.ZipExtFile`
..
.. bpo: 42627
.. date: 2021-05-22-07-58-59
.. nonce: EejtD0
.. section: Library
Fix incorrect parsing of Windows registry proxy settings
..
.. bpo: 42047
.. date: 2020-10-15-18-37-12
.. nonce: XDdoSF
.. section: Library
Add :func:`threading.get_native_id` support for DragonFly BSD. Patch by
David Carlier.
..
.. bpo: 14243
.. date: 2020-09-28-04-56-04
.. nonce: YECnxv
.. section: Library
The :class:`tempfile.NamedTemporaryFile` function has a new optional
parameter *delete_on_close*
..
.. bpo: 41246
.. date: 2020-07-08-20-32-13
.. nonce: 2trYf3
.. section: Library
Give the same callback function for when the overlapped operation is done to
the functions ``recv``, ``recv_into``, ``recvfrom``, ``sendto``, ``send``
and ``sendfile`` inside ``IocpProactor``.
..
.. bpo: 39264
.. date: 2020-01-09-01-57-12
.. nonce: GsBL9-
.. section: Library
Fixed :meth:`collections.UserDict.get` to not call :meth:`__missing__` when
a value is not found. This matches the behavior of :class:`dict`. Patch by
Bar Harel.
..
.. bpo: 38693
.. date: 2019-11-04-22-21-27
.. nonce: w_OAov
.. section: Library
:mod:`importlib` now uses f-strings internally instead of ``str.format``.
..
.. bpo: 38267
.. date: 2019-09-25-00-37-51
.. nonce: X9Jb5V
.. section: Library
Add *timeout* parameter to :meth:`asyncio.loop.shutdown_default_executor`.
The default value is ``None``, which means the executor will be given an
unlimited amount of time. When called from :class:`asyncio.Runner` or
:func:`asyncio.run`, the default timeout is 5 minutes.
..
.. bpo: 34828
.. date: 2018-09-28-22-18-03
.. nonce: 5Zyi_S
.. section: Library
:meth:`sqlite3.Connection.iterdump` now handles databases that use
``AUTOINCREMENT`` in one or more tables.
..
.. bpo: 32990
.. date: 2018-09-23-07-47-29
.. nonce: 2FVVTU
.. section: Library
Support reading wave files with the ``WAVE_FORMAT_EXTENSIBLE`` format in the
:mod:`wave` module.
..
.. bpo: 26253
.. date: 2017-07-31-13-35-28
.. nonce: 8v_sCs
.. section: Library
Allow adjustable compression level for tarfile streams in
:func:`tarfile.open`.
..
.. date: 2022-10-16-17-34-45
.. gh-issue: 85525
.. nonce: DvkD0v
.. section: Documentation
Remove extra row
..
.. date: 2022-10-11-09-40-50
.. gh-issue: 86404
.. nonce: dEAb8W
.. section: Documentation
Deprecated tools ``make suspicious`` and ``rstlint.py`` are now removed.
They have been replaced by `spinx-lint
<https://pypi.org/project/sphinx-lint/>`_.
..
.. date: 2022-10-02-10-58-52
.. gh-issue: 97741
.. nonce: 39l023
.. section: Documentation
Fix ``!`` in c domain ref target syntax via a ``conf.py`` patch, so it works
as intended to disable ref target resolution.
..
.. date: 2022-09-01-17-03-04
.. gh-issue: 96432
.. nonce: 1EJ1-4
.. section: Documentation
Fraction literals now support whitespace around the forward slash,
``Fraction('2 / 3')``.
..
.. date: 2022-08-19-17-07-45
.. gh-issue: 96098
.. nonce: nDp43u
.. section: Documentation
Improve discoverability of the higher level concurrent.futures module by
providing clearer links from the lower level threading and multiprocessing
modules.
..
.. date: 2022-08-13-20-34-51
.. gh-issue: 95957
.. nonce: W9ZZAx
.. section: Documentation
What's New 3.11 now has instructions for how to provide compiler and linker
flags for Tcl/Tk and OpenSSL on RHEL 7 and CentOS 7.
..
.. date: 2022-08-12-01-12-52
.. gh-issue: 95588
.. nonce: PA0FI7
.. section: Documentation
Clarified the conflicting advice given in the :mod:`ast` documentation about
:func:`ast.literal_eval` being "safe" for use on untrusted input while at
the same time warning that it can crash the process. The latter statement is
true and is deemed unfixable without a large amount of work unsuitable for a
bugfix. So we keep the warning and no longer claim that ``literal_eval`` is
safe.
..
.. date: 2022-08-03-13-35-08
.. gh-issue: 91207
.. nonce: eJ4pPf
.. section: Documentation
Fix stylesheet not working in Windows CHM htmlhelp docs and add warning that
they are deprecated. Contributed by C.A.M. Gerlach.
..
.. date: 2022-07-30-00-23-11
.. gh-issue: 95454
.. nonce: we7AFm
.. section: Documentation
Replaced incorrectly written true/false values in documentiation. Patch by
Robert O'Shea
..
.. date: 2022-07-29-23-02-19
.. gh-issue: 95451
.. nonce: -tgB93
.. section: Documentation
Update library documentation with :ref:`availability information
<wasm-availability>` on WebAssembly platforms ``wasm32-emscripten`` and
``wasm32-wasi``.
..
.. date: 2022-07-29-09-04-02
.. gh-issue: 95415
.. nonce: LKTyw6
.. section: Documentation
Use consistent syntax for platform availability. The directive now supports
a content body and emits a warning when it encounters an unknown platform.
..
.. date: 2022-07-07-08-42-05
.. gh-issue: 94321
.. nonce: pmCIPb
.. section: Documentation
Document the :pep:`246` style protocol type
:class:`sqlite3.PrepareProtocol`.
..
.. date: 2022-06-19-18-18-22
.. gh-issue: 86128
.. nonce: 39DDTD
.. section: Documentation
Document a limitation in ThreadPoolExecutor where its exit handler is
executed before any handlers in atexit.
..
.. date: 2022-06-16-10-10-59
.. gh-issue: 61162
.. nonce: 1ypkG8
.. section: Documentation
Clarify :mod:`sqlite3` behavior when
:ref:`sqlite3-connection-context-manager`.
..
.. date: 2022-06-15-12-12-49
.. gh-issue: 87260
.. nonce: epyI7D
.. section: Documentation
Align :mod:`sqlite3` argument specs with the actual implementation.
..
.. date: 2022-05-29-21-22-54
.. gh-issue: 86986
.. nonce: lFXw8j
.. section: Documentation
The minimum Sphinx version required to build the documentation is now 3.2.
..
.. date: 2022-05-26-14-51-25
.. gh-issue: 88831
.. nonce: 5Cccr5
.. section: Documentation
Augmented documentation of asyncio.create_task(). Clarified the need to keep
strong references to tasks and added a code snippet detailing how to to
this.
..
.. date: 2022-05-26-11-33-23
.. gh-issue: 86438
.. nonce: kEGGmK
.. section: Documentation
Clarify that :option:`-W` and :envvar:`PYTHONWARNINGS` are matched literally
and case-insensitively, rather than as regular expressions, in
:mod:`warnings`.
..
.. date: 2022-05-20-18-42-10
.. gh-issue: 93031
.. nonce: c2RdJe
.. section: Documentation
Update tutorial introduction output to use 3.10+ SyntaxError invalid range.
..
.. date: 2022-05-18-23-58-26
.. gh-issue: 92240
.. nonce: bHvYiz
.. section: Documentation
Added release dates for "What's New in Python 3.X" for 3.0, 3.1, 3.2, 3.8
and 3.10
..
.. bpo: 47161
.. date: 2022-03-30-17-56-01
.. nonce: gesHfS
.. section: Documentation
Document that :class:`pathlib.PurePath` does not collapse initial double
slashes because they denote UNC paths.
..
.. bpo: 40838
.. date: 2022-01-13-16-03-15
.. nonce: k3NVCf
.. section: Documentation
Document that :func:`inspect.getdoc`, :func:`inspect.getmodule`, and
:func:`inspect.getsourcefile` might return ``None``.
..
.. bpo: 43689
.. date: 2021-04-01-08-09-34
.. nonce: mqCfLe
.. section: Documentation
The ``Differ`` documentation now also mentions other whitespace characters,
which make it harder to understand the diff output.
..
.. bpo: 38056
.. date: 2019-09-12-08-28-17
.. nonce: 6ktYkc
.. section: Documentation
Overhaul the :ref:`error-handlers` documentation in :mod:`codecs`.
..
.. bpo: 13553
.. date: 2017-12-10-19-13-39
.. nonce: gQbZs4
.. section: Documentation
Document tkinter.Tk args.
..
.. date: 2022-10-20-17-49-50
.. gh-issue: 95027
.. nonce: viRpJB
.. section: Tests
On Windows, when the Python test suite is run with the ``-jN`` option, the
ANSI code page is now used as the encoding for the stdout temporary file,
rather than using UTF-8 which can lead to decoding errors. Patch by Victor
Stinner.
..
.. date: 2022-09-08-18-31-26
.. gh-issue: 96624
.. nonce: 5cANM1
.. section: Tests
Fixed the failure of repeated runs of ``test.test_unittest`` caused by side
effects in ``test_dotted_but_module_not_loaded``.
..
.. date: 2022-08-22-14-59-42
.. gh-issue: 95243
.. nonce: DeD66V
.. section: Tests
Mitigate the inherent race condition from using find_unused_port() in
testSockName() by trying to find an unused port a few times before failing.
Patch by Ross Burton.
..
.. date: 2022-08-05-09-57-43
.. gh-issue: 95573
.. nonce: edMdQB
.. section: Tests
:source:`Lib/test/test_asyncio/test_ssl.py` exposed a bug in the macOS
kernel where intense concurrent load on non-blocking sockets occasionally
causes :const:`errno.ENOBUFS` ("No buffer space available") to be emitted.
FB11063974 filed with Apple, in the mean time as a workaround buffer size
used in tests on macOS is decreased to avoid intermittent failures. Patch
by Fantix King.
..
.. date: 2022-07-26-15-22-19
.. gh-issue: 95280
.. nonce: h8HvbP
.. section: Tests
Fix problem with ``test_ssl`` ``test_get_ciphers`` on systems that require
perfect forward secrecy (PFS) ciphers.
..
.. date: 2022-07-24-20-19-05
.. gh-issue: 95212
.. nonce: fHiU4e
.. section: Tests
Make multiprocessing test case ``test_shared_memory_recreate``
parallel-safe.
..
.. date: 2022-07-24-17-24-42
.. gh-issue: 95218
.. nonce: zfBLtu
.. section: Tests
Move tests for importlib.resources into test_importlib.resources.
..
.. date: 2022-07-24-16-28-31
.. gh-issue: 93963
.. nonce: UB9azu
.. section: Tests
Updated tests to use preferred location for ``importlib.resources`` ABCs.
..
.. date: 2022-07-08-12-22-00
.. gh-issue: 94675
.. nonce: IiTs5f
.. section: Tests
Add a regression test for :mod:`re` exponentional slowdown when using
rjsmin.
..
.. date: 2022-07-05-17-53-13
.. gh-issue: 91330
.. nonce: Qys5IL
.. section: Tests
Added more tests for :mod:`dataclasses` to cover behavior with data
descriptor-based fields.
..
.. date: 2022-06-27-21-27-20
.. gh-issue: 94208
.. nonce: VR6HX-
.. section: Tests
``test_ssl`` is now checking for supported TLS version and protocols in more
tests.
..
.. date: 2022-06-27-08-53-40
.. gh-issue: 94315
.. nonce: MoZT9t
.. section: Tests
Tests now check for DAC override capability instead of relying on
:func:`os.geteuid`.
..
.. date: 2022-06-21-17-37-46
.. gh-issue: 54781
.. nonce: BjVAVg
.. section: Tests
Rename test_tk to test_tkinter, and rename test_ttk_guionly to test_ttk.
Patch by Victor Stinner.
..
.. date: 2022-06-20-23-04-52
.. gh-issue: 93839
.. nonce: OE3Ybk
.. section: Tests
Move ``Lib/ctypes/test/`` to ``Lib/test/test_ctypes/``. Patch by Victor
Stinner.
..
.. date: 2022-06-17-15-20-09
.. gh-issue: 93951
.. nonce: CW1Vv4
.. section: Tests
In test_bdb.StateTestCase.test_skip, avoid including auxiliary importers.
..
.. date: 2022-06-17-13-55-11
.. gh-issue: 93957
.. nonce: X4ovYV
.. section: Tests
Provide nicer error reporting from subprocesses in
test_venv.EnsurePipTest.test_with_pip.
..
.. date: 2022-06-17-13-27-21
.. gh-issue: 93884
.. nonce: 5pvPvl
.. section: Tests
Add test cases for :c:func:`PyNumber_ToBase` that take a large number or a
non-int object as parameter.
..
.. date: 2022-06-16-21-38-18
.. gh-issue: 93852
.. nonce: U_Hl6s
.. section: Tests
test_asyncio, test_logging, test_socket and test_socketserver now create
AF_UNIX domains in the current directory to no longer fail with
``OSError("AF_UNIX path too long")`` if the temporary directory (the
:envvar:`TMPDIR` environment variable) is too long. Patch by Victor Stinner.
..
.. date: 2022-06-16-17-50-58
.. gh-issue: 93353
.. nonce: JdpATx
.. section: Tests
regrtest now checks if a test leaks temporary files or directories if run
with -jN option. Patch by Victor Stinner.
..
.. date: 2022-06-10-21-18-14
.. gh-issue: 84461
.. nonce: 9TAb26
.. section: Tests
``run_tests.py`` now handles cross compiling env vars correctly and pass
``HOSTRUNNER`` to regression tests.
..
.. date: 2022-06-08-22-32-56
.. gh-issue: 93616
.. nonce: e5Kkx2
.. section: Tests
``test_modulefinder`` now creates a temporary directory in
``ModuleFinderTest.setUp()`` instead of module scope.
..
.. date: 2022-06-08-14-17-59
.. gh-issue: 93575
.. nonce: Xb2LNB
.. section: Tests
Fix issue with test_unicode test_raiseMemError. The test case now use
``test.support.calcobjsize`` to calculate size of PyUnicode structs.
:func:`sys.getsizeof` may return different size when string has UTF-8
memory.
..
.. date: 2022-06-05-10-16-45
.. gh-issue: 90473
.. nonce: QMu7A8
.. section: Tests
WASI does not have a ``chmod(2)`` syscall. :func:`os.chmod` is now a dummy
function on WASI. Skip all tests that depend on working :func:`os.chmod`.
..
.. date: 2022-06-04-12-05-31
.. gh-issue: 90473
.. nonce: RSpjF7
.. section: Tests
Skip tests on WASI that require symlinks with absolute paths.
..
.. date: 2022-06-03-16-26-04
.. gh-issue: 57539
.. nonce: HxWgYO
.. section: Tests
Increase calendar test coverage for
:meth:`calendar.LocaleTextCalendar.formatweekday`.
..
.. date: 2022-06-03-14-18-37
.. gh-issue: 90473
.. nonce: 7iXVRK
.. section: Tests
Skip symlink tests on WASI. wasmtime uses ``openat2(2)`` with
``RESOLVE_BENEATH`` flag, which prevents symlinks with absolute paths.
..
.. date: 2022-06-03-12-22-44
.. gh-issue: 89858
.. nonce: ftBvjE
.. section: Tests
Fix ``test_embed`` for out-of-tree builds. Patch by Kumar Aditya.
..
.. date: 2022-05-25-23-07-15
.. gh-issue: 92886
.. nonce: Aki63_
.. section: Tests
Fixing tests that fail when running with optimizations (``-O``) in
``test_imaplib.py``.
..
.. date: 2022-05-25-23-00-35
.. gh-issue: 92886
.. nonce: Y-vrWj
.. section: Tests
Fixing tests that fail when running with optimizations (``-O``) in
``test_zipimport.py``
..
.. date: 2022-05-25-22-53-30
.. gh-issue: 92886
.. nonce: mIfdtz
.. section: Tests
Fixing tests that fail when running with optimizations (``-O``) in
``test_py_compile.py``
..
.. date: 2022-05-25-22-43-11
.. gh-issue: 92886
.. nonce: 9HQb9e
.. section: Tests
Fixing tests that fail when running with optimizations (``-O``) in
``test_sys_settrace.py``.
..
.. date: 2022-05-25-22-34-10
.. gh-issue: 92886
.. nonce: 1Lkt8S
.. section: Tests
Fixing tests that fail when running with optimizations (``-O``) in
``_test_multiprocessing.py``
..
.. date: 2022-05-12-05-51-06
.. gh-issue: 92670
.. nonce: 7L43Z_
.. section: Tests
Skip ``test_shutil.TestCopy.test_copyfile_nonexistent_dir`` test on AIX as
the test uses a trailing slash to force the OS consider the path as a
directory, but on AIX the trailing slash has no effect and is considered as
a file.
..
.. date: 2022-05-08-15-40-41
.. gh-issue: 92514
.. nonce: Xbf5JY
.. section: Tests
Remove unused ``test.support.BasicTestRunner``. Patch by Jelle Zijlstra.
..
.. bpo: 47016
.. date: 2022-03-14-23-28-17
.. nonce: K-t2QX
.. section: Tests
Create a GitHub Actions workflow for verifying bundled pip and setuptools.
Patch by Illia Volochii and Adam Turner.
..
.. date: 2022-09-20-12-43-44
.. gh-issue: 96761
.. nonce: IF29kR
.. section: Build
Fix the build process of clang compiler for :program:`_bootstrap_python` if
LTO optimization is applied. Patch by Matthias Görgens and Dong-hee Na.
..
.. date: 2022-09-17-11-19-24
.. gh-issue: 96883
.. nonce: p_gr62
.. section: Build
``wasm32-emscripten`` builds for browsers now include
:mod:`concurrent.futures` for :mod:`asyncio` and :mod:`unittest.mock`.
..
.. date: 2022-09-12-18-34-51
.. gh-issue: 85936
.. nonce: tX4VCU
.. section: Build
CPython now uses the ThinLTO option as the default policy if the Clang
compiler accepts the flag. Patch by Dong-hee Na.
..
.. date: 2022-09-11-14-23-49
.. gh-issue: 96729
.. nonce: W4uBWL
.. section: Build
Ensure that Windows releases built with ``Tools\msi\buildrelease.bat`` are
upgradable to and from official Python releases.
..
.. date: 2022-08-26-11-50-03
.. gh-issue: 96269
.. nonce: x_J5h0
.. section: Build
Shared module targets now depend on new ``MODULE_DEPS`` variable, which
includes ``EXPORTSYMS``. This fixes a build order issue on unsupported AIX
platform.
..
.. date: 2022-08-26-11-09-11
.. gh-issue: 84461
.. nonce: Nsdn_R
.. section: Build
``wasm32-emscripten`` platform no longer builds :mod:`resource` module,
:func:`~os.getresuid`, :func:`~os.getresgid`, and their setters. The APIs
are stubs and not functional.
..
.. date: 2022-08-15-10-56-07
.. gh-issue: 95973
.. nonce: Bsswsc
.. section: Build
Add a new ``--with-dsymutil`` configure option to to link debug information
in macOS. Patch by Pablo Galindo.
..
.. date: 2022-08-12-13-06-03
.. gh-issue: 90536
.. nonce: qMpF6p
.. section: Build
Use the BOLT post-link optimizer to improve performance, particularly on
medium-to-large applications.
..
.. date: 2022-08-04-15-29-35
.. gh-issue: 93744
.. nonce: svRuqm
.. section: Build
Remove the ``configure --with-cxx-main`` build option: it didn't work for
many years. Remove the ``MAINCC`` variable from ``configure`` and
``Makefile``. Patch by Victor Stinner.
..
.. date: 2022-07-26-18-13-34
.. gh-issue: 94801
.. nonce: 9fREfy
.. section: Build
Fix a regression in ``configure`` script that caused some header checks to
ignore custom ``CPPFLAGS``. The regression was introduced in :gh:`94802`.
..
.. date: 2022-07-25-09-48-43
.. gh-issue: 95145
.. nonce: ZNS3dj
.. section: Build
wasm32-wasi builds no longer depend on WASIX's pthread stubs. Python now has
its own stubbed pthread API.
..
.. date: 2022-07-25-08-59-35
.. gh-issue: 95174
.. nonce: g8woUW
.. section: Build
Python now detects missing ``dup`` function in WASI and works around some
missing :mod:`errno`, :mod:`select`, and :mod:`socket` constants.
..
.. date: 2022-07-23-21-39-09
.. gh-issue: 95174
.. nonce: 7cYMZR
.. section: Build
Python now skips missing :mod:`socket` functions and methods on WASI. WASI
can only create sockets from existing fd / accept and has no netdb.
..
.. date: 2022-07-21-09-17-01
.. gh-issue: 95085
.. nonce: E9x2S_
.. section: Build
Platforms ``wasm32-unknown-emscripten`` and ``wasm32-unknown-wasi`` have
been promoted to :pep:`11` tier 3 platform support.
..
.. date: 2022-07-14-11-13-26
.. gh-issue: 94847
.. nonce: s3Kr5p
.. section: Build
Fixed ``_decimal`` module build issue on GCC when compiling with LTO and
pydebug. Debug builds no longer force inlining of functions.
..
.. date: 2022-07-14-02-45-44
.. gh-issue: 94841
.. nonce: lLRTdf
.. section: Build
Fix the possible performance regression of :c:func:`PyObject_Free` compiled
with MSVC version 1932.
..
.. date: 2022-07-13-10-13-10
.. gh-issue: 94801
.. nonce: 3xUB24
.. section: Build
``configure`` now uses custom flags like ``ZLIB_CFLAGS`` and ``ZLIB_LIBS``
when searching for headers and libraries.
..
.. date: 2022-07-12-13-39-18
.. gh-issue: 94773
.. nonce: koHKm5
.. section: Build
``deepfreeze.py`` now supports code object with frozensets that contain
incompatible, unsortable types.
..
.. date: 2022-07-08-10-28-23
.. gh-issue: 94682
.. nonce: ZtGt_0
.. section: Build
Build and test with OpenSSL 1.1.1q
..
.. date: 2022-06-30-17-18-23
.. gh-issue: 90005
.. nonce: EIOOla
.. section: Build
Dependencies of :mod:`readline` and :mod:`curses` module are now detected in
``configure`` script with ``pkg-config``. Only ``ncurses`` / ``ncursesw``
are detected automatically. The old ``curses`` library is not configured
automatically. Workaround for missing ``termcap`` or ``tinfo`` library has
been removed.
..
.. date: 2022-06-30-17-00-54
.. gh-issue: 90005
.. nonce: iiq5qD
.. section: Build
Fix building ``_ctypes`` extension without ``pkg-config``.
..
.. date: 2022-06-30-09-57-39
.. gh-issue: 90005
.. nonce: 9-pQyR
.. section: Build
``_dbm`` module dependencies are now detected by configure.
..
.. date: 2022-06-29-08-58-31
.. gh-issue: 94404
.. nonce: 3MadM6
.. section: Build
``makesetup`` now works around an issue with sed on macOS and uses correct
CFLAGS for object files that end up in a shared extension. Module CFLAGS are
used before PY_STDMODULE_CFLAGS to avoid clashes with system headers.
..
.. date: 2022-06-28-09-42-10
.. gh-issue: 93939
.. nonce: _VWxKW
.. section: Build
C extension modules are now built by ``configure`` and ``make`` instead of
``distutils`` and ``setup.py``.
..
.. date: 2022-06-27-11-57-15
.. gh-issue: 93939
.. nonce: rv7s8W
.. section: Build
The ``2to3``, ``idle``, and ``pydoc`` scripts are now generated and
installed by ``Makefile`` instead of ``setup.py``.
..
.. date: 2022-06-25-23-25-47
.. gh-issue: 94280
.. nonce: YhEyW_
.. section: Build
Updated pegen regeneration script on Windows to find and use Python 3.9 or
higher. Prior to this, pegen regeneration already required 3.9 or higher,
but the script may have used lower versions of Python.
..
.. date: 2022-06-08-14-28-03
.. gh-issue: 93584
.. nonce: 0xfHOK
.. section: Build
Address race condition in ``Makefile`` when installing a PGO build. All
``test`` and ``install`` targets now depend on ``all`` target.
..
.. date: 2022-06-04-12-53-53
.. gh-issue: 93491
.. nonce: ehM211
.. section: Build
``configure`` now detects and reports :pep:`11` support tiers.
..
.. date: 2022-05-31-18-04-58
.. gh-issue: 69093
.. nonce: 6lSa0C
.. section: Build
Fix ``Modules/Setup.stdlib.in`` rule for ``_sqlite3`` extension.
..
.. date: 2022-05-25-13-56-00
.. gh-issue: 93207
.. nonce: B9Rubf
.. section: Build
``va_start()`` with two parameters, like ``va_start(args, format),`` is now
required to build Python. ``va_start()`` is no longer called with a single
parameter. Patch by Kumar Aditya.
..
.. date: 2022-05-25-05-46-00
.. gh-issue: 93202
.. nonce: T37jtj
.. section: Build
Python now always use the ``%zu`` and ``%zd`` printf formats to format a
``size_t`` or ``Py_ssize_t`` number. Building Python 3.12 requires a C11
compiler, so these printf formats are now always supported. Patch by Victor
Stinner.
..
.. date: 2022-05-12-10-19-15
.. gh-issue: 90473
.. nonce: -syvqK
.. section: Build
Disable pymalloc and increase stack size on ``wasm32-wasi``.
..
.. bpo: 34449
.. date: 2018-08-21-11-10-18
.. nonce: Z3qm3c
.. section: Build
Drop invalid compiler switch ``-fPIC`` for HP aCC on HP-UX. Patch by Michael
Osipov.
..
.. date: 2022-10-19-20-00-28
.. gh-issue: 98360
.. nonce: O2m6YG
.. section: Windows
Fixes :mod:`multiprocessing` spawning child processes on Windows from a
virtual environment to ensure that child processes that also use
:mod:`multiprocessing` to spawn more children will recognize that they are
in a virtual environment.
..
.. date: 2022-10-19-19-35-37
.. gh-issue: 98414
.. nonce: FbHZuS
.. section: Windows
Fix :file:`py.exe` launcher handling of ``-V:<company>/`` option when
default preferences have been set in environment variables or configuration
files.
..
.. date: 2022-10-02-11-59-23
.. gh-issue: 97728
.. nonce: dIdlPE
.. section: Windows
Fix possible crashes caused by the use of uninitialized variables when pass
invalid arguments in :func:`os.system` on Windows and in Windows-specific
modules (like ``winreg``).
..
.. date: 2022-09-29-23-08-49
.. gh-issue: 90989
.. nonce: no89Q2
.. section: Windows
Made :ref:`launcher` install per-user by default (unless an all users
install already exists), and clarify some text in the installer.
..
.. date: 2022-09-29-22-27-04
.. gh-issue: 97649
.. nonce: bI7OQU
.. section: Windows
The ``Tools`` directory is no longer installed on Windows
..
.. date: 2022-09-23-15-40-04
.. gh-issue: 96965
.. nonce: CsnEGs
.. section: Windows
Update libffi to 3.4.3
..
.. date: 2022-09-07-00-11-33
.. gh-issue: 96577
.. nonce: kV4K_1
.. section: Windows
Fixes a potential buffer overrun in :mod:`msilib`.
..
.. date: 2022-09-05-18-32-47
.. gh-issue: 96559
.. nonce: 561sUd
.. section: Windows
Fixes the Windows launcher not using the compatible interpretation of
default tags found in configuration files when no tag was passed to the
command.
..
.. date: 2022-08-30-12-01-51
.. gh-issue: 94781
.. nonce: OxO-Gr
.. section: Windows
Fix :file:`pcbuild.proj` to clean previous instances of output files in
``Python\deepfreeze`` and ``Python\frozen_modules`` directories on Windows.
Patch by Charlie Zhao.
..
.. date: 2022-08-26-00-11-18
.. gh-issue: 89545
.. nonce: zmJMY_
.. section: Windows
Updates :mod:`platform` code getting the Windows version to use native
Windows Management Instrumentation (WMI) queries to determine OS version,
type, and architecture.
..
.. date: 2022-08-10-22-46-48
.. gh-issue: 95733
.. nonce: 2_urOp
.. section: Windows
Make certain requirements of the Windows Store package optional to allow
installing on earlier updates of Windows.
..
.. date: 2022-08-04-18-47-54
.. gh-issue: 95656
.. nonce: VJ1d13
.. section: Windows
Enable the :meth:`~sqlite3.Connection.enable_load_extension` :mod:`sqlite3`
API.
..
.. date: 2022-08-04-01-12-27
.. gh-issue: 95587
.. nonce: Fvdv5q
.. section: Windows
Fixes some issues where the Windows installer would incorrectly detect
certain features of an existing install when upgrading.
..
.. date: 2022-08-03-00-49-46
.. gh-issue: 94399
.. nonce: KvxHc0
.. section: Windows
Restores the behaviour of :ref:`launcher` for ``/usr/bin/env`` shebang
lines, which will now search :envvar:`PATH` for an executable matching the
given command. If none is found, the usual search process is used.
..
.. date: 2022-07-30-14-18-33
.. gh-issue: 95445
.. nonce: mjrTaq
.. section: Windows
Fixes the unsuccessful removal of the HTML document directory when
uninstalling with Windows msi.
..
.. date: 2022-07-28-20-21-38
.. gh-issue: 95359
.. nonce: ywMrgu
.. section: Windows
Fix :ref:`launcher` handling of :file:`py.ini` commands (it was incorrectly
expecting a ``py_`` prefix on keys) and crashes when reading per-user
configuration file.
..
.. date: 2022-07-26-20-33-12
.. gh-issue: 95285
.. nonce: w6fa22
.. section: Windows
Fix :ref:`launcher` handling of command lines where it is only passed a
short executable name.
..
.. date: 2022-07-16-16-18-32
.. gh-issue: 90844
.. nonce: vwITT3
.. section: Windows
Allow virtual environments to correctly launch when they have spaces in the
path.
..
.. date: 2022-07-12-20-45-43
.. gh-issue: 94772
.. nonce: uNMmdG
.. section: Windows
Fix incorrect handling of shebang lines in py.exe launcher
..
.. date: 2022-06-20-22-32-14
.. gh-issue: 94018
.. nonce: bycC3A
.. section: Windows
:mod:`zipfile` will now remove trailing spaces from path components when
extracting files on Windows.
..
.. date: 2022-06-15-01-03-52
.. gh-issue: 93824
.. nonce: mR4mxu
.. section: Windows
Drag and drop of files onto Python files in Windows Explorer has been
enabled for Windows ARM64.
..
.. date: 2022-05-28-19-36-13
.. gh-issue: 43414
.. nonce: NGMJ3g
.. section: Windows
:func:`os.get_terminal_size` now attempts to read the size from any provided
handle, rather than only supporting file descriptors 0, 1 and 2.
..
.. date: 2022-05-19-21-44-25
.. gh-issue: 92817
.. nonce: Jrf-Kv
.. section: Windows
Ensures that :file:`py.exe` will prefer an active virtual environment over
default tags specified with environment variables or through a
:file:`py.ini` file.
..
.. date: 2022-05-19-14-01-30
.. gh-issue: 92984
.. nonce: Dsxnlr
.. section: Windows
Explicitly disable incremental linking for non-Debug builds
..
.. date: 2022-05-16-11-45-06
.. gh-issue: 92841
.. nonce: NQx107
.. section: Windows
:mod:`asyncio` no longer throws ``RuntimeError: Event loop is closed`` on
interpreter exit after asynchronous socket activity. Patch by Oleg Iarygin.
..
.. bpo: 46907
.. date: 2022-05-05-06-27-59
.. nonce: IW-uvT
.. section: Windows
Update Windows installer to use SQLite 3.38.4.
..
.. date: 2022-04-12-18-35-20
.. gh-issue: 91061
.. nonce: x40hSK
.. section: Windows
Accept os.PathLike for the argument to winsound.PlaySound
..
.. bpo: 42658
.. date: 2022-03-20-15-47-35
.. nonce: 16eXtb
.. section: Windows
Support native Windows case-insensitive path comparisons by using
``LCMapStringEx`` instead of :func:`str.lower` in :func:`ntpath.normcase`.
Add ``LCMapStringEx`` to the :mod:`_winapi` module.
..
.. bpo: 38704
.. date: 2020-01-10-23-33-03
.. nonce: 2Idtdn
.. section: Windows
Prevent installation on unsupported Windows versions.
..
.. date: 2022-10-05-15-26-58
.. gh-issue: 97897
.. nonce: Rf-C6u
.. section: macOS
The macOS 13 SDK includes support for the ``mkfifoat`` and ``mknodat``
system calls. Using the ``dir_fd`` option with either :func:`os.mkfifo` or
:func:`os.mknod` could result in a segfault if cpython is built with the
macOS 13 SDK but run on an earlier version of macOS. Prevent this by adding
runtime support for detection of these system calls ("weaklinking") as is
done for other newer syscalls on macOS.
..
.. date: 2022-10-15-21-20-40
.. gh-issue: 97527
.. nonce: otAHJM
.. section: IDLE
Fix a bug in the previous bugfix that caused IDLE to not start when run with
3.10.8, 3.12.0a1, and at least Microsoft Python 3.10.2288.0 installed
without the Lib/test package. 3.11.0 was never affected.
..
.. date: 2022-08-04-20-07-51
.. gh-issue: 65802
.. nonce: xnThWe
.. section: IDLE
Document handling of extensions in Save As dialogs.
..
.. date: 2022-08-01-23-31-48
.. gh-issue: 95191
.. nonce: U7vryB
.. section: IDLE
Include prompts when saving Shell (interactive input and output).
..
.. date: 2022-07-31-22-15-14
.. gh-issue: 95511
.. nonce: WX6PmB
.. section: IDLE
Fix the Shell context menu copy-with-prompts bug of copying an extra line
when one selects whole lines.
..
.. date: 2022-07-30-15-10-39
.. gh-issue: 95471
.. nonce: z3scVG
.. section: IDLE
In the Edit menu, move ``Select All`` and add a new separator.
..
.. date: 2022-07-29-11-08-52
.. gh-issue: 95411
.. nonce: dazlqH
.. section: IDLE
Enable using IDLE's module browser with .pyw files.
..
.. date: 2022-07-28-18-56-57
.. gh-issue: 89610
.. nonce: hcosiM
.. section: IDLE
Add .pyi as a recognized extension for IDLE on macOS. This allows opening
stub files by double clicking on them in the Finder.
..
.. date: 2022-10-07-22-06-11
.. gh-issue: 68686
.. nonce: 6KNIQ4
.. section: Tools/Demos
Remove ptags and eptags scripts.
..
.. date: 2022-09-30-18-35-11
.. gh-issue: 97681
.. nonce: -KO1Ba
.. section: Tools/Demos
Remove the ``Tools/demo/`` directory which contained old demo scripts. A
copy can be found in the `old-demos project
<https://github.com/gvanrossum/old-demos>`_. Patch by Victor Stinner.
..
.. date: 2022-09-30-14-30-12
.. gh-issue: 97669
.. nonce: gvbgcg
.. section: Tools/Demos
Remove outdated example scripts of the ``Tools/scripts/`` directory. A copy
can be found in the `old-demos project
<https://github.com/gvanrossum/old-demos>`_. Patch by Victor Stinner.
..
.. date: 2022-08-29-17-25-13
.. gh-issue: 95853
.. nonce: Ce17cT
.. section: Tools/Demos
The ``wasm_build.py`` script now pre-builds Emscripten ports, checks for
broken EMSDK versions, and warns about pkg-config env vars.
..
.. date: 2022-08-10-17-08-43
.. gh-issue: 95853
.. nonce: HCjC2m
.. section: Tools/Demos
The new tool ``Tools/wasm/wasm_builder.py`` automates configure, compile,
and test steps for building CPython on WebAssembly platforms.
..
.. date: 2022-08-05-23-25-59
.. gh-issue: 95731
.. nonce: N2KohU
.. section: Tools/Demos
Fix handling of module docstrings in :file:`Tools/i18n/pygettext.py`.
..
.. date: 2022-07-04-10-02-02
.. gh-issue: 93939
.. nonce: U6sW6H
.. section: Tools/Demos
Add script ``Tools/scripts/check_modules.py`` to check and validate builtin
and shared extension modules. The script also handles ``Modules/Setup`` and
will eventually replace ``setup.py``.
..
.. date: 2022-07-04-01-37-42
.. gh-issue: 94538
.. nonce: 1rgy1Y
.. section: Tools/Demos
Fix Argument Clinic output to custom file destinations. Patch by Erlend E.
Aasland.
..
.. date: 2022-06-29-22-47-11
.. gh-issue: 94430
.. nonce: hdov8L
.. section: Tools/Demos
Allow parameters named ``module`` and ``self`` with custom C names in
Argument Clinic. Patch by Erlend E. Aasland
..
.. date: 2022-06-19-14-56-33
.. gh-issue: 86087
.. nonce: R8MkRy
.. section: Tools/Demos
The ``Tools/scripts/parseentities.py`` script used to parse HTML4 entities
has been removed.
..
.. date: 2022-10-18-16-16-27
.. gh-issue: 98393
.. nonce: 55u4BF
.. section: C API
The :c:func:`PyUnicode_FSDecoder` function no longer accepts bytes-like
paths, like :class:`bytearray` and :class:`memoryview` types: only the exact
:class:`bytes` type is accepted for bytes strings. Patch by Victor Stinner.
..
.. date: 2022-10-05-10-43-32
.. gh-issue: 91051
.. nonce: ODDRsQ
.. section: C API
Add :c:func:`PyType_Watch` and related APIs to allow callbacks on
:c:func:`PyType_Modified`.
..
.. date: 2022-10-03-20-33-24
.. gh-issue: 95756
.. nonce: SSmXlG
.. section: C API
Lazily create and cache ``co_`` attributes for better performance for code
getters.
..
.. date: 2022-09-20-01-04-57
.. gh-issue: 96512
.. nonce: msZTjF
.. section: C API
Configuration for the :ref:`integer string conversion length limitation
<int_max_str_digits>` now lives in the PyConfig C API struct.
..
.. date: 2022-08-16-16-54-42
.. gh-issue: 95589
.. nonce: 6xE1ar
.. section: C API
Extensions classes that set ``tp_dictoffset`` and ``tp_weaklistoffset`` lose
the support for multiple inheritance, but are now safe. Extension classes
should use :const:`Py_TPFLAGS_MANAGED_DICT` and
:const:`Py_TPFLAGS_MANAGED_WEAKREF` instead.
..
.. date: 2022-08-08-14-36-31
.. gh-issue: 95781
.. nonce: W_G8YW
.. section: C API
An unrecognized format character in :c:func:`PyUnicode_FromFormat` and
:c:func:`PyUnicode_FromFormatV` now sets a :exc:`SystemError`. In previous
versions it caused all the rest of the format string to be copied as-is to
the result string, and any extra arguments discarded.
..
.. date: 2022-08-03-14-39-08
.. gh-issue: 92678
.. nonce: ozFTEx
.. section: C API
Restore the 3.10 behavior for multiple inheritance of C extension classes
that store their dictionary at the end of the struct.
..
.. date: 2022-08-03-13-01-57
.. gh-issue: 92678
.. nonce: DLwONN
.. section: C API
Support C extensions using managed dictionaries by setting the
``Py_TPFLAGS_MANAGED_DICT`` flag.
..
.. date: 2022-08-01-16-21-39
.. gh-issue: 93274
.. nonce: QoDHEu
.. section: C API
API for implementing vectorcall (:c:data:`Py_TPFLAGS_HAVE_VECTORCALL`,
:c:func:`PyVectorcall_NARGS` and :c:func:`PyVectorcall_Call`) was added to
the limited API and stable ABI.
..
.. date: 2022-07-31-21-58-27
.. gh-issue: 95504
.. nonce: wy7B1F
.. section: C API
Fix sign placement when specifying width or precision in
:c:func:`PyUnicode_FromFormat` and :c:func:`PyUnicode_FromFormatV`. Patch by
Philip Georgi.
..
.. date: 2022-07-29-15-24-45
.. gh-issue: 93012
.. nonce: -DdGEy
.. section: C API
The :const:`Py_TPFLAGS_HAVE_VECTORCALL` flag is now removed from a class
when the class's :py:meth:`~object.__call__` method is reassigned. This
makes vectorcall safe to use with mutable types (i.e. heap types without the
:const:`immutable <Py_TPFLAGS_IMMUTABLETYPE>` flag). Mutable types that do
not override :c:member:`~PyTypeObject.tp_call` now inherit the
:const:`Py_TPFLAGS_HAVE_VECTORCALL` flag.
..
.. date: 2022-07-29-10-41-59
.. gh-issue: 95388
.. nonce: aiRSgr
.. section: C API
Creating :c:data:`immutable types <Py_TPFLAGS_IMMUTABLETYPE>` with mutable
bases is deprecated and is planned to be disabled in Python 3.14.
..
.. date: 2022-07-25-15-54-27
.. gh-issue: 92678
.. nonce: ziZpxz
.. section: C API
Adds unstable C-API functions ``_PyObject_VisitManagedDict`` and
``_PyObject_ClearManagedDict`` to allow C extensions to allow the VM to
manage their object's dictionaries.
..
.. date: 2022-07-19-22-37-40
.. gh-issue: 94936
.. nonce: LGlmKv
.. section: C API
Added :c:func:`PyCode_GetVarnames`, :c:func:`PyCode_GetCellvars` and
:c:func:`PyCode_GetFreevars` for accessing ``co_varnames``, ``co_cellvars``
and ``co_freevars`` respectively via the C API.
..
.. date: 2022-07-17-18-21-40
.. gh-issue: 94930
.. nonce: gPFGDL
.. section: C API
Fix ``SystemError`` raised when :c:func:`PyArg_ParseTupleAndKeywords` is
used with ``#`` in ``(...)`` but without ``PY_SSIZE_T_CLEAN`` defined.
..
.. date: 2022-07-12-17-39-32
.. gh-issue: 94731
.. nonce: 9CPJNU
.. section: C API
Python again uses C-style casts for most casting operations when compiled
with C++. This may trigger compiler warnings, if they are enabled with e.g.
``-Wold-style-cast`` or ``-Wzero-as-null-pointer-constant`` options for
``g++``.
..
.. date: 2022-06-17-13-41-38
.. gh-issue: 93937
.. nonce: uKVTEh
.. section: C API
The following frame functions and type are now directly available with
``#include <Python.h>``, it's no longer needed to add ``#include
<frameobject.h>``:
* :c:func:`PyFrame_Check`
* :c:func:`PyFrame_GetBack`
* :c:func:`PyFrame_GetBuiltins`
* :c:func:`PyFrame_GetGenerator`
* :c:func:`PyFrame_GetGlobals`
* :c:func:`PyFrame_GetLasti`
* :c:func:`PyFrame_GetLocals`
* :c:type:`PyFrame_Type`
Patch by Victor Stinner.
..
.. date: 2022-06-13-21-37-31
.. gh-issue: 91321
.. nonce: DgJFvS
.. section: C API
Fix the compatibility of the Python C API with C++ older than C++11. Patch
by Victor Stinner.
..
.. date: 2022-06-10-23-41-48
.. gh-issue: 91731
.. nonce: fhYUQG
.. section: C API
Avoid defining the ``static_assert`` when compiling with C++ 11, where this
is a keyword and redefining it can lead to undefined behavior. Patch by
Pablo Galindo
..
.. date: 2022-06-10-16-50-27
.. gh-issue: 89546
.. nonce: mX1f10
.. section: C API
:c:func:`PyType_FromMetaclass` (and other ``PyType_From*`` functions) now
check that offsets and the base class's
:c:member:`~PyTypeObject.tp_basicsize` fit in the new class's
``tp_basicsize``.
..
.. date: 2022-06-06-16-04-14
.. gh-issue: 93503
.. nonce: MHJTu8
.. section: C API
Add two new public functions to the public C-API,
:c:func:`PyEval_SetProfileAllThreads` and
:c:func:`PyEval_SetTraceAllThreads`, that allow to set tracing and profiling
functions in all running threads in addition to the calling one. Also, two
analogous functions to the :mod:`threading` module
(:func:`threading.setprofile_all_threads` and
:func:`threading.settrace_all_threads`) that allow to do the same from
Python. Patch by Pablo Galindo
..
.. date: 2022-06-04-13-15-41
.. gh-issue: 93442
.. nonce: 4M4NDb
.. section: C API
Add C++ overloads for _Py_CAST_impl() to handle 0/NULL. This will allow C++
extensions that pass 0 or NULL to macros using _Py_CAST() to continue to
compile.
..
.. date: 2022-06-03-14-54-41
.. gh-issue: 93466
.. nonce: DDtH0X
.. section: C API
Slot IDs in PyType_Spec may not be repeated. The documentation was updated
to mention this. For some cases of repeated slots, PyType_FromSpec and
related functions will now raise an exception.
..
.. date: 2022-05-23-15-22-18
.. gh-issue: 92898
.. nonce: Qjc9d3
.. section: C API
Fix C++ compiler warnings when casting function arguments to ``PyObject*``.
Patch by Serge Guelton.
..
.. date: 2022-05-23-13-33-18
.. gh-issue: 93103
.. nonce: ooD3Eb
.. section: C API
Deprecate global configuration variables, like
:c:var:`Py_IgnoreEnvironmentFlag`, in the documentation: the
:c:func:`Py_InitializeFromConfig` API should be instead. Patch by Victor
Stinner.
..
.. date: 2022-05-23-12-31-04
.. gh-issue: 77782
.. nonce: ugC8dn
.. section: C API
Deprecate global configuration variable like
:c:var:`Py_IgnoreEnvironmentFlag`: the :c:func:`Py_InitializeFromConfig` API
should be instead. Patch by Victor Stinner.
..
.. date: 2022-05-19-18-05-51
.. gh-issue: 92913
.. nonce: Ass1Hv
.. section: C API
Ensures changes to :c:member:`PyConfig.module_search_paths` are ignored
unless :c:member:`PyConfig.module_search_paths_set` is set
..
.. date: 2022-05-13-18-17-48
.. gh-issue: 92781
.. nonce: TVDr3-
.. section: C API
Avoid mixing declarations and code in the C API to fix the compiler warning:
"ISO C90 forbids mixed declarations and code"
[-Werror=declaration-after-statement]. Patch by Victor Stinner.
..
.. date: 2022-05-11-02-33-10
.. gh-issue: 92651
.. nonce: FIXLf0
.. section: C API
Remove the ``token.h`` header file. There was never any public tokenizer C
API. The ``token.h`` header file was only designed to be used by Python
internals. Patch by Victor Stinner.
..
.. date: 2022-05-10-12-35-42
.. gh-issue: 92536
.. nonce: cAoRCZ
.. section: C API
Remove legacy Unicode APIs based on ``Py_UNICODE*``.
..
.. date: 2022-05-09-23-16-38
.. gh-issue: 85858
.. nonce: VIcNDL
.. section: C API
Remove the ``PyUnicode_InternImmortal()`` function and the
``SSTATE_INTERNED_IMMORTAL`` macro. Patch by Victor Stinner.
..
.. date: 2022-05-03-19-35-37
.. gh-issue: 92193
.. nonce: 61VoFL
.. section: C API
Add new function :c:func:`PyFunction_SetVectorcall` to the C API which sets
the vectorcall field of a given :c:type:`PyFunctionObject`.
Warning: extensions using this API must preserve the behavior of the
unaltered function!
..
.. date: 2022-04-13-16-10-55
.. gh-issue: 59121
.. nonce: -B7mKp
.. section: C API
Fixed an assert that prevented ``PyRun_InteractiveOne`` from providing
tracebacks when parsing from the provided FD.
..
.. bpo: 45383
.. date: 2021-10-05-21-59-43
.. nonce: TVClgf
.. section: C API
The :c:func:`PyType_FromSpec` API will now find and use a metaclass based on
the provided bases. An error will be raised if there is a metaclass
conflict.
|