summaryrefslogtreecommitdiffstats
path: root/Misc/NEWS.d/3.13.0b3.rst
blob: e9b55d6e52b26057213564be1b4ccac79d5d730f (plain)
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
.. date: 2024-06-26-14-09-31
.. gh-issue: 120838
.. nonce: nFeTL9
.. release date: 2024-06-27
.. section: Core and Builtins

:c:func:`Py_Finalize()` and :c:func:`Py_FinalizeEx()` now always run with
the main interpreter active.

..

.. date: 2024-06-26-13-42-36
.. gh-issue: 113433
.. nonce: xKAtLB
.. section: Core and Builtins

Subinterpreters now get cleaned up automatically during runtime
finalization.

..

.. date: 2024-06-19-11-10-50
.. gh-issue: 119462
.. nonce: DpcqSe
.. section: Core and Builtins

Make sure that invariants of type versioning are maintained: * Superclasses
always have their version number assigned before subclasses * The version
tag is always zero if the tag is not valid. * The version tag is always
non-zero if the tag is valid.

..

.. date: 2024-06-19-01-58-54
.. gh-issue: 120437
.. nonce: nCkIoI
.. section: Core and Builtins

Fix ``_CHECK_STACK_SPACE`` optimization problems introduced in :gh:`118322`.

..

.. date: 2024-06-18-22-41-05
.. gh-issue: 120722
.. nonce: rS7tkE
.. section: Core and Builtins

Correctly set the bytecode position on return instructions within lambdas.
Patch by Jelle Zijlstra.

..

.. date: 2024-06-18-21-34-30
.. gh-issue: 120367
.. nonce: zDwffP
.. section: Core and Builtins

Fix bug where compiler creates a redundant jump during pseudo-op
replacement. Can only happen with a synthetic AST that has a try on the same
line as the instruction following the exception handler.

..

.. date: 2024-06-14-22-02-25
.. gh-issue: 113993
.. nonce: MiA0vX
.. section: Core and Builtins

Strings interned with :func:`sys.intern` are again garbage-collected when no
longer used, as per the documentation. Strings interned with the C function
:c:func:`PyUnicode_InternInPlace` are still immortal. Internals of the
string interning mechanism have been changed. This may affect performance
and identities of :class:`str` objects.

..

.. date: 2024-06-13-12-17-52
.. gh-issue: 120384
.. nonce: w1UBGl
.. section: Core and Builtins

Fix an array out of bounds crash in ``list_ass_subscript``, which could be
invoked via some specificly tailored input: including concurrent
modification of a list object, where one thread assigns a slice and another
clears it.

..

.. date: 2024-06-12-18-50-29
.. gh-issue: 120367
.. nonce: LmXx2y
.. section: Core and Builtins

Fix crash in compiler on code with redundant NOPs and JUMPs which show up
after exception handlers are moved to the end of the code.

..

.. date: 2024-06-12-18-23-15
.. gh-issue: 120380
.. nonce: edtqjq
.. section: Core and Builtins

Fix Python implementation of :class:`pickle.Pickler` for :class:`bytes` and
:class:`bytearray` objects when using protocol version 5. Patch by Bénédikt
Tran.

..

.. date: 2024-06-12-12-29-45
.. gh-issue: 120400
.. nonce: lZYHVS
.. section: Core and Builtins

Support Linux perf profiler to see Python calls on RISC-V architecture.

..

.. date: 2024-06-11-17-56-12
.. gh-issue: 120221
.. nonce: si9hM9
.. section: Core and Builtins

Deliver real signals on Ctrl-C and Ctrl-Z in the new REPL. Patch by Pablo
Galindo

..

.. date: 2024-06-11-12-47-54
.. gh-issue: 120346
.. nonce: hhn_6X
.. section: Core and Builtins

Respect :envvar:`PYTHON_BASIC_REPL` when running in interative inspect mode
(``python -i``). Patch by Pablo Galindo

..

.. date: 2024-06-10-22-30-26
.. gh-issue: 93691
.. nonce: 68WOTS
.. section: Core and Builtins

Fix source locations of instructions generated for the iterator of a for
statement.

..

.. date: 2024-06-10-15-07-16
.. gh-issue: 120198
.. nonce: WW_pjO
.. section: Core and Builtins

