Commit graph

125534 commits

Author SHA1 Message Date
Stan Ulbrych
ea07223716
[3.13] Fix typos and grammar errors across documentation (GH-144709) (#144804)
(cherry picked from commit 3718f4be60)

Co-authored-by: Ronald Eddy Jr <ronald_eddy@yahoo.com>
2026-02-17 12:56:29 +00:00
Miss Islington (bot)
6579e03813
[3.13] gh-143637: Fix test_socket.test_sendmsg_reentrant_ancillary_mutation() on Solaris (GH-144890) (#144902)
gh-143637: Fix test_socket.test_sendmsg_reentrant_ancillary_mutation() on Solaris (GH-144890)

Use socket.SCM_RIGHTS operation.
(cherry picked from commit 63531a3867)

Co-authored-by: Victor Stinner <vstinner@python.org>
2026-02-17 10:12:25 +00:00
Miss Islington (bot)
c3b5900c65
[3.13] gh-144551: Update macOS installer to use OpenSSL 3.0.19 (GH-144897) (#144898)
(cherry picked from commit 8f7e9c239f)

Co-authored-by: Ned Deily <nad@python.org>
2026-02-17 05:57:46 +00:00
Peter Bierma
9314ec23a6
[3.13] gh-144601: Avoid sharing exception objects raised in a PyInit function across multiple interpreters (GH-144602) (GH-144880)
(cherry picked from commit fd6b639a49)
2026-02-16 16:05:55 +00:00
Miss Islington (bot)
e701a5cb18
[3.13] gh-144601: Use _testmultiphase instead of _testsinglephase in test_importlib (GH-144769) (GH-144877)
[3.14] gh-144601: Use `_testmultiphase` instead of `_testsinglephase` in `test_importlib` (GH-144769)
(cherry picked from commit d148662326)

Co-authored-by: Peter Bierma <zintensitydev@gmail.com>
2026-02-16 10:11:17 -05:00
Miss Islington (bot)
ba0bab40f7
[3.13] gh-80667: Fix lookup for Tangut ideographs in unicodedata (GH-144789) (GH-144871) (GH-144875)
(cherry picked from commit 8b7b5a9946)
(cherry picked from commit bcabbd02f6)

Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
Co-authored-by: Pierre Le Marre <dev@wismill.eu>
2026-02-16 15:02:01 +00:00
Zachary Ware
48f9ecad92
[3.13] gh-144551: Update Android builds to use OpenSSL 3.0.19 (GH-144868)
(cherry picked from commit 87c7f193b8)
2026-02-15 23:27:39 -06:00
Miss Islington (bot)
37f818caef
[3.13] gh-144833: Fix use-after-free in SSL module when SSL_new() fails (GH-144843) (#144859)
gh-144833: Fix use-after-free in SSL module when SSL_new() fails (GH-144843)

In newPySSLSocket(), when SSL_new() returns NULL, Py_DECREF(self)
was called before _setSSLError(get_state_ctx(self), ...), causing
a use-after-free. Additionally, get_state_ctx() was called with
self (PySSLSocket*) instead of sslctx (PySSLContext*), which is
a type confusion bug.

Fix by calling _setSSLError() before Py_DECREF() and using
sslctx instead of self for get_state_ctx().
(cherry picked from commit c91638ca06)

Co-authored-by: Ramin Farajpour Cami <ramin.blackhat@gmail.com>
2026-02-16 03:09:58 +00:00
Miss Islington (bot)
e1dbe2263a
[3.13] gh-101100: Resolve reference warnings in reference/ (GH-138418) (#138681)
Co-authored-by: Adam Turner <9087854+AA-Turner@users.noreply.github.com>
Co-authored-by: Stan Ulbrych <stan@ulbrych.org>
2026-02-15 03:06:50 +00:00
Pablo Galindo Salgado
0151abcd9f
[3.13] gh-144766: Fix a crash in fork child process when perf support is enabled. (GH-144795) (#144818)
(cherry picked from commit 5922149a50)

Co-authored-by: Yilei <hi@mangoumbrella.com>
2026-02-14 17:52:42 +00:00
Zachary Ware
48dd852025
[3.13] gh-144551: Update CI to use latest OpenSSL versions (GH-144800)
(cherry picked from commit b933ef9261)
2026-02-13 15:41:42 -06:00
Miss Islington (bot)
795f436fc5
[3.13] gh-144787: [tests] Allow TLS v1.2 to be minimum version (GH-144790) (#144792)
gh-144787: [tests] Allow TLS v1.2 to be minimum version (GH-144790)

Allow TLS v1.2 to be minimum version

Updates test_min_max_version to allow TLS v1.2 to be minimum version if
TLS 1.0 and 1.1 are disabled in OpenSSL.
(cherry picked from commit d625f7da33)

Co-authored-by: Colin McAllister <colinmca242@gmail.com>
2026-02-13 12:28:14 -08:00
Zachary Ware
160fe2acd8
[3.13] gh-144551: Update Windows builds to use OpenSSL 3.0.19 (GH-144798)
(cherry picked from commit 928602c0ac)
2026-02-13 19:37:02 +00:00
Miss Islington (bot)
309bacdb4a
[3.13] gh-143637: Fix re-entrant mutation of ancillary data in socket.sendmsg() (GH-143892) (#144785)
gh-143637: Fix re-entrant mutation of ancillary data in socket.sendmsg() (GH-143892)
(cherry picked from commit 82b92e3cd1)

Co-authored-by: Priyanshu Singh <priyanshu2282@gmail.com>
Co-authored-by: blurb-it[bot] <43283697+blurb-it[bot]@users.noreply.github.com>
Co-authored-by: Victor Stinner <vstinner@python.org>
Co-authored-by: Bénédikt Tran <10796600+picnixz@users.noreply.github.com>
2026-02-13 15:58:59 +00:00
Miss Islington (bot)
99a4e55f79
[3.13] gh-144706: Warn against using synchronization primitives within signal handlers (GH-144736) (GH-144768)
gh-144706: Warn against using synchronization primitives within signal handlers (GH-144736)
(cherry picked from commit 945bf8ce1b)

Co-authored-by: Robsdedude <dev@rouvenbauer.de>
2026-02-12 23:21:26 +00:00
Serhiy Storchaka
2f354107f3
[3.13] gh-80667: Fix case-sensitivity of some Unicode literal escapes (GH-107281) (GH-144754)
Lookup for CJK ideograms and Hangul syllables is now case-insensitive,
as is the case for other character names.
(cherry picked from commit e66f4a5a9c)

Co-authored-by: James <snoopjedi@gmail.com>
2026-02-12 17:18:48 +00:00
Miss Islington (bot)
99cc3d1842
[3.13] gh-57095: Add note about input splitting in datetime.*.strptime (GH-131049) (GH-144734)
(cherry picked from commit 2e3e76e5cd)

Co-authored-by: Petr Viktorin <encukou@gmail.com>
2026-02-12 11:44:42 +01:00
Serhiy Storchaka
009583fc6f
[3.13] gh-84424: Use numeric_changed for UCD.numeric (GH-19457) (GH-144732)
This was causing ucd_3_2_0.numeric() to pick up only decimal
changes between Unicode 3.2.0 and the current version.
(cherry picked from commit 3e0322ff16)

Co-authored-by: William Meehan <wmeehan@fb.com>
2026-02-12 08:35:09 +00:00
Stan Ulbrych
9a57c932ec
[3.13] Itertools recipes: Replace the tabulate() example with running_mean() (gh-144483) (gh-144722) 2026-02-12 00:24:00 -06:00
Lysandros Nikolaou
05c9474ed9
[3.13] gh-142518: Define lock-free and per-object lock (GH-144548) (#144707)
(cherry picked from commit 12dbae4c02)
2026-02-11 18:08:49 +01:00
Miss Islington (bot)
a5b1952d24
[3.13] gh-106318: Improve str.rstrip() method doc (GH-143893) (#144698)
gh-106318: Improve str.rstrip() method doc (GH-143893)
(cherry picked from commit 936d60dbe1)

Co-authored-by: Adorilson Bezerra <adorilson@gmail.com>
Co-authored-by: Victor Stinner <vstinner@python.org>
Co-authored-by: Stan Ulbrych <89152624+StanFromIreland@users.noreply.github.com>
2026-02-11 08:48:28 +00:00
Gregory P. Smith
c117ef1a1c
[3.13] gh-143650: Fix importlib race condition on import failure (GH-143651) (#144697)
gh-143650: Fix importlib race condition on import failure (GH-143651)

Fix a race condition where a thread could receive a partially-initialized
module when another thread's import fails. The race occurs when:

1. Thread 1 starts importing, adds module to sys.modules
2. Thread 2 sees the module in sys.modules via the fast path
3. Thread 1's import fails, removes module from sys.modules
4. Thread 2 returns a stale module reference not in sys.modules

The fix adds verification after the "skip lock" optimization in both Python
and C code paths to check if the module is still in sys.modules. If the
module was removed (due to import failure), we retry the import so the
caller receives the actual exception from the import failure rather than
a stale module reference.

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>

cherry picked from ac8b5b6890
2026-02-11 06:37:25 +00:00
Miss Islington (bot)
36aa0815ca
[3.13] gh-138744: Skip test_dtrace on Windows (GH-144657) (#144668)
[3.14] gh-138744: Skip test_dtrace on Windows (GH-144657)
(cherry picked from commit 8b4210c30e)

Co-authored-by: Victor Stinner <vstinner@python.org>
Co-authored-by: Ken Jin <kenjin@python.org>
2026-02-10 14:54:27 +00:00
Miss Islington (bot)
c49835a51c
[3.13] Clarify the docs for args in asyncio callbacks (GH-143873) (#144664)
Clarify the docs for `args` in asyncio callbacks (GH-143873)
(cherry picked from commit 40a82abe93)

Co-authored-by: Aarni Koskela <akx@iki.fi>
Co-authored-by: Kumar Aditya <kumaraditya@python.org>
2026-02-10 13:16:12 +00:00
Miss Islington (bot)
d177460b43
[3.13] gh-143543: Fix re-entrant use-after-free in itertools.groupby (GH-143738) (GH-144627)
(cherry picked from commit a91b5c3fb5)

Co-authored-by: VanshAgarwal24036 <148854295+VanshAgarwal24036@users.noreply.github.com>
Co-authored-by: Sergey B Kirpichev <skirpichev@gmail.com>
Co-authored-by: Petr Viktorin <encukou@gmail.com>
2026-02-10 14:01:23 +01:00
Miss Islington (bot)
7fbdec4180
[3.13] gh-144363: Update bundled libexpat to 2.7.4 (GH-144365) (GH-144500)
(cherry picked from commit d5cb9f6a9b)

Co-authored-by: Stan Ulbrych <89152624+StanFromIreland@users.noreply.github.com>
Co-authored-by: Gregory P. Smith <greg@krypto.org>
2026-02-10 13:59:12 +01:00
Petr Viktorin
bad4bc4603
[3.13] gh-131261: generate_sbom.py: Exclude the refresh script from SBOM (GH-131359) (GH-144625)
- generate_sbom.py: Exclude the refresh script from SBOM
- Modules/expat/refresh.sh: Expand the list of manual steps

(cherry picked from commit 51d309988b)
2026-02-10 10:49:00 +01:00
Miss Islington (bot)
de105e78c7
[3.13] Disable pip version check when upgrading certifi (GH-144632) (#144640)
(cherry picked from commit 80ba4e10f5)

Co-authored-by: Hugo van Kemenade <1324225+hugovk@users.noreply.github.com>
2026-02-09 22:22:12 -05:00
Miss Islington (bot)
c304b32b1f
[3.13] gh-144492: Fix process_changed_files outputs for reusable-{macos, wasi}.yml (GH-144518) (#144634)
gh-144492: Fix `process_changed_files` outputs for `reusable-{macos, wasi}.yml` (GH-144518)

Fix `process_changed_files` double-processing reusable-{macos, wasi] ending up with incorrect outputs
(cherry picked from commit fd190d1fa1)

Co-authored-by: Stan Ulbrych <89152624+StanFromIreland@users.noreply.github.com>
2026-02-09 18:16:33 +00:00
Miss Islington (bot)
6884288570
[3.13] gh-106318: Add examples for str.partition() method (GH-142823) (#144612)
gh-106318: Add examples for str.partition() method (GH-142823)
(cherry picked from commit 432ddd99e2)

Co-authored-by: Adorilson Bezerra <adorilson@gmail.com>
2026-02-08 22:16:49 +00:00
Miss Islington (bot)
43b9344114
[3.13] gh-106318: Add example for str.isalnum() (GH-137550) (#144610)
gh-106318: Add example for str.isalnum() (GH-137550)
(cherry picked from commit 3dd7a3c65a)

Co-authored-by: Adorilson Bezerra <adorilson@gmail.com>
2026-02-08 22:15:45 +00:00
Miss Islington (bot)
57aaee56cb
[3.13] For enum.bin, update versionadded directive from 3.10 to 3.11 (GH-144574) (#144589)
For `enum.bin`, update versionadded directive from 3.10 to 3.11 (GH-144574)
(cherry picked from commit d73634935c)

Co-authored-by: Guo Ci <zguoci@gmail.com>
2026-02-08 07:43:22 +00:00
Miss Islington (bot)
e6e0171357
[3.13] gh-143700: document secrets.DEFAULT_ENTROPY as an opaque value (GH-144568) (#144580)
gh-143700: document `secrets.DEFAULT_ENTROPY` as an opaque value (GH-144568)
(cherry picked from commit 934997218e)

Co-authored-by: Bénédikt Tran <10796600+picnixz@users.noreply.github.com>
2026-02-07 22:44:03 +00:00
Miss Islington (bot)
51ff5f376b
[3.13] gh-142044: Add note to prefer asyncio.timeout[_at] over asyncio.Timeout (GH-144449) (#144566)
gh-142044: Add note to prefer `asyncio.timeout[_at]` over `asyncio.Timeout` (GH-144449)
(cherry picked from commit 0e7c06a858)

Co-authored-by: kovan <xaum.io@gmail.com>
2026-02-07 13:31:35 +01:00
Miss Islington (bot)
ac9bc7c8fc
[3.13] gh-144538: Upgrade bundled pip to 26.0.1 (gh-144556) (#144561)
gh-144538: Upgrade bundled pip to 26.0.1 (gh-144556)

Upgrade bundled pip to 26.0.1
(cherry picked from commit f4364a51c1)

Co-authored-by: Damian Shaw <damian.peter.shaw@gmail.com>
2026-02-07 14:22:54 +02:00
Miss Islington (bot)
b6c6cd6321
[3.13] gh-144330: Initialize classmethod and staticmethod in new (GH-144498) (#144537)
[3.14] gh-144330: Initialize classmethod and staticmethod in new (GH-144498)

gh-144330: Initialize classmethod and staticmethod in new

Initialize cm_callable and sm_callable to None in classmethod and
staticmethod constructor.
(cherry picked from commit 160810de89)

Co-authored-by: Victor Stinner <vstinner@python.org>
Co-authored-by: Aniket Singh Yadav <singhyadavaniket43@gmail.com>
Co-authored-by: Stan Ulbrych <89152624+StanFromIreland@users.noreply.github.com>
2026-02-06 09:48:55 +00:00
Miss Islington (bot)
7d04956d4a
[3.13] gh-144484: Warn users not to use wsgiref in production (#144512)
gh-144484: Warn users not to use wsgiref in production
(cherry picked from commit 7e777c587f)

Co-authored-by: Seth Michael Larson <seth@python.org>
2026-02-05 18:22:07 +02:00
Miss Islington (bot)
d5d4d2c36f
[3.13] gh-144148: Update the urllib.parse documentation (GH-144497) (GH-144507) (GH-144509)
(cherry picked from commit 2fb9cde118)

Document urlsplit() as the main parsing function and urlparse() as
an obsolete variant.
(cherry picked from commit 67ddba9aa9)

Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
2026-02-05 15:47:52 +00:00
Miss Islington (bot)
65acd01693
[3.13] gh-106318: Add examples for str.startswith() method (GH-144369) (#144480)
gh-106318: Add examples for `str.startswith()` method (GH-144369)
(cherry picked from commit 1b6d737ee0)

Co-authored-by: Adorilson Bezerra <adorilson@gmail.com>
Co-authored-by: Stan Ulbrych <89152624+StanFromIreland@users.noreply.github.com>
2026-02-04 17:24:35 +00:00
Miss Islington (bot)
7f3939338a
[3.13] gh-141004: Document remaining pyport.h utility macros (GH-144279) (GH-144478)
gh-141004: Document remaining `pyport.h` utility macros (GH-144279)
(cherry picked from commit 914fbec214)

Co-authored-by: Peter Bierma <zintensitydev@gmail.com>
Co-authored-by: Bénédikt Tran <10796600+picnixz@users.noreply.github.com>
Co-authored-by: Victor Stinner <vstinner@python.org>
2026-02-04 16:49:59 +00:00
Miss Islington (bot)
e5d8b783e8
[3.13] gh-141444: Replace dead URL in urllib.robotparser example (GH-144443) (#144465)
Co-authored-by: kovan <217326+kovan@users.noreply.github.com>
Co-authored-by: Claude Opus 4.5 <noreply@anthropic.com>
2026-02-04 11:36:32 +00:00
Thomas Wouters
cc1f81bb45 Post 3.13.12 2026-02-03 22:47:48 +01:00
Thomas Wouters
1cbe481834 Python 3.13.12 2026-02-03 18:53:27 +01:00
Miss Islington (bot)
ad5bd4ad47
[3.13] gh-127313: Use getLogger() without argument to get root logger in logging cookbook (GH-143683) (GH-144432)
gh-127313: Use getLogger() without argument to get root logger in logging cookbook (GH-143683)

Use getLogger() to get root logger in logging cookbook
(cherry picked from commit 53fecbe6e1)

Co-authored-by: AN Long <aisk@users.noreply.github.com>
2026-02-03 14:55:25 +00:00
Miss Islington (bot)
5e888993e4
[3.13] gh-74453: Add stronger security warning to os.path.commonprefix
gh-74453: Add stronger security warning to os.path.commonprefix (GH-144401)
(cherry picked from commit 4e15b8d95d)

Co-authored-by: Seth Michael Larson <seth@python.org>
2026-02-03 14:16:28 +00:00
Miss Islington (bot)
44820648e6
[3.13] gh-106318: Add examples for str.rindex() method (GH-143887) (#144422)
gh-106318: Add examples for str.rindex() method (GH-143887)
(cherry picked from commit 45d00a0791)

Co-authored-by: Adorilson Bezerra <adorilson@gmail.com>
Co-authored-by: Victor Stinner <vstinner@python.org>
2026-02-03 14:36:32 +01:00
Miss Islington (bot)
9d76689343
[3.13] gh-75572: Speed up test_xpickle (GH-144393) (GH-144404)
Run a long living subprocess which handles multiple requests instead of
running a new subprocess for each request.
(cherry picked from commit 29acc08c8d)

Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
2026-02-03 10:40:48 +00:00
Miss Islington (bot)
ebc047f717
[3.13] gh-144415: Android testbed fixes (GH-142912) (#144417)
Modifies handling of `.gz` files in Android app payloads, and ensures that
when the Android testbed streams logs, stream flushes aren't treated as
newlines. This improves the output of test suites that use "one dot per test"
progress indicators.
(cherry picked from commit cb1dc91dcb)

Co-authored-by: Malcolm Smith <smith@chaquo.com>
2026-02-03 09:28:43 +00:00
Guo Ci
b4a84bc555
[3.13] gh-140806: add docs for enum.bin function (#140807) (#143740)
(cherry picked from commit 7f50a5febd)

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>
2026-02-02 22:57:53 +01:00
Miss Islington (bot)
b74e3a4c05
[3.13] gh-142555: Fix null pointer dereference in array.__setitem__ via re-entrant __index__ (GH-142713) (#144397)
gh-142555: Fix null pointer dereference in array.__setitem__ via re-entrant __index__ (GH-142713)
(cherry picked from commit 39f16a93ef)

Co-authored-by: AN Long <aisk@users.noreply.github.com>
2026-02-02 21:06:59 +01:00