]> git.ipfire.org Git - thirdparty/Python/cpython.git/log
thirdparty/Python/cpython.git
3 months agogh-140544: fix build for including `pycore_pystate.h` when `HAVE_THREAD_LOCAL` is... 140694/head
Kumar Aditya [Mon, 27 Oct 2025 20:10:41 +0000 (01:40 +0530)] 
gh-140544: fix build for including `pycore_pystate.h` when `HAVE_THREAD_LOCAL` is not defined (#140623)

3 months agogh-140634: Fix a reference counting bug in os.sched_param.__reduce__() (GH-140667)
Serhiy Storchaka [Mon, 27 Oct 2025 19:42:32 +0000 (21:42 +0200)] 
gh-140634: Fix a reference counting bug in os.sched_param.__reduce__() (GH-140667)

3 months agogh-140104: Set next_instr properly in the JIT during exceptions (GH-140233)
Ken Jin [Mon, 27 Oct 2025 18:26:47 +0000 (02:26 +0800)] 
gh-140104: Set next_instr properly in the JIT during exceptions (GH-140233)

Co-authored-by: devdanzin <74280297+devdanzin@users.noreply.github.com>
Co-authored-by: Chris Eibl <138194463+chris-eibl@users.noreply.github.com>
3 months agogh-140607: Validate returned byte count in RawIOBase.read (#140611)
Cody Maloney [Mon, 27 Oct 2025 18:06:46 +0000 (11:06 -0700)] 
gh-140607: Validate returned byte count in RawIOBase.read (#140611)

While `RawIOBase.readinto` should return a count of bytes between 0 and
the length of the given buffer, it is not required to. Add validation
inside RawIOBase.read() that the returned byte count is valid.

Co-authored-by: Shamil <ashm.tech@proton.me>
Co-authored-by: Victor Stinner <vstinner@python.org>
3 months agogh-125434: Display thread name in faulthandler on Windows (#140675)
Victor Stinner [Mon, 27 Oct 2025 17:41:18 +0000 (18:41 +0100)] 
gh-125434: Display thread name in faulthandler on Windows (#140675)

3 months agogh-138050: [WIP] JIT - Streamline MAKE_WARM - move coldness check to executor creatio...
alm [Mon, 27 Oct 2025 16:37:37 +0000 (18:37 +0200)] 
gh-138050: [WIP] JIT - Streamline MAKE_WARM - move coldness check to executor creation (GH-138240)

3 months agogh-79922: Remove always false test skips in `test_time` (#136202)
Stan Ulbrych [Mon, 27 Oct 2025 15:09:25 +0000 (15:09 +0000)] 
gh-79922: Remove always false test skips in `test_time` (#136202)

3 months agogh-116738: Use PyMutex for bz2 module (gh-140555)
Alper [Mon, 27 Oct 2025 13:52:30 +0000 (06:52 -0700)] 
gh-116738: Use PyMutex for bz2 module (gh-140555)

The methods are already wrapped with a lock, which makes them thread-safe in
free-threaded build. This replaces `PyThread_acquire_lock` with `PyMutex` and
removes some macros and allocation handling code.

Also add a test for free-threading to ensure we aren't getting data races and
that the locking is working.

3 months agogh-140641: Break out of inittab search on match (GH-140642)
Itamar Oren [Mon, 27 Oct 2025 13:18:58 +0000 (06:18 -0700)] 
gh-140641: Break out of inittab search on match (GH-140642)

3 months agogh-140487: Fix Py_RETURN_NOTIMPLEMENTED in limited C API 3.11 (GH-140636)
Victor Stinner [Mon, 27 Oct 2025 11:59:56 +0000 (12:59 +0100)] 
gh-140487: Fix Py_RETURN_NOTIMPLEMENTED in limited C API 3.11 (GH-140636)

Py_RETURN_NONE, Py_RETURN_TRUE and Py_RETURN_FALSE have already been
fixed by commit 9258f3da9175134d03f2c8c7c7eed223802ad945 (issue gh-134989).

3 months agogh-134160: Add more comments for the xxlimited module (GH-140214)
Petr Viktorin [Mon, 27 Oct 2025 10:39:42 +0000 (11:39 +0100)] 
gh-134160: Add more comments for the xxlimited module (GH-140214)

3 months agoDocs: Replace "encoder" with "decoder" in `Doc/c-api/codec.rst` (#140613)
RayXu [Mon, 27 Oct 2025 09:43:24 +0000 (17:43 +0800)] 
Docs: Replace "encoder" with "decoder" in `Doc/c-api/codec.rst` (#140613)

3 months agogh-140633: AppleFrameworkLoader: Ignore AttributeError when setting __file__ (GH...
Petr Viktorin [Mon, 27 Oct 2025 09:09:22 +0000 (10:09 +0100)] 
gh-140633: AppleFrameworkLoader: Ignore AttributeError when setting __file__ (GH-140635)

3 months agoRemove dead stores to 'size' in UTF-8 decoder (unicodeobject.c) (#140637)
Shamil [Mon, 27 Oct 2025 08:55:57 +0000 (11:55 +0300)] 
Remove dead stores to 'size' in UTF-8 decoder (unicodeobject.c) (#140637)

3 months agoFix typo in TLS docs (#140640)
da-woods [Mon, 27 Oct 2025 04:58:30 +0000 (04:58 +0000)] 
Fix typo in TLS docs (#140640)

3 months agogh-138944: Fix `SyntaxError` message for invalid syntax following valid import-as...
Brian Schubert [Sun, 26 Oct 2025 22:35:21 +0000 (18:35 -0400)] 
gh-138944: Fix `SyntaxError` message for invalid syntax following valid import-as statement (#138945)

3 months agogh-140609: delete unused `_stdlib_enums` in enum.py (#140618)
yihong [Sun, 26 Oct 2025 17:37:31 +0000 (01:37 +0800)] 
gh-140609: delete unused `_stdlib_enums` in enum.py (#140618)

Signed-off-by: yihong0618 <zouzou0208@gmail.com>
3 months agogh-137568: Ignore startup file in `test_dumb_terminal_exits_cleanly` (GH-140295)
Bartosz Sławecki [Sun, 26 Oct 2025 14:48:03 +0000 (15:48 +0100)] 
gh-137568: Ignore startup file in `test_dumb_terminal_exits_cleanly` (GH-140295)

3 months agogh-140593: Fix a memory leak in function `my_ElementDeclHandler` of `pyexpat` (#140602)
Sebastian Pipping [Sun, 26 Oct 2025 13:45:32 +0000 (14:45 +0100)] 
gh-140593: Fix a memory leak in function `my_ElementDeclHandler` of `pyexpat` (#140602)

Ensure that the memory allocated for the content model
passed to `my_ElementDeclHandler` is freed in all error
paths.

3 months agogh-133346: add tests for `_colorize.Theme` (#139687)
Bénédikt Tran [Sun, 26 Oct 2025 12:07:31 +0000 (13:07 +0100)] 
gh-133346: add tests for `_colorize.Theme` (#139687)

3 months agogh-133346: make `_colorize.Argparse` kw-only constructible (#140620)
Bénédikt Tran [Sun, 26 Oct 2025 11:33:57 +0000 (12:33 +0100)] 
gh-133346: make `_colorize.Argparse` kw-only constructible (#140620)

Other themes are kw-only constructible.

3 months agogh-76007: Deprecate `__version__` attribute in `decimal` (#140302)
Stan Ulbrych [Sun, 26 Oct 2025 11:01:04 +0000 (11:01 +0000)] 
gh-76007: Deprecate `__version__` attribute in `decimal` (#140302)

Co-authored-by: Victor Stinner <vstinner@python.org>
Co-authored-by: Sergey B Kirpichev <skirpichev@gmail.com>
Co-authored-by: Hugo van Kemenade <1324225+hugovk@users.noreply.github.com>
3 months agoDocs: Fix a grammatical error in `Doc/c-api/codec.rst` (#140612)
RayXu [Sun, 26 Oct 2025 09:39:32 +0000 (17:39 +0800)] 
Docs: Fix a grammatical error in `Doc/c-api/codec.rst` (#140612)

3 months agogh-124694: Add versionadded note to InterpreterPoolExecutor (#140468)
Zachary Ware [Sat, 25 Oct 2025 23:29:46 +0000 (18:29 -0500)] 
gh-124694: Add versionadded note to InterpreterPoolExecutor (#140468)

3 months agoFix typo in `Doc/c-api/code.rst` (#140586)
RayXu [Sat, 25 Oct 2025 15:34:45 +0000 (23:34 +0800)] 
Fix typo in `Doc/c-api/code.rst` (#140586)

3 months agoRemove unreachable break statements in _ctypes_test.c (#140585)
Shamil [Sat, 25 Oct 2025 14:59:12 +0000 (17:59 +0300)] 
Remove unreachable break statements in _ctypes_test.c (#140585)

3 months agogh-140544: use faster `_PyInterpreterState_GET` for type lock (#140584)
Kumar Aditya [Sat, 25 Oct 2025 14:53:26 +0000 (20:23 +0530)] 
gh-140544: use faster `_PyInterpreterState_GET` for type lock (#140584)

3 months agogh-140544: store pointer to interpreter state as a thread local for fast access ...
Kumar Aditya [Sat, 25 Oct 2025 14:26:07 +0000 (19:56 +0530)] 
gh-140544: store pointer to interpreter state as a thread local for fast access (#140573)

3 months agoDocs: Fix a grammatical error in `Doc/c-api/capsule.rst` (GH-140577)
RayXu [Sat, 25 Oct 2025 13:54:52 +0000 (21:54 +0800)] 
Docs: Fix a grammatical error in `Doc/c-api/capsule.rst` (GH-140577)

"who" -> "which"

3 months agoAdd missing NEWS entry for gh-140517 (GH-140560)
Mikhail Efimov [Fri, 24 Oct 2025 19:53:00 +0000 (22:53 +0300)] 
Add missing NEWS entry for gh-140517 (GH-140560)

3 months agogh-136327: Fix inconsistent ``TypeError`` messages regarding invalid values after...
Tapeline [Fri, 24 Oct 2025 19:12:49 +0000 (00:12 +0500)] 
gh-136327: Fix inconsistent ``TypeError`` messages regarding invalid values after * and ** (#136395)

3 months agogh-140482: Preserve and restore `stty echo` as a test environment (#140519)
Barry Warsaw [Fri, 24 Oct 2025 18:07:08 +0000 (11:07 -0700)] 
gh-140482: Preserve and restore `stty echo` as a test environment (#140519)

gh-140482: Restore `stty echo` as a test environment

3 months agogh-140463: Fix typo in xmlrpc.client documentation (GH-140552)
Miša Jakovljević [Fri, 24 Oct 2025 16:04:43 +0000 (18:04 +0200)] 
gh-140463: Fix typo in xmlrpc.client documentation (GH-140552)

Fix typo in xmlrpc.client documentation

3 months agogh-140517: fix leak in `map_next` in strict mode (#140543)
Mikhail Efimov [Fri, 24 Oct 2025 15:59:16 +0000 (18:59 +0300)] 
gh-140517: fix leak in `map_next` in strict mode (#140543)

3 months agogh-140414: add fastpath for current running loop in `asyncio.all_tasks` (#140542)
Kumar Aditya [Fri, 24 Oct 2025 14:32:17 +0000 (20:02 +0530)] 
gh-140414: add fastpath for current running loop in `asyncio.all_tasks` (#140542)

Optimize `asyncio.all_tasks()` for the common case where the event loop is running in the current thread by avoiding stop-the-world pauses and locking.

This optimization is already present for `asyncio.current_task()` so we do the same for `asyncio.all_tasks()`.

3 months agogh-140544: cleanup `HAVE_THREAD_LOCAL` checks in pystate.c (#140547)
Kumar Aditya [Fri, 24 Oct 2025 14:23:06 +0000 (19:53 +0530)] 
gh-140544: cleanup `HAVE_THREAD_LOCAL` checks in pystate.c (#140547)

3 months agoDocument that PyModule_GetDef can return NULL with or without setting an exception...
Petr Viktorin [Fri, 24 Oct 2025 13:28:48 +0000 (15:28 +0200)] 
Document that PyModule_GetDef can return NULL with or without setting an exception (GH-140529)

3 months agoDocs: Fix a grammatical error in `Doc/c-api/arg.rst` (GH-140525)
RayXu [Fri, 24 Oct 2025 12:17:52 +0000 (20:17 +0800)] 
Docs: Fix a grammatical error in `Doc/c-api/arg.rst` (GH-140525)

"have" -> "has"

3 months agogh-136535: Tests: Correct `Py_TPFLAGS_MANAGED_DICT` in `test_class.py` (gh-136538)
Jiseok CHOI [Fri, 24 Oct 2025 11:20:09 +0000 (20:20 +0900)] 
gh-136535: Tests: Correct `Py_TPFLAGS_MANAGED_DICT` in `test_class.py` (gh-136538)

3 months agogh-138857: Improve error message for `case` outside of `match` (#138858)
sobolevn [Fri, 24 Oct 2025 09:20:54 +0000 (12:20 +0300)] 
gh-138857: Improve error message for `case` outside of `match` (#138858)

* gh-138857: Improve error message for `case` outside of `match`

---------

Co-authored-by: Bartosz Sławecki <bartosz@ilikepython.com>
3 months agogh-133390: sqlite3 CLI completion for tables, columns, indices, triggers, views,...
Tan Long [Fri, 24 Oct 2025 06:26:36 +0000 (14:26 +0800)] 
gh-133390: sqlite3 CLI completion for tables, columns, indices, triggers, views, functions, schemata (GH-136101)

3 months agogh-83714: Set os.statx().stx_mode to None if missing from stx_mask (#140484)
Victor Stinner [Thu, 23 Oct 2025 20:35:17 +0000 (22:35 +0200)] 
gh-83714: Set os.statx().stx_mode to None if missing from stx_mask (#140484)

* Set stx_mode to None if STATX_TYPE|STATX_MODE is missing from
  stx_mask.
* Enhance os.statx() tests.
* statx_result structure: remove atime_sec, btime_sec, ctime_sec and
  mtime_sec members. Compute them on demand when stx_atime,
  stx_btime, stx_ctime and stx_mtime are read.
* Doc: fix statx members sorting.

3 months agogh-140443: Use `fma` in `loghelper` to improve accuracy of log for very large integer...
Abhishek Tiwari [Thu, 23 Oct 2025 17:05:12 +0000 (22:35 +0530)] 
gh-140443: Use `fma` in `loghelper` to improve accuracy of log for very large integers (#140469)

* gh-140443:use fma in loghelper to improve accuracy of log for very large integers

Use fused multiply-add in log_helper() for huge ints.

Saving a rounding here is remarkably effective. Across some millions
of randomized test cases with ints up to a billion bits, on Windows
and using log10, the ULP error distribution was dramatically
flattened, and its range was nearly cut in half. In fact, the largest
error Tim saw was under 0.6 ULP.

---------

Co-authored-by: abhi210 <27881020+Abhi210@users.noreply.github.com>
Co-authored-by: Stan Ulbrych <89152624+StanFromIreland@users.noreply.github.com>
3 months agogh-135125: Fix Py_STACKREF_DEBUG build (GH-139475)
Mikhail Efimov [Thu, 23 Oct 2025 16:00:23 +0000 (19:00 +0300)] 
gh-135125: Fix Py_STACKREF_DEBUG build (GH-139475)

* Use the same pattern of refcounting for stackrefs as in production build

3 months agoGH-135904: JIT compiler: Support 19 bit branch instructions on AArch64 for Mach-O...
Mark Shannon [Thu, 23 Oct 2025 15:45:57 +0000 (16:45 +0100)] 
GH-135904: JIT compiler: Support 19 bit branch instructions on AArch64 for Mach-O. (GH-140453)

* Insert labels into assembly for custom relocation during stencil creation.

3 months agogh-140471: Fix buffer overflow in AST node initialization with malformed `_fields...
Stan Ulbrych [Thu, 23 Oct 2025 15:35:21 +0000 (16:35 +0100)] 
gh-140471: Fix buffer overflow in AST node initialization with malformed `_fields` (#140506)

3 months agogh-140438: properly run the asyncio REPL tests (#140298)
Bartosz Sławecki [Thu, 23 Oct 2025 15:23:23 +0000 (17:23 +0200)] 
gh-140438: properly run the asyncio REPL tests (#140298)

3 months agogh-140431: Fix GC crash due to partially initialized coroutines (gh-140470)
Sam Gross [Thu, 23 Oct 2025 14:18:13 +0000 (10:18 -0400)] 
gh-140431: Fix GC crash due to partially initialized coroutines (gh-140470)

The `make_gen()` function creates and tracks generator/coro objects, but
doesn't fully initialize all the fields. At a minimum, we need to
initialize all the fields that may be accessed by gen_traverse because
the call to `compute_cr_origin()` can trigger a GC.

3 months agogh-138774: use `value` to `ast.unparse` code when `str` is `None` in `ast.Interpolati...
George Ogden [Thu, 23 Oct 2025 13:56:05 +0000 (14:56 +0100)] 
gh-138774: use `value` to `ast.unparse` code when `str` is `None` in `ast.Interpolation` (#139415)

3 months agogh-137627: Make `csv.Sniffer.sniff()` delimiter detection 1.6x faster (#137628)
Maurycy Pawłowski-Wieroński [Thu, 23 Oct 2025 12:28:29 +0000 (14:28 +0200)] 
gh-137627: Make `csv.Sniffer.sniff()` delimiter detection 1.6x faster (#137628)

Co-authored-by: Bénédikt Tran <10796600+picnixz@users.noreply.github.com>
3 months agogh-140474: Fix memory leak in `array.array` (GH-140478)
Stan Ulbrych [Thu, 23 Oct 2025 09:49:27 +0000 (10:49 +0100)] 
gh-140474: Fix memory leak in `array.array` (GH-140478)

3 months agoGH-140472: Create a WASI devcontainer configuration (GH-140473)
Brett Cannon [Wed, 22 Oct 2025 23:11:48 +0000 (16:11 -0700)] 
GH-140472: Create a WASI devcontainer configuration (GH-140473)

3 months agoGH-140475: Support WASI SDK 25 (#140477)
Brett Cannon [Wed, 22 Oct 2025 21:34:37 +0000 (14:34 -0700)] 
GH-140475: Support WASI SDK 25 (#140477)

As well, bump the version of Wasmtime used in CI.

3 months agogh-140253: Improve the syntax error from an ill-positioned double-star subpattern...
Bartosz Sławecki [Wed, 22 Oct 2025 18:29:14 +0000 (20:29 +0200)] 
gh-140253: Improve the syntax error from an ill-positioned double-star subpattern (#140254)

3 months agogh-130317: Fix SNaN broken tests on HP PA RISC (#140452)
Stefano Rivera [Wed, 22 Oct 2025 16:36:12 +0000 (09:36 -0700)] 
gh-130317: Fix SNaN broken tests on HP PA RISC (#140452)

While looking at #140028, I found some unrelated test regressions in the
3.14 cycle. These seem to all come from #130317. From what I can tell,
that made Python more correct than it was before. According to [0], HP PA
RISC uses 1 for SNaN and thus a 0 for QNaN.

[0]: https://grouper.ieee.org/groups/1788/email/msg03272.html

3 months agogh-140448: Default `suggest_on_error` to `True` in `argparse.ArgumentParser` (#140450)
Jakob [Wed, 22 Oct 2025 16:15:26 +0000 (18:15 +0200)] 
gh-140448: Default `suggest_on_error` to `True` in `argparse.ArgumentParser` (#140450)

3 months agogh-116738: Add critical section to dbm/gdbm context manager (gh-140391)
Alper [Wed, 22 Oct 2025 15:16:28 +0000 (08:16 -0700)] 
gh-116738: Add critical section to dbm/gdbm context manager (gh-140391)

3 months agoGH-139193: Fix dump_stack when PYTHON_LLTRACE=4 (GH-139384)
Sergey Miryanov [Wed, 22 Oct 2025 13:14:25 +0000 (18:14 +0500)] 
GH-139193: Fix dump_stack when PYTHON_LLTRACE=4 (GH-139384)

3 months agogh-83714: Only use STATX_MNT_ID & STATX_SUBVOL if they're defined (GH-140446)
Petr Viktorin [Wed, 22 Oct 2025 10:42:51 +0000 (12:42 +0200)] 
gh-83714: Only use STATX_MNT_ID & STATX_SUBVOL if they're defined (GH-140446)

3 months agogh-83714: Use "stx_" prefix for all os.statx_result members (#140432)
Victor Stinner [Wed, 22 Oct 2025 09:48:37 +0000 (11:48 +0200)] 
gh-83714: Use "stx_" prefix for all os.statx_result members (#140432)

Rename stx_birthtime to stx_btime, and rename stx_birthtime_ns to
stx_btime_ns.

3 months agogh-116738: Make _suggestions module thread-safe (gh-140321)
Alper [Wed, 22 Oct 2025 00:14:48 +0000 (17:14 -0700)] 
gh-116738: Make _suggestions module thread-safe (gh-140321)

3 months agogh-55258: Skip tests of stdout status on mobile platforms (#140401)
Russell Keith-Magee [Tue, 21 Oct 2025 23:12:26 +0000 (07:12 +0800)] 
gh-55258: Skip tests of stdout status on mobile platforms (#140401)

Skip tests of stdout status on mobile platforms.

3 months agogh-132835: Add defensive NULL checks to MRO resolution (GH-134763)
Emma Smith [Tue, 21 Oct 2025 21:48:29 +0000 (14:48 -0700)] 
gh-132835: Add defensive NULL checks to MRO resolution (GH-134763)

Currently, there are a few places where tp_mro could theoretically
become NULL, but do not in practice. This commit adds defensive checks for
NULL values to ensure that any changes do not introduce a crash and that
state invariants are upheld.

The assertions added in this commit are all instances where a NULL value would get passed to something not expecting a NULL, so it is better to catch an assertion failure than crash later on.

There are a few cases where it is OK for the return of lookup_tp_mro to be NULL, such as when passed to is_subtype_with_mro, which handles this explicitly.

3 months agogh-69528: Distinguish between file modes "wb+" and "rb+" (GH-137834)
Stan Ulbrych [Tue, 21 Oct 2025 17:33:30 +0000 (18:33 +0100)] 
gh-69528: Distinguish between file modes "wb+" and "rb+" (GH-137834)

Co-authored-by: Xiang Zhang <angwerzx@126.com>
3 months agogh-83714: Check for struct statx members in configure (#140402)
Jeffrey Bosboom [Tue, 21 Oct 2025 16:13:14 +0000 (09:13 -0700)] 
gh-83714: Check for struct statx members in configure (#140402)

Some systems have the definitions of the mask bits without having the
corresponding members in struct statx.  Add configure checks for members
added after Linux 4.11 (when statx itself was added).

3 months agoUse ``sphinxext-opengraph`` v0.13.0 (GH-140425)
Adam Turner [Tue, 21 Oct 2025 16:02:43 +0000 (17:02 +0100)] 
Use ``sphinxext-opengraph`` v0.13.0 (GH-140425)

3 months agogh-138764: annotationlib: Make `call_annotate_function` fallback to using `VALUE...
David Ellis [Tue, 21 Oct 2025 15:57:43 +0000 (16:57 +0100)] 
gh-138764: annotationlib: Make `call_annotate_function` fallback to using `VALUE` annotations if both the requested format and `VALUE_WITH_FAKE_GLOBALS` are not implemented (#138803)

3 months agogh-140239: Check for statx on Android (#140395)
Jeffrey Bosboom [Tue, 21 Oct 2025 15:54:00 +0000 (08:54 -0700)] 
gh-140239: Check for statx on Android (#140395)

Android has Linux's statx, but MACHDEP is "android" on Android, so
configure doesn't check for statx on Android.  Base the check for statx
on ac_sys_system instead, which is "Linux-android" on Android, "Linux"
on other Linux distributions, and "AIX" on AIX (which has an
incompatible function named statx).

3 months agoGH-139951: Fix major GC performance regression (GH-140262)
Mark Shannon [Tue, 21 Oct 2025 14:22:15 +0000 (15:22 +0100)] 
GH-139951: Fix major GC performance regression (GH-140262)

* Count number of actually tracked objects, instead of trackable objects. This ensures that untracking tuples has the desired effect of reducing GC overhead

* Do not track most untrackable tuples during creation. This prevents large numbers of small tuples causing execessive GCs.

3 months agoGH-139436: Remove references to downloadable PDF documentation (#140416)
Adam Turner [Tue, 21 Oct 2025 12:37:06 +0000 (13:37 +0100)] 
GH-139436: Remove references to downloadable PDF documentation (#140416)

3 months agogh-140406: Fix memory leak upon `__hash__` returning a non-integer (GH-140411)
Peter Bierma [Tue, 21 Oct 2025 12:10:01 +0000 (08:10 -0400)] 
gh-140406: Fix memory leak upon `__hash__` returning a non-integer (GH-140411)

3 months agogh-83714: Fix os.statx() tests on tmpfs: st_birthtime can be None (#140407)
Victor Stinner [Tue, 21 Oct 2025 10:24:49 +0000 (12:24 +0200)] 
gh-83714: Fix os.statx() tests on tmpfs: st_birthtime can be None (#140407)

3 months agogh-133951: Add venv changes to documentation and whatsnew (GH-139704)
Cycloctane [Tue, 21 Oct 2025 08:52:57 +0000 (16:52 +0800)] 
gh-133951: Add venv changes to documentation and whatsnew (GH-139704)

3 months agogh-140398: fix memory leaks in `readline` module when `PySys_Audit` fails (#140400)
Shamil [Tue, 21 Oct 2025 07:54:34 +0000 (10:54 +0300)] 
gh-140398: fix memory leaks in `readline` module when `PySys_Audit` fails (#140400)

3 months agogh-139707: Better `ModuleNotFoundError` message for missing stdlib modules (GH-140219)
Stan Ulbrych [Tue, 21 Oct 2025 07:12:04 +0000 (08:12 +0100)] 
gh-139707: Better `ModuleNotFoundError` message for missing stdlib modules (GH-140219)

3 months agogh-140358: Bring back elapsed time and unreachable count to gc debug output (#140359)
Pål Grønås Drange [Mon, 20 Oct 2025 23:54:44 +0000 (01:54 +0200)] 
gh-140358: Bring back elapsed time and unreachable count to gc debug output (#140359)

3 months agogh-133601: Remove deprecated `typing.no_type_check_decorator` (#133602)
sobolevn [Mon, 20 Oct 2025 21:10:44 +0000 (00:10 +0300)] 
gh-133601: Remove deprecated `typing.no_type_check_decorator` (#133602)

3 months ago[Docs] Add missing note about Required/NotRequired/ReadOnly in get_type_hints() ...
Sam Bull [Mon, 20 Oct 2025 20:09:33 +0000 (21:09 +0100)] 
[Docs] Add missing note about Required/NotRequired/ReadOnly in get_type_hints() (#139565)

Co-authored-by: Jelle Zijlstra <jelle.zijlstra@gmail.com>
3 months agogh-138891: fix star-unpack in get_annotations (#138951)
Christoph Walcher [Mon, 20 Oct 2025 19:55:08 +0000 (21:55 +0200)] 
gh-138891: fix star-unpack in get_annotations (#138951)

3 months agogh-133656: Remove unused import and private global in `Lib/zipimport.py` (GH-140325)
yihong [Mon, 20 Oct 2025 19:43:10 +0000 (03:43 +0800)] 
gh-133656: Remove unused import and private global in `Lib/zipimport.py` (GH-140325)

3 months agogh-63161: Fix tokenize.detect_encoding() (GH-139446)
Serhiy Storchaka [Mon, 20 Oct 2025 17:08:47 +0000 (20:08 +0300)] 
gh-63161: Fix tokenize.detect_encoding() (GH-139446)

* Support non-UTF-8 shebang and comments if non-UTF-8 encoding is specified.
* Detect decoding error for non-UTF-8 encoding.
* Detect null bytes in source code.

3 months agogh-83714: Set os.statx() members to None if missing from stx_mask (#140216)
Victor Stinner [Mon, 20 Oct 2025 15:59:12 +0000 (17:59 +0200)] 
gh-83714: Set os.statx() members to None if missing from stx_mask (#140216)

3 months agoDocs: replace an esoteric Von Neumann mention (#137598)
Ned Batchelder [Mon, 20 Oct 2025 14:01:20 +0000 (10:01 -0400)] 
Docs: replace an esoteric Von Neumann mention (#137598)

* Docs: replace an esoteric Von Neumann mention

* oops, don't need to edit topics.py

3 months agogh-140263: Fix data race in test_lock_two_threads (gh-140264)
Sam Gross [Mon, 20 Oct 2025 13:58:05 +0000 (09:58 -0400)] 
gh-140263: Fix data race in test_lock_two_threads (gh-140264)

Clang-20 detects a data race between the unlock and the non-atomic
read of the lock state. Use a relaxed load for the assertion to avoid
the race.

3 months agogh-140166: Use `application/texinfo` as sole MIME type for `.texi` and `.texinfo...
Charlie Lin [Mon, 20 Oct 2025 13:14:23 +0000 (09:14 -0400)] 
gh-140166: Use `application/texinfo` as sole MIME type for `.texi` and `.texinfo` files (#140165)

Co-authored-by: Stan Ulbrych <89152624+StanFromIreland@users.noreply.github.com>
Co-authored-by: blurb-it[bot] <43283697+blurb-it[bot]@users.noreply.github.com>
3 months agogh-76007: Deprecate `__version__` attribute in `imaplib` (#140299)
Hugo van Kemenade [Mon, 20 Oct 2025 12:20:44 +0000 (15:20 +0300)] 
gh-76007: Deprecate `__version__` attribute in `imaplib` (#140299)

Co-authored-by: Victor Stinner <vstinner@python.org>
3 months agogh-66646: Explain __base__ attribute in the docs (GH-102554)
Furkan Onder [Mon, 20 Oct 2025 12:15:30 +0000 (21:15 +0900)] 
gh-66646: Explain __base__ attribute in the docs (GH-102554)

Co-authored-by: Éric <merwok@netwok.org>
3 months agogh-139951: Test on GC collection disabled if threshold is zero (GH-140304)
Mikhail Efimov [Mon, 20 Oct 2025 10:45:07 +0000 (13:45 +0300)] 
gh-139951: Test on GC collection disabled if threshold is zero (GH-140304)

3 months agogh-140301: Fix memory leak in subinterpreter `PyConfig` cleanup (#140303)
Shamil [Mon, 20 Oct 2025 09:29:23 +0000 (12:29 +0300)] 
gh-140301: Fix memory leak in subinterpreter `PyConfig` cleanup (#140303)

Co-authored-by: Kumar Aditya <kumaraditya@python.org>
3 months agofix typo in comments PyOS_CallInputHook -> PyOS_InputHook (#140237)
mdehoon [Mon, 20 Oct 2025 08:55:57 +0000 (17:55 +0900)] 
fix typo in comments PyOS_CallInputHook -> PyOS_InputHook (#140237)

3 months agoRemove typo in ``functools.lru_cache`` docs (#140278)
Brandon Hubacher [Mon, 20 Oct 2025 08:55:01 +0000 (03:55 -0500)] 
Remove typo in ``functools.lru_cache`` docs (#140278)

3 months agoFix typo in PyIter_Send docs (#140336)
Peter Holloway [Mon, 20 Oct 2025 08:53:57 +0000 (09:53 +0100)] 
Fix typo in PyIter_Send docs (#140336)

3 months agogh-101100: Fix sphinx warnings in `library/resource.rst` (#140023)
Weilin Du [Mon, 20 Oct 2025 07:15:40 +0000 (15:15 +0800)] 
gh-101100: Fix sphinx warnings in `library/resource.rst` (#140023)

3 months ago`zlib.rst`: Link to constants and deduplicate text (GH-140115)
Stan Ulbrych [Mon, 20 Oct 2025 04:22:39 +0000 (05:22 +0100)] 
`zlib.rst`: Link to constants and deduplicate text (GH-140115)

* Link to compression setting constants from compression functions
* De-duplicate descriptions of the constants

Co-authored-by: Victor Stinner <vstinner@python.org>
3 months agodocs: be clearer that glob results are unordered (#140184)
Ned Batchelder [Sun, 19 Oct 2025 20:16:35 +0000 (16:16 -0400)] 
docs: be clearer that glob results are unordered (#140184)

* docs: be clearer that glob results are unordered

* trim down the opening paragraph

3 months agogh-140306: Fix memory leaks in cross-interpreter data handling (GH-140307)
Shamil [Sun, 19 Oct 2025 19:24:28 +0000 (22:24 +0300)] 
gh-140306: Fix memory leaks in cross-interpreter data handling (GH-140307)

3 months agogh-101525: [BOLT] Add GCC's LTO-generated function clones, with computed gotos, to...
stratakis [Sun, 19 Oct 2025 14:23:49 +0000 (16:23 +0200)] 
gh-101525: [BOLT] Add GCC's LTO-generated function clones, with computed gotos, to BOLT skip list (gh-139840)

3 months ago`Lib/idlelib/idle_test/__init__.py`: remove commented out duplicate code (#140259)
Stan Ulbrych [Sun, 19 Oct 2025 04:16:13 +0000 (05:16 +0100)] 
`Lib/idlelib/idle_test/__init__.py`: remove commented out duplicate code (#140259)

3 months agogh-138997: Remove false justify `fill` option from Tkinter docs (#139023)
Marat Khagazheev [Sun, 19 Oct 2025 03:45:52 +0000 (06:45 +0300)] 
gh-138997: Remove false justify `fill` option from Tkinter docs (#139023)

Co-authored-by: marat <khagazheev@artlebedev.ru>
3 months agogh-139269: Fix unaligned memory access in JIT code patching functions (GH-139271)
Shamil [Sat, 18 Oct 2025 23:20:04 +0000 (02:20 +0300)] 
gh-139269: Fix unaligned memory access in JIT code patching functions (GH-139271)

* Use memcpy for patching values instead of direct assignment

Co-authored-by: Bénédikt Tran <10796600+picnixz@users.noreply.github.com>