Fix a crash when multiple threads read and write to the same ``__class__``
of an object concurrently.

..

.. date: 2024-06-10-10-42-48
.. gh-issue: 120298
.. nonce: napREA
.. section: Core and Builtins

Fix use-after free in ``list_richcompare_impl`` which can be invoked via
some specificly tailored evil input.

..

.. date: 2024-06-09-19-13-38
.. gh-issue: 119666
.. nonce: S0G4rZ
.. section: Core and Builtins

Fix a compiler crash in the case where two comprehensions in class scope
both reference ``__class__``.

..

.. date: 2024-06-07-16-09-04
.. gh-issue: 120225
.. nonce: kuYf9t
.. section: Core and Builtins

Fix crash in compiler on empty block at end of exception handler.

..

.. date: 2024-06-03-13-48-44
.. gh-issue: 119933
.. nonce: Kc0HG5
.. section: Core and Builtins

Improve :exc:`SyntaxError` messages for invalid expressions in a type
parameters bound, a type parameter constraint tuple or a default type
parameter. Patch by Bénédikt Tran.

..

.. bpo: 24766
.. date: 2018-10-09-15-14-53
.. nonce: c_C1Wc
.. section: Core and Builtins

Fix handling of ``doc`` argument to subclasses of ``property``.

..

.. date: 2024-06-27-13-47-14
.. gh-issue: 121027
.. nonce: jh55EC
.. section: Library

Add a future warning in :meth:`!functools.partial.__get__`. In future Python
versions :class:`functools.partial` will be a method descriptor.

..

.. date: 2024-06-26-10-13-40
.. gh-issue: 121025
.. nonce: M-XXlV
.. section: Library

Improve the :meth:`~object.__repr__` of :class:`functools.partialmethod`.
Patch by Bénédikt Tran.

..

.. date: 2024-06-26-03-04-24
.. gh-issue: 121018
.. nonce: clVSc4
.. section: Library

Fixed an issue where :meth:`!argparse.ArgumentParser.parses_args` did not
honor ``exit_on_error=False`` when given unrecognized arguments. Patch by
Ben Hsing.

..

.. date: 2024-06-23-17-50-40
.. gh-issue: 119614
.. nonce: vwPGLB
.. section: Library

Fix truncation of strings with embedded null characters in some internal
operations in :mod:`tkinter`.

..

.. date: 2024-06-23-11-21-27
.. gh-issue: 120910
.. nonce: t0QXdB
.. section: Library

When reading installed files from an egg, use ``relative_to(walk_up=True)``
to honor files installed outside of the installation root.

..

.. date: 2024-06-22-22-52-24
.. gh-issue: 120888
.. nonce: sd8I3N
.. section: Library

Upgrade pip wheel bundled with ensurepip (pip 24.1.1)

..

.. date: 2024-06-22-22-23-56
.. gh-issue: 101830
.. nonce: 1BAoxH
.. section: Library

Accessing the :mod:`tkinter` object's string representation no longer
converts the underlying Tcl object to a string on Windows.

..

.. date: 2024-06-21-14-32-56
.. gh-issue: 120811
.. nonce: eBmVTV
.. section: Library

Fix possible memory leak in :meth:`contextvars.Context.run`.

..

.. date: 2024-06-20-01-31-24
.. gh-issue: 120769
.. nonce: PfiMrc
.. section: Library

Make empty line in :mod:`pdb` repeats the last command even when the command
is from ``cmdqueue``.

..

.. date: 2024-06-19-15-06-58
.. gh-issue: 120732
.. nonce: OvYV9b
.. section: Library

Fix ``name`` passing to :class:`unittest.mock.Mock` object when using
:func:`unittest.mock.create_autospec`.

..

.. date: 2024-06-18-19-18-10
.. gh-issue: 120683
.. nonce: xmRez7
.. section: Library

Fix an error in :class:`logging.LogRecord`, when the integer part of the
timestamp is rounded up, while the millisecond calculation truncates,
causing the log timestamp to be wrong by up to 999 ms (affected roughly 1 in
8 million timestamps).

..

.. date: 2024-06-17-20-04-13
.. gh-issue: 120633
.. nonce: kZC5wt
.. section: Library

Move scrollbar and remove tear-off menus in turtledemo.

..

