]> git.ipfire.org Git - thirdparty/Python/cpython.git/log
thirdparty/Python/cpython.git
3 days agogh-144257: document return values of PyModule_SetDocString (GH-144258)
Nathan Goldbaum [Tue, 27 Jan 2026 07:15:16 +0000 (00:15 -0700)] 
gh-144257: document return values of PyModule_SetDocString (GH-144258)

Co-authored-by: sobolevn <mail@sobolevn.me>
3 days agogh-142037: Fix a refleak introduced in GH-142081 (GH-144256)
Serhiy Storchaka [Mon, 26 Jan 2026 21:15:21 +0000 (23:15 +0200)] 
gh-142037: Fix a refleak introduced in GH-142081 (GH-144256)

3 days agogh-144001: Support ignorechars in binascii.a2b_base64() and base64.b64decode() (GH...
Serhiy Storchaka [Mon, 26 Jan 2026 18:11:40 +0000 (20:11 +0200)] 
gh-144001: Support ignorechars in binascii.a2b_base64() and base64.b64decode() (GH-144024)

3 days agogh-142966: Make ctypes.POINTER.set_type also reset format (GH-142967)
Jeong, YunWon [Mon, 26 Jan 2026 16:40:56 +0000 (01:40 +0900)] 
gh-142966: Make ctypes.POINTER.set_type also reset format (GH-142967)

Make the deprecated set_type method resets the format, using the
same code as in type initialization.

Implementation note: this was done in PyCPointerType_init
after calling PyCPointerType_SetProto, but was forgotten
after in PyCPointerType_set_type_impl's call to
PyCPointerType_SetProto.
With this change, setting the format is conceptually part of
setting proto (i.e. the pointed-to type).

Co-authored-by: AN Long <aisk@users.noreply.github.com>
3 days agogh-101888: Add function.__builtins__ to ref documentation (#144174)
Victor Stinner [Mon, 26 Jan 2026 16:15:47 +0000 (17:15 +0100)] 
gh-101888: Add function.__builtins__ to ref documentation (#144174)

3 days agogh-142119: Clarify context manager protocol documentation on `ContextVar.set` and...
Bartosz Sławecki [Mon, 26 Jan 2026 15:50:27 +0000 (16:50 +0100)] 
gh-142119: Clarify context manager protocol documentation on `ContextVar.set` and `Token` (GH-143694)

3 days agogh-140557: Force alignment of empty `bytearray` and `array.array` buffers (GH-140559)
Jake Lishman [Mon, 26 Jan 2026 15:45:17 +0000 (15:45 +0000)] 
gh-140557: Force alignment of empty `bytearray` and `array.array` buffers (GH-140559)

This ensures the buffers used by the empty `bytearray` and `array.array`
are aligned the same as a pointer returned by the allocator.  This is a
more convenient default for interop with other languages that have
stricter requirements of type-safe buffers (e.g. Rust's `&[T]` type)
even when empty.

3 days agogh-144212: Add `image/jxl` to `mimetypes` (GH-144213)
FooIbar [Mon, 26 Jan 2026 14:26:55 +0000 (22:26 +0800)] 
gh-144212: Add `image/jxl` to `mimetypes` (GH-144213)

3 days agogh-143928: Remove outdated comparison between pickle and marshal regarding recursion...
Yashraj [Mon, 26 Jan 2026 13:38:23 +0000 (19:08 +0530)] 
gh-143928: Remove outdated comparison between pickle and marshal regarding recursion (#144025)

4 days agogh-144100: Fix crash for POINTER(str) used in ctypes argtypes (#144108)
VanshAgarwal24036 [Mon, 26 Jan 2026 12:27:42 +0000 (17:57 +0530)] 
gh-144100: Fix crash for POINTER(str) used in ctypes argtypes (#144108)

Co-authored-by: Victor Stinner <vstinner@python.org>
4 days agogh-144128: Fix crash in array.fromlist with reentrant __index__ (#144138)
Priyanshu Singh [Mon, 26 Jan 2026 12:13:49 +0000 (17:43 +0530)] 
gh-144128: Fix crash in array.fromlist with reentrant __index__ (#144138)

Co-authored-by: blurb-it[bot] <43283697+blurb-it[bot]@users.noreply.github.com>
Co-authored-by: Peter Bierma <zintensitydev@gmail.com>
Co-authored-by: Victor Stinner <vstinner@python.org>
4 days agogh-144233: Fix typo in os.eventfd documentation (#144234)
Solomon Ritzow [Mon, 26 Jan 2026 08:07:56 +0000 (00:07 -0800)] 
gh-144233: Fix typo in os.eventfd documentation (#144234)

4 days agogh-144169: Fix three crashes in AST objects with non-str kwargs (#144178)
Jelle Zijlstra [Mon, 26 Jan 2026 01:28:58 +0000 (17:28 -0800)] 
gh-144169: Fix three crashes in AST objects with non-str kwargs (#144178)

Co-authored-by: Victor Stinner <vstinner@python.org>
4 days agogh-144217: Add dicom support (medical imaging) to mimetypes (GH-144218)
benediktjohannes [Sun, 25 Jan 2026 22:22:43 +0000 (23:22 +0100)] 
gh-144217: Add dicom support (medical imaging) to mimetypes (GH-144218)

Co-authored-by: blurb-it[bot] <43283697+blurb-it[bot]@users.noreply.github.com>
Co-authored-by: Peter Bierma <zintensitydev@gmail.com>
4 days agogh-143995: Eliminate redundant refcounting in the JIT from LOAD_ATTR_MODULE (GH-143996)
AN Long [Sun, 25 Jan 2026 18:24:44 +0000 (03:24 +0900)] 
gh-143995: Eliminate redundant refcounting in the JIT from LOAD_ATTR_MODULE (GH-143996)

4 days agogh-143504: Expose CELL status of a symbol in symtable (#143549)
Yashraj [Sun, 25 Jan 2026 15:21:27 +0000 (20:51 +0530)] 
gh-143504: Expose CELL status of a symbol in symtable (#143549)

5 days agogh-144140: Optimize len for string constants in optimizer (GH-144142)
Yi Yang [Sat, 24 Jan 2026 16:09:29 +0000 (00:09 +0800)] 
gh-144140: Optimize len for string constants in optimizer (GH-144142)

5 days agoRemove stray typedef in _tkinter.c (GH-142924)
mdehoon [Sat, 24 Jan 2026 15:20:14 +0000 (00:20 +0900)] 
Remove stray typedef in _tkinter.c (GH-142924)

Co-authored-by: Michiel de Hoon <mdehoon@tkx288.genome.gsc.riken.jp>
6 days agogh-142037: Improve error messages for printf-style formatting (GH-142081)
Serhiy Storchaka [Sat, 24 Jan 2026 11:13:50 +0000 (13:13 +0200)] 
gh-142037: Improve error messages for printf-style formatting (GH-142081)

This affects string formatting as well as bytes and bytearray formatting.

* For errors in the format string, always include the position of the
  start of the format unit.
* For errors related to the formatted arguments, always include the number
  or the name of the formatted argument.
* Suggest more probable causes of errors in the format string (stray %,
  unsupported format, unexpected character).
* Provide more information when the number of arguments does not match
  the number of format units.
* Raise more specific errors when access of arguments by name is mixed with
  sequential access and when * is used with a mapping.
* Add tests for some uncovered cases.

6 days agogh-142913: Add generated test files to gitattributes (GH-144209)
Marc Mueller [Sat, 24 Jan 2026 10:19:21 +0000 (11:19 +0100)] 
gh-142913: Add generated test files to gitattributes (GH-144209)

6 days agogh-130415: Narrow types to constants in branches involving specialized comparisons...
reiden [Sat, 24 Jan 2026 10:02:08 +0000 (18:02 +0800)] 
gh-130415: Narrow types to constants in branches involving specialized comparisons with a constant (GH-144150)

6 days agogh-144068: fix JIT tracer memory leak when daemon thread exits (GH-144077)
Hai Zhu [Sat, 24 Jan 2026 09:43:01 +0000 (17:43 +0800)] 
gh-144068: fix JIT tracer memory leak when daemon thread exits (GH-144077)

6 days agoMisc: remove duplicate `instr_frame` assignment in `_PyJit_TryInitializeTracing`...
Yongtao Huang [Sat, 24 Jan 2026 09:37:45 +0000 (17:37 +0800)] 
Misc: remove duplicate `instr_frame` assignment in `_PyJit_TryInitializeTracing` (GH-144155)

Remove duplicate instr_frame assignment in optimizer

6 days agogh-144016: Fix bad stack assert in the JIT optimizer (GH-144019)
Ken Jin [Sat, 24 Jan 2026 09:36:40 +0000 (17:36 +0800)] 
gh-144016: Fix bad stack assert in the JIT optimizer (GH-144019)

6 days agogh-144007: Eliminate redundant refcounting in the JIT for BINARY_OP (GH-144011)
AN Long [Sat, 24 Jan 2026 09:35:32 +0000 (18:35 +0900)] 
gh-144007: Eliminate redundant refcounting in the JIT for BINARY_OP (GH-144011)

6 days agogh-135142: Initial 3.15 IDLE News3.txt entries (#144200)
Terry Jan Reedy [Sat, 24 Jan 2026 02:34:41 +0000 (21:34 -0500)] 
gh-135142: Initial 3.15 IDLE News3.txt entries (#144200)

6 days agogh-74902: Avoid hitting unicode.org for test data (GH-144195)
Zachary Ware [Fri, 23 Jan 2026 21:07:27 +0000 (15:07 -0600)] 
gh-74902: Avoid hitting unicode.org for test data (GH-144195)

Use our own pythontest.net instead.

6 days agogh-144027: Fix documentation for ignorechars in base64.a85decode() (GH-144028)
Serhiy Storchaka [Fri, 23 Jan 2026 18:55:48 +0000 (20:55 +0200)] 
gh-144027: Fix documentation for ignorechars in base64.a85decode() (GH-144028)

It does not support an ASCII string.

Also add more tests.

6 days agogh-144005: Eliminate redundant refcounting in the JIT for BINARY_OP_EXTEND (#144006)
AN Long [Fri, 23 Jan 2026 17:19:01 +0000 (02:19 +0900)] 
gh-144005: Eliminate redundant refcounting in the JIT for BINARY_OP_EXTEND (#144006)

6 days agogh-141376: smelly.py: Print only smelly symbols, or all of them with --verbose (GH...
Petr Viktorin [Fri, 23 Jan 2026 16:51:29 +0000 (17:51 +0100)] 
gh-141376: smelly.py: Print only smelly symbols, or all of them with --verbose (GH-141394)

Instead of long and uninteresting output for all checked libraries, only print found issues by default.

Add a new -v/--verbose option to list all symbols (useful for checking that the script finds the symbols).

6 days agoProgramming FAQ: fix some punctuaction typos (GH-144058)
Bartosz Sławecki [Fri, 23 Jan 2026 16:34:21 +0000 (17:34 +0100)] 
Programming FAQ: fix some punctuaction typos (GH-144058)

Co-authored-by: Stan Ulbrych <89152624+StanFromIreland@users.noreply.github.com>
6 days agogh-144125: email: verify headers are sound in BytesGenerator
Seth Michael Larson [Fri, 23 Jan 2026 14:59:35 +0000 (08:59 -0600)] 
gh-144125: email: verify headers are sound in BytesGenerator

Co-authored-by: Denis Ledoux <dle@odoo.com>
Co-authored-by: Denis Ledoux <5822488+beledouxdenis@users.noreply.github.com>
Co-authored-by: Petr Viktorin <302922+encukou@users.noreply.github.com>
Co-authored-by: Bas Bloemsaat <1586868+basbloemsaat@users.noreply.github.com>
7 days agoDoc: fix incorrect reference in `isasyncgenfunction` docs (GH-144099)
Yongtao Huang [Fri, 23 Jan 2026 08:06:47 +0000 (16:06 +0800)] 
Doc: fix incorrect reference in `isasyncgenfunction` docs (GH-144099)

Fix incorrect reference in isasyncgenfunction docs

7 days agogh-143513: Remove importlib.abc documentation for removed ABCs (#143605)
Alex Willmer [Thu, 22 Jan 2026 22:00:37 +0000 (22:00 +0000)] 
gh-143513: Remove importlib.abc documentation for removed ABCs (#143605)

In 3.11 ResourceReader, Traversable, & TraversableResources moved from importlib.abc to importlib.resources.abc (commit e712a5b277866a71c195f38c1b5d87d9126dba3e).

In 3.12 old import locations were deprecated (commit 71848c960927af801656026203371c41ad139b5a).

In 3.14 backwards-compat support was removed (commit 0751511d24295c39fdf2f5b2255e3fa3d796ce4d).

Co-authored-by: Brett Cannon <brett@python.org>
7 days agoAdd source links to documentation for Windows-specific modules (GH-130244)
Dimma Don't [Thu, 22 Jan 2026 21:30:13 +0000 (16:30 -0500)] 
Add source links to documentation for Windows-specific modules (GH-130244)

7 days agogh-143756: Avoid borrowed reference in SSL code (gh-143816)
Sam Gross [Thu, 22 Jan 2026 19:02:48 +0000 (14:02 -0500)] 
gh-143756: Avoid borrowed reference in SSL code (gh-143816)

GET_SOCKET() returned a borrowed reference, which was potentially
unsafe. Also, refactor out some common code.

7 days agogh-143756: Fix potential data race in SSLContext.load_cert_chain (gh-143818)
Sam Gross [Thu, 22 Jan 2026 19:02:30 +0000 (14:02 -0500)] 
gh-143756: Fix potential data race in SSLContext.load_cert_chain (gh-143818)

Concurrent calls to `load_cert_chain` caused data races in OpenSSL code.

7 days agogh-144157: Optimize bytes.translate() by deferring change detection (GH-144158)
Gregory P. Smith [Thu, 22 Jan 2026 17:21:07 +0000 (09:21 -0800)] 
gh-144157: Optimize bytes.translate() by deferring change detection (GH-144158)

Optimize bytes.translate() by deferring change detection

Move the equality check out of the hot loop to allow better compiler
optimization. Instead of checking each byte during translation, perform
a single memcmp at the end to determine if the input can be returned
unchanged.

This allows compilers to unroll and pipeline the loops, resulting in ~2x
throughput improvement for medium-to-large inputs (tested on an AMD zen2).
No change observed on small inputs.

It will also be faster for bytes subclasses as those do not need change
detection.

7 days agogh-142779: Initialize reserved field for proper padding (#142780)
stratakis [Thu, 22 Jan 2026 17:06:36 +0000 (18:06 +0100)] 
gh-142779: Initialize reserved field for proper padding (#142780)

The jitdump specification specifies a reserved field for padding.

Initialize it so no garbage data is embedded in the jitdump files.

8 days agogh-67041: Allow to distinguish between empty and not defined URI components (GH-123305)
Serhiy Storchaka [Thu, 22 Jan 2026 12:29:13 +0000 (14:29 +0200)] 
gh-67041: Allow to distinguish between empty and not defined URI components (GH-123305)

Changes in the urllib.parse module:

* Add option missing_as_none in urlparse(), urlsplit() and urldefrag(). If
  it is true, represent not defined components as None instead of an
  empty string.
* Add option keep_empty in urlunparse() and urlunsplit(). If it is
  true, keep empty non-None components in the resulting string.

8 days agogh-143001: Add @cpython_only to test_sys.test_current_frames() (#144004)
Jeong, YunWon [Thu, 22 Jan 2026 11:08:08 +0000 (20:08 +0900)] 
gh-143001: Add @cpython_only to test_sys.test_current_frames() (#144004)

8 days agoGH-139109: Partial reworking of JIT data structures (GH-144105)
Mark Shannon [Thu, 22 Jan 2026 10:55:49 +0000 (10:55 +0000)] 
GH-139109: Partial reworking of JIT data structures (GH-144105)

* Halve size of buffers by reusing combined trace + optimizer buffers for TOS caching
* Add simple buffer struct for more maintainable handling of buffers
* Decouple JIT structs from thread state struct
* Ensure terminator is added to trace, when optimizer gives up

8 days agogh-141004: Mark up constants for `PyOS_double_to_string` (GH-143867)
Petr Viktorin [Thu, 22 Jan 2026 10:53:17 +0000 (11:53 +0100)] 
gh-141004: Mark up constants for `PyOS_double_to_string` (GH-143867)

This ensures they show up as C macros in search and the Sphinx inventory.

8 days agogh-143959: Make _datetime optional for test_sys (GH-144003)
Jeong, YunWon [Thu, 22 Jan 2026 10:52:16 +0000 (19:52 +0900)] 
gh-143959: Make _datetime optional for test_sys (GH-144003)

8 days agogh-143993: Document ways to disable remote debugging support (#143994)
Rafael Weingartner-Ortner [Thu, 22 Jan 2026 10:41:20 +0000 (11:41 +0100)] 
gh-143993: Document ways to disable remote debugging support (#143994)

Although PEP 768 mentions how to disable the mechanism of
remote debugging, it is not documented in the Python docs.

This change adds a note on how to disable remote debugging support
in a Python interpreter to the remote debugging how-to.

Co-authored-by: Hugo van Kemenade <1324225+hugovk@users.noreply.github.com>
8 days agogh-142913: Revert adding test_replaced_interpreter (GH-144110)
Petr Viktorin [Thu, 22 Jan 2026 09:40:34 +0000 (10:40 +0100)] 
gh-142913: Revert adding test_replaced_interpreter (GH-144110)

This partially reverts commit 4d5a676aa0811563ea78ae58ef89cdc0295bf7ed
(GH-142911)

The removed test fails when re-run in --huntrleaks mode.

8 days agogh-130415: Narrowing to constants in branches involving `is` comparisons with a const...
reiden [Thu, 22 Jan 2026 09:37:45 +0000 (17:37 +0800)] 
gh-130415: Narrowing to constants in branches involving `is` comparisons with a constant (GH-143895)

8 days agoGH-143941: Move WASI-related files to Platforms/WASI (GH-143942)
Brett Cannon [Wed, 21 Jan 2026 22:31:58 +0000 (14:31 -0800)] 
GH-143941: Move WASI-related files to Platforms/WASI (GH-143942)

Along the way, leave a deprecated Tools/wasm/wasi/__main__.py behind for backwards-compatibility.

Co-authored-by: Zachary Ware <zachary.ware@gmail.com>
8 days agogh-77188: Add pickle tests for objects with slots (GH-144116)
Serhiy Storchaka [Wed, 21 Jan 2026 17:21:02 +0000 (19:21 +0200)] 
gh-77188: Add pickle tests for objects with slots (GH-144116)

8 days agoGH-138245: Perform boolean guards by testing a single bit, rather than a full pointer...
Mark Shannon [Wed, 21 Jan 2026 15:58:27 +0000 (15:58 +0000)] 
GH-138245: Perform boolean guards by testing a single bit, rather than a full pointer comparison. (GH-143810)

8 days agoUpdate install manager docs (python/pymanager#227) (GH-144079)
Steve Dower [Wed, 21 Jan 2026 15:33:05 +0000 (15:33 +0000)] 
Update install manager docs (python/pymanager#227) (GH-144079)

8 days agogh-144030: Add check that argument is callable to Python version of functools.lru_cac...
CF Bolz-Tereick [Wed, 21 Jan 2026 14:19:19 +0000 (15:19 +0100)] 
gh-144030: Add check that argument is callable to Python version of functools.lru_cache (#144031)

Co-authored-by: sobolevn <mail@sobolevn.me>
Co-authored-by: AN Long <aisk@users.noreply.github.com>
8 days agogh-143869: Add PEP 757 functions to the limited API (#143906)
Sergey B Kirpichev [Wed, 21 Jan 2026 13:47:14 +0000 (16:47 +0300)] 
gh-143869: Add PEP 757 functions to the limited API (#143906)

Co-authored-by: Petr Viktorin <encukou@gmail.com>
9 days agogh-144085: Add `{gi,cr}_suspended` to `inspect` comments and `generator/coroutine...
Yongtao Huang [Wed, 21 Jan 2026 10:33:56 +0000 (18:33 +0800)] 
gh-144085: Add `{gi,cr}_suspended` to `inspect` comments and `generator/coroutine` tests (#144086)

9 days agogh-125346: Deprecate accepting standard Base64 alphabet when alternative alphabet...
Serhiy Storchaka [Wed, 21 Jan 2026 07:41:58 +0000 (09:41 +0200)] 
gh-125346: Deprecate accepting standard Base64 alphabet when alternative alphabet is used (GH-141128)

Emit a warning in base64.urlsafe_b64decode() and base64.b64decode() when
the "+" or "/" characters occur in the Base64 data with alternative
alphabet if they are not the part of the alternative alphabet.

It is a DeprecationWarning in the strict mode (will be error) and
a FutureWarning in non-strict mode (will be ignored).

9 days agoGH-143948: Explain graphlib's cycle-finding code (#143950)
Tim Peters [Wed, 21 Jan 2026 01:28:48 +0000 (19:28 -0600)] 
GH-143948: Explain graphlib's cycle-finding code (#143950)

Explain topsort's cycle-finding algorithm, and why it's written that way.

Co-authored-by: Bénédikt Tran <10796600+picnixz@users.noreply.github.com>
9 days agogh-143919: Reject control characters in http cookies
Seth Michael Larson [Tue, 20 Jan 2026 21:23:42 +0000 (15:23 -0600)] 
gh-143919: Reject control characters in http cookies

Co-authored-by: Bartosz Sławecki <bartosz@ilikepython.com>
Co-authored-by: sobolevn <mail@sobolevn.me>
9 days agogh-143923: Reject control characters in POP3 commands
Seth Michael Larson [Tue, 20 Jan 2026 20:46:32 +0000 (14:46 -0600)] 
gh-143923: Reject control characters in POP3 commands

9 days agogh-143925: Reject control characters in data: URL mediatypes
Seth Michael Larson [Tue, 20 Jan 2026 20:45:58 +0000 (14:45 -0600)] 
gh-143925: Reject control characters in data: URL mediatypes

9 days agogh-143921: Reject control characters in IMAP commands
Seth Michael Larson [Tue, 20 Jan 2026 20:45:42 +0000 (14:45 -0600)] 
gh-143921: Reject control characters in IMAP commands

9 days agogh-141504: Move PYTHON_UOPS_OPTIMIZE to policy object (GH-144082)
Donghee Na [Tue, 20 Jan 2026 18:47:38 +0000 (03:47 +0900)] 
gh-141504: Move PYTHON_UOPS_OPTIMIZE to policy object (GH-144082)

9 days agogh-144054: no deferred refcount for untracked (gh-144081)
Neil Schemenauer [Tue, 20 Jan 2026 18:01:09 +0000 (10:01 -0800)] 
gh-144054: no deferred refcount for untracked (gh-144081)

This reverts gh-144055 and fixes the bug in a different way.  Deferred
reference counting relies on the object being tracked by the GC,
otherwise the object will live until interpreter shutdown.  So, take
care that we do not enable deferred reference counting for objects that
are untracked.  Also, if a tuple has deferred reference counting
enabled, don't untrack it.

9 days agogh-143939: Fix assignment to `_PyThreadStateImpl.generator_return_kind` (gh-143951)
Sam Gross [Tue, 20 Jan 2026 17:51:55 +0000 (12:51 -0500)] 
gh-143939: Fix assignment to `_PyThreadStateImpl.generator_return_kind` (gh-143951)

The assignment to generator_return_kind has to be after any potentially
escaping calls to ensure that it's not overwritten.

9 days agogh-143960: Add support for OpenSSL 3.6, drop EOL 3.2 (#143961)
Hugo van Kemenade [Tue, 20 Jan 2026 15:25:31 +0000 (17:25 +0200)] 
gh-143960: Add support for OpenSSL 3.6, drop EOL 3.2 (#143961)

Co-authored-by: Gregory P. Smith <68491+gpshead@users.noreply.github.com>
9 days agogh-144054: shutdown fix for deferred ref counting (GH-144055)
Neil Schemenauer [Tue, 20 Jan 2026 13:45:12 +0000 (05:45 -0800)] 
gh-144054: shutdown fix for deferred ref counting (GH-144055)

When shutting down, disable deferred refcounting for all GC objects. It
is important to do this also for untracked objects, which before this
change were getting missed.

Small code cleanup:
We can remove the shutdown case disable_deferred_refcounting() call
inside scan_heap_visitor() if we are careful about it.  The key is
that frame_disable_deferred_refcounting() might fail if the object
is untracked.

10 days agoUpdate struct.__doc__: _Bool available unconditionally (#143716)
Sergey B Kirpichev [Tue, 20 Jan 2026 12:09:20 +0000 (15:09 +0300)] 
Update struct.__doc__: _Bool available unconditionally (#143716)

This amends commit a9296e7f3be4d6c22271b25c86467ff867c63bbb.

10 days agogh-144050: Fix stat.filemode pure Python file type detection (GH-144059)
VanshAgarwal24036 [Tue, 20 Jan 2026 12:05:42 +0000 (17:35 +0530)] 
gh-144050: Fix stat.filemode pure Python file type detection (GH-144059)

10 days agogh-143999: Fix: handle suspended state on types.coroutine wrappers (GH-144000)
Yongtao Huang [Tue, 20 Jan 2026 10:20:06 +0000 (18:20 +0800)] 
gh-143999: Fix: handle suspended state on types.coroutine wrappers (GH-144000)

10 days agogh-144023: Prevent follow_symlinks from being allowed with an fd of 0 (GH-144022)
AZero13 [Tue, 20 Jan 2026 09:50:51 +0000 (04:50 -0500)] 
gh-144023: Prevent follow_symlinks from being allowed with an fd of 0 (GH-144022)

The check was (fd > 0), should be (fd >= 0).

10 days agogh-143774 - Improve IDLE Format Paragraph doc (#143775)
Terry Jan Reedy [Tue, 20 Jan 2026 09:07:29 +0000 (04:07 -0500)] 
gh-143774 - Improve IDLE Format Paragraph doc (#143775)

Add a reminder to not rewrap code line to the Menu => Format => Reformat Paragraph entry.
In Editing and Nagivagion, add a new 'Format block' subsection that defines 'paragraph'
to better match what is dependably handled as more or less expected.
In particular, specify equal indents and that the resulting indent equals original indent.
Also mention that selections are expanded to complete lines and how to modify max length.

(Also fix a couple case errors in cross references.)

10 days agogh-143754: Add Tkinter methods pack_content(), place_content() and grid_content(...
Serhiy Storchaka [Tue, 20 Jan 2026 07:16:36 +0000 (09:16 +0200)] 
gh-143754: Add Tkinter methods pack_content(), place_content() and grid_content() (GH-143845)

They use Tk commands with new name like "pack content instead of old
"pack slaves".

10 days agoFix typo: 'exept' -> 'except' in Lib/dbm/dumb.py (GH-144060)
Bodhi Silberling [Tue, 20 Jan 2026 06:50:34 +0000 (22:50 -0800)] 
Fix typo: 'exept' -> 'except' in Lib/dbm/dumb.py (GH-144060)

10 days agogh-143874: Use self.message instead of raw print in `_exec_in_closure()` (#143875)
Yongtao Huang [Tue, 20 Jan 2026 00:11:07 +0000 (08:11 +0800)] 
gh-143874: Use self.message instead of raw print in `_exec_in_closure()`  (#143875)

10 days agogh-102809: No longer mention `Misc/gdbinit` in the code (#143980)
Bartosz Sławecki [Mon, 19 Jan 2026 17:36:55 +0000 (18:36 +0100)] 
gh-102809: No longer mention `Misc/gdbinit` in the code (#143980)

Fix misleading comment on `PyObject_Dump`.

10 days agogh-106318: Add examples for str.rpartition() method (#143891)
Adorilson Bezerra [Mon, 19 Jan 2026 14:15:55 +0000 (14:15 +0000)] 
gh-106318: Add examples for str.rpartition() method (#143891)

10 days agogh-143689: Fix BufferedReader.read1 leaving object in reentrant state on error (...
Yongtao Huang [Mon, 19 Jan 2026 14:09:30 +0000 (22:09 +0800)] 
gh-143689: Fix BufferedReader.read1 leaving object in reentrant state on error (#143690)

BufferedReader.read1() could leave the buffered object in a
reentrant (locked) state when an exception was raised while
allocating the output buffer.

This change ensures the internal buffered lock is always released
on error, keeping the object in a consistent state after failures.

Signed-off-by: Yongtao Huang <yongtaoh2022@gmail.com>
Co-authored-by: blurb-it[bot] <43283697+blurb-it[bot]@users.noreply.github.com>
Co-authored-by: Cody Maloney <cmaloney@users.noreply.github.com>
Co-authored-by: sobolevn <mail@sobolevn.me>
10 days agogh-142461: Move misplaced NEWS entries to an appropriate section (GH-143392)
Aniket [Mon, 19 Jan 2026 12:59:26 +0000 (18:29 +0530)] 
gh-142461: Move misplaced NEWS entries to an appropriate section (GH-143392)

11 days agogh-143935: Email preserve parens when folding comments (#143936)
Seth Michael Larson [Mon, 19 Jan 2026 12:38:22 +0000 (06:38 -0600)] 
gh-143935: Email preserve parens when folding comments (#143936)

Fix a bug in the folding of comments when flattening an email message
using a modern email policy. Comments consisting of a very long sequence of
non-foldable characters could trigger a forced line wrap that omitted the
required leading space on the continuation line, causing the remainder of
the comment to be interpreted as a new header field. This enabled header
injection with carefully crafted inputs.

Co-authored-by: Denis Ledoux <dle@odoo.com>
11 days agogh-143897: Remove the isxidstart() and isxidcontinue() methods of unicodedata.ucd_3_2...
Serhiy Storchaka [Mon, 19 Jan 2026 12:37:41 +0000 (14:37 +0200)] 
gh-143897: Remove the isxidstart() and isxidcontinue() methods of unicodedata.ucd_3_2_0 (GH-143898)

They are now only exposed as the unicodedata function.

11 days agogh-142440: Fix _decimal builds configured with EXTRA_FUNCTIONALITY (GH-142441)
AZero13 [Mon, 19 Jan 2026 12:19:20 +0000 (07:19 -0500)] 
gh-142440: Fix _decimal builds configured with EXTRA_FUNCTIONALITY (GH-142441)

There was a typo in _decimal.Context.apply().

11 days agogh-143754: Modernize Tkinter docs (GH-143841)
Serhiy Storchaka [Mon, 19 Jan 2026 12:01:29 +0000 (14:01 +0200)] 
gh-143754: Modernize Tkinter docs (GH-143841)

Use more relevant terminology instead of "master"/"slave" widgets where possible.

11 days agogh-143866: Verify return value of `pathlib.write_{bytes,text}` methods in tests ...
b9788213 [Mon, 19 Jan 2026 11:24:20 +0000 (14:24 +0300)] 
gh-143866: Verify return value of `pathlib.write_{bytes,text}` methods in tests (#143870)

Co-authored-by: sobolevn <mail@sobolevn.me>
11 days agogh-75459: versionadded for PyObject_CallFinalizer*() API (GH-143982)
Sergey B Kirpichev [Mon, 19 Jan 2026 10:22:16 +0000 (13:22 +0300)] 
gh-75459: versionadded for PyObject_CallFinalizer*() API (GH-143982)

11 days agogh-143831: Compare cells by identity in forward references (#143848)
Bartosz Sławecki [Mon, 19 Jan 2026 05:29:11 +0000 (06:29 +0100)] 
gh-143831: Compare cells by identity in forward references (#143848)

11 days agoNotify Sviat of GHA changes through codeowners (#143945)
🇺🇦 Sviatoslav Sydorenko (Святослав Сидоренко) [Sun, 18 Jan 2026 22:28:38 +0000 (23:28 +0100)] 
Notify Sviat of GHA changes through codeowners (#143945)

Co-authored-by: Hugo van Kemenade <1324225+hugovk@users.noreply.github.com>
11 days agogh-141860: Add on_error= keyword arg to `multiprocessing.set_forkserver_preload`...
Gregory P. Smith [Sun, 18 Jan 2026 22:04:18 +0000 (14:04 -0800)] 
gh-141860: Add on_error= keyword arg to `multiprocessing.set_forkserver_preload` (GH-141859)

Add a keyword-only `on_error` parameter to `multiprocessing.set_forkserver_preload()`. This allows the user to have exceptions during optional `forkserver` start method module preloading cause the forkserver subprocess to warn (generally to stderr) or exit with an error (preventing use of the forkserver) instead of being silently ignored.

This _also_ fixes an oversight, errors when preloading a `__main__` module are now treated the similarly. Those would always raise unlike other modules in preload, but that had gone unnoticed as up until bug fix PR GH-135295 in 3.14.1 and 3.13.8, the `__main__` module was never actually preloaded.

Based on original work by Nick Neumann @aggieNick02 in GH-99515.

11 days agogh-144012: Check null binary op extend (#144014)
AN Long [Sun, 18 Jan 2026 18:38:37 +0000 (03:38 +0900)] 
gh-144012: Check null binary op extend (#144014)

12 days agogh-143952: Fix asyncio tools to work with the new remote debugging API (#143954)
Bartosz Sławecki [Sun, 18 Jan 2026 00:16:12 +0000 (01:16 +0100)] 
gh-143952: Fix asyncio tools to work with the new remote debugging API (#143954)

12 days agoFix UBSan error in _testcapi: correct create_attr_from_spec signature (#143097)
Shamil [Sat, 17 Jan 2026 18:05:09 +0000 (21:05 +0300)] 
Fix UBSan error in _testcapi: correct create_attr_from_spec signature (#143097)

Co-authored-by: sobolevn <mail@sobolevn.me>
12 days ago gh-143916: Reject control characters in wsgiref.headers.Headers (GH-143917)
Seth Michael Larson [Sat, 17 Jan 2026 17:46:21 +0000 (11:46 -0600)] 
 gh-143916: Reject control characters in wsgiref.headers.Headers  (GH-143917)

* Add 'test.support' fixture for C0 control characters
* gh-143916: Reject control characters in wsgiref.headers.Headers

12 days agogh-143421: Use new buffer to save optimized uops (GH-143682)
Hai Zhu [Sat, 17 Jan 2026 15:52:16 +0000 (23:52 +0800)] 
gh-143421: Use new buffer to save  optimized uops (GH-143682)

12 days agogh-141004: Document `PyException_HEAD` and `PyDescr_COMMON` (GH-143896)
Peter Bierma [Sat, 17 Jan 2026 15:39:29 +0000 (07:39 -0800)] 
gh-141004: Document `PyException_HEAD` and `PyDescr_COMMON` (GH-143896)

12 days agogh-143946: Show `JitOptSymbol` on abstract stack when set PYTHON_OPT_DEBUG > 4 (GH...
Hai Zhu [Sat, 17 Jan 2026 15:20:35 +0000 (23:20 +0800)] 
gh-143946: Show `JitOptSymbol` on abstract stack when set PYTHON_OPT_DEBUG > 4 (GH-143957)

12 days agogh-142913: Export JIT functions for _testinternalcapi (#143958)
Ken Jin [Sat, 17 Jan 2026 13:31:38 +0000 (21:31 +0800)] 
gh-142913: Export JIT functions for _testinternalcapi (#143958)

* Export JIT functions for _testinternalcapi

* Add testinternalcapi to paths to run JIT CI on

13 days agogh-143943: add missing header file for `pycore_optimizer_types.h` (GH-143947)
Hai Zhu [Sat, 17 Jan 2026 12:26:19 +0000 (20:26 +0800)] 
gh-143943: add missing header file for `pycore_optimizer_types.h` (GH-143947)

13 days agogh-132657: Add maybe_enable_deferred_ref_count() (gh-142843)
Neil Schemenauer [Sat, 17 Jan 2026 01:54:43 +0000 (17:54 -0800)] 
gh-132657: Add maybe_enable_deferred_ref_count() (gh-142843)

If we are specializing to `LOAD_GLOBAL_MODULE` or `LOAD_ATTR_MODULE`, try
to enable deferred reference counting for the value, if the object is owned by
a different thread.  This applies to the free-threaded build only and should
improve scaling of multi-threaded programs.

13 days agogh-142913: Remove JIT interpreter for interpreter generator tests (GH-143944)
Ken Jin [Sat, 17 Jan 2026 00:34:39 +0000 (08:34 +0800)] 
gh-142913: Remove JIT interpreter for interpreter generator tests (GH-143944)

13 days agogh-138122: Default highlight to sh (#143782)
Hugo van Kemenade [Fri, 16 Jan 2026 19:40:28 +0000 (21:40 +0200)] 
gh-138122: Default highlight to sh (#143782)

13 days ago gh-142913: Update generated code that conflicted with other landed change (#143932)
Dino Viehland [Fri, 16 Jan 2026 19:10:15 +0000 (11:10 -0800)] 
 gh-142913: Update generated code that conflicted with other landed change (#143932)

Update test cases

13 days agogh-142913: Add test case for interpreter generator w/ overridden opcodes (#142911)
Dino Viehland [Fri, 16 Jan 2026 18:33:29 +0000 (10:33 -0800)] 
gh-142913: Add test case for interpreter generator w/ overridden opcodes (#142911)

Add test case for interpreter generator w/ overridden opcodes