.. date: 2024-06-15-12-04-46
.. gh-issue: 120541
.. nonce: d3cc5y
.. section: Library

Improve the prompt in the "less" pager when :func:`help` is called with
non-string argument.

..

.. date: 2024-06-14-20-05-25
.. gh-issue: 120495
.. nonce: OxgZKB
.. section: Library

Fix incorrect exception handling in Tab Nanny. Patch by Wulian233.

..

.. date: 2024-06-12-11-54-05
.. gh-issue: 120381
.. nonce: O-BNLs
.. section: Library

Correct :func:`inspect.ismethoddescriptor` to check also for the lack of
:meth:`~object.__delete__`.  Patch by Jan Kaliszewski.

..

.. date: 2024-06-12-10-00-31
.. gh-issue: 90425
.. nonce: 5CfkKG
.. section: Library

The OS byte in gzip headers is now always set to 255 when using
:func:`gzip.compress`.

..

.. date: 2024-06-11-16-34-41
.. gh-issue: 120343
.. nonce: hdiXeU
.. section: Library

Fix column offset reporting for tokens that come after multiline f-strings
in the :mod:`tokenize` module.

..

.. date: 2024-06-10-14-00-40
.. gh-issue: 119600
.. nonce: jJMf4C
.. section: Library

Fix :func:`unittest.mock.patch` to not read attributes of the target when
``new_callable`` is set. Patch by Robert Collins.

..

.. date: 2024-06-08-15-46-35
.. gh-issue: 114053
.. nonce: Ub2XgJ
.. section: Library

Fix edge-case bug where :func:`typing.get_type_hints` would produce
incorrect results if type parameters in a class scope were overridden by
assignments in a class scope and ``from __future__ import annotations``
semantics were enabled. Patch by Alex Waygood.

..

.. date: 2024-06-08-15-15-29
.. gh-issue: 114053
.. nonce: WQLAFG
.. section: Library

Fix erroneous :exc:`NameError` when calling :func:`inspect.get_annotations`
with ``eval_str=True``` on a class that made use of :pep:`695` type
parameters in a module that had ``from __future__ import annotations`` at
the top of the file. Patch by Alex Waygood.

..

.. date: 2024-06-08-14-36-40
.. gh-issue: 120268
.. nonce: MNpd1q
.. section: Library

Prohibit passing ``None`` to pure-Python :meth:`datetime.date.fromtimestamp`
to achieve consistency with C-extension implementation.

..

.. date: 2024-06-08-09-45-31
.. gh-issue: 120244
.. nonce: 8o9Dzr
.. section: Library

Fix memory leak in :func:`re.sub()` when the replacement string contains
backreferences.

..

.. date: 2024-06-07-13-21-11
.. gh-issue: 120211
.. nonce: Rws_gf
.. section: Library

Fix :mod:`tkinter.ttk` with Tcl/Tk 9.0.

..

.. date: 2024-06-07-11-23-31
.. gh-issue: 71587
.. nonce: IjFajE
.. section: Library

Fix crash in C version of :meth:`datetime.datetime.strptime` when called
again on the restarted interpreter.

..

.. date: 2024-06-06-17-24-43
.. gh-issue: 120161
.. nonce: DahNXV
.. section: Library

:mod:`datetime` no longer crashes in certain complex reference cycle
situations.

..

.. date: 2024-06-06-12-07-57
.. gh-issue: 119698
.. nonce: rRrprk
.. section: Library

Fix :meth:`symtable.Class.get_methods` and document its behaviour. Patch by
Bénédikt Tran.

..

.. date: 2024-06-05-16-30-28
.. gh-issue: 120121
.. nonce: 9dz8i7
.. section: Library

Add :exc:`concurrent.futures.InvalidStateError` to module's ``__all__``.

..

.. date: 2024-06-05-11-39-21
.. gh-issue: 119933
.. nonce: ooJXQV
.. section: Library

Add the :class:`symtable.SymbolTableType` enumeration to represent the
possible outputs of the :class:`symtable.SymbolTable.get_type` method. Patch
by Bénédikt Tran.

..

.. date: 2024-06-05-08-02-46
.. gh-issue: 120108
.. nonce: 4U9BL8
.. section: Library

Fix calling :func:`copy.deepcopy` on :mod:`ast` trees that have been
modified to have references to parent nodes. Patch by Jelle Zijlstra.

..

.. date: 2024-06-04-19-03-25
.. gh-issue: 112672
.. nonce: K2XfZH
.. section: Library

Support building :mod:`tkinter` with Tcl 9.0.

..

.. date: 2024-06-04-08-57-02
.. gh-issue: 65454
.. nonce: o9j4wF
.. section: Library

:func:`unittest.mock.Mock.attach_mock` no longer triggers a call to a
``PropertyMock`` being attached.

..

.. date: 2024-06-02-13-35-11
.. gh-issue: 81936
.. nonce: ETeW9x
.. section: Library

:meth:`!help` and :meth:`!showtopic` methods now respect a configured
*output* argument to :class:`!pydoc.Helper` and not use the pager in such
cases. Patch by Enrico Tröger.

..

.. date: 2024-05-29-21-50-05
.. gh-issue: 119577
.. nonce: S3BlKJ
.. section: Library

The :exc:`DeprecationWarning` emitted when testing the truth value of an
:class:`xml.etree.ElementTree.Element` now describes unconditionally
returning ``True`` in a future version rather than raising an exception in
Python 3.14.

..

.. date: 2024-05-25-10-40-38
.. gh-issue: 118908
.. nonce: XcZiq4
.. section: Library

Limit exposed globals from internal imports and definitions on new REPL
startup. Patch by Eugene Triguba and Pablo Galindo.

..

.. date: 2024-05-24-14-32-24
.. gh-issue: 119506
.. nonce: -nMNqq
.. section: Library

Fix :meth:`!io.TextIOWrapper.write` method breaks internal buffer when the
method is called again during flushing internal buffer.

..

.. date: 2024-06-21-09-24-03
.. gh-issue: 120671
.. nonce: Z8sBQB
.. section: Build

Fix failing configure tests due to a missing space when appending to CFLAGS.

..

.. date: 2024-06-19-21-05-15
.. gh-issue: 120602
.. nonce: UyDARz
.. section: Build

Correctly handle LLVM installs with ``LLVM_VERSION_SUFFIX`` when building
with ``--enable-experimental-jit``.

..

.. date: 2024-06-11-00-38-05
.. gh-issue: 120326
.. nonce: JHSDF1
.. section: Build

On Windows, fix build error when ``--disable-gil`` and
``--experimental-jit`` options are combined.

..

.. date: 2024-06-09-15-54-22
.. gh-issue: 120291
.. nonce: IpfHzE
.. section: Build

Make the ``python-config`` shell script compatible with non-bash shells.

..

.. date: 2024-06-26-11-29-01
.. gh-issue: 120642
.. nonce: H7P9qK
.. section: C API

Remove the private ``_Py_CODEUNIT`` type from the public C API. The internal
``pycore_code.h`` header should now be used to get this internal type. Patch
by Victor Stinner.

..

.. date: 2024-06-21-16-41-21
.. gh-issue: 120858
.. nonce: Z5_-Mn
.. section: C API

:c:func:`PyDict_Next` no longer locks the dictionary in the free-threaded
build.  The locking needs to be done by the caller around the entire
iteration loop.

..

.. date: 2024-06-19-21-27-42
.. gh-issue: 120642
.. nonce: UlKClN
.. section: C API

Remove the following unstable functions:

* ``PyUnstable_Replace_Executor()``
* ``PyUnstable_SetOptimizer()``
* ``PyUnstable_GetOptimizer()``
* ``PyUnstable_GetExecutor()``
* ``PyUnstable_Optimizer_NewCounter()``
* ``PyUnstable_Optimizer_NewUOpOptimizer()``

Patch by Victor Stinner.

..

.. date: 2024-05-21-19-41-41
.. gh-issue: 119344
.. nonce: QKvzQb
.. section: C API

The critical section API is now public as part of the non-limited C API.

..

.. date: 2024-05-08-21-57-50
.. gh-issue: 118789
.. nonce: Ni4UQx
.. section: C API

Add :c:func:`PyUnstable_Object_ClearWeakRefsNoCallbacks`, which clears
weakrefs without calling their callbacks.

..

.. date: 2024-04-10-16-48-04
.. gh-issue: 117511
.. nonce: RZtBRK
.. section: C API

Make the :c:type:`PyMutex` public in the non-limited C API.