]> git.ipfire.org Git - thirdparty/Python/cpython.git/log
thirdparty/Python/cpython.git
5 months ago[3.13] gh-135839: Fix `module_traverse` and `module_clear` in `_interpchannelsmodule...
sobolevn [Wed, 25 Jun 2025 09:25:27 +0000 (12:25 +0300)] 
[3.13] gh-135839: Fix `module_traverse` and `module_clear` in `_interpchannelsmodule` (GH-135840) (#135919)

(cherry picked from commit dd59c786cfb1018eb5abe877bfa7265ea9a3c2b9)

5 months ago[3.13] gh-135755: Docs: C API: Document missing `PyFunction_GET*` macros (GH-135762...
Miss Islington (bot) [Wed, 25 Jun 2025 08:51:58 +0000 (10:51 +0200)] 
[3.13] gh-135755: Docs: C API: Document missing `PyFunction_GET*` macros (GH-135762) (GH-135917)

(cherry picked from commit ca87a47b3d92aabaefbbe79c0493d66602184b41)

Co-authored-by: Peter Bierma <zintensitydev@gmail.com>
Co-authored-by: Brian Schubert <brianm.schubert@gmail.com>
Co-authored-by: Petr Viktorin <encukou@gmail.com>
5 months ago[3.13] gh-135855: Raise TypeError When Passing Non-dict Object to `_interpreters...
Brian Schubert [Tue, 24 Jun 2025 22:23:26 +0000 (18:23 -0400)] 
[3.13] gh-135855: Raise TypeError When Passing Non-dict Object to `_interpreters.set___main___attrs` (gh-135903)

(cherry picked from commit 4e6f0d116e, AKA gh-135856)

5 months ago[3.13] gh-135878: Fix crash in `types.SimpleNamespace.__repr__` (GH-135889) (#135895)
Miss Islington (bot) [Tue, 24 Jun 2025 16:59:29 +0000 (18:59 +0200)] 
[3.13] gh-135878: Fix crash in `types.SimpleNamespace.__repr__` (GH-135889) (#135895)

gh-135878: Fix crash in `types.SimpleNamespace.__repr__` (GH-135889)
(cherry picked from commit b3ab94acd308591bbdf264f1722fedc7ee25d6fa)

Co-authored-by: sobolevn <mail@sobolevn.me>
Co-authored-by: Peter Bierma <zintensitydev@gmail.com>
5 months ago[3.13] gh-135487: fix `reprlib.Repr.repr_int` when given very large integers (GH...
Miss Islington (bot) [Tue, 24 Jun 2025 12:00:14 +0000 (14:00 +0200)] 
[3.13] gh-135487: fix `reprlib.Repr.repr_int` when given very large integers (GH-135506) (#135886)

gh-135487: fix `reprlib.Repr.repr_int` when given very large integers (GH-135506)
(cherry picked from commit e5f03b94b6d4decbf433d385f692c1b8d9b7e88d)

Co-authored-by: Bénédikt Tran <10796600+picnixz@users.noreply.github.com>
5 months ago[3.13] gh-135494: Fix python -m test --pgo -x test_re (#135713) (#135881)
Victor Stinner [Tue, 24 Jun 2025 10:49:31 +0000 (12:49 +0200)] 
[3.13] gh-135494: Fix python -m test --pgo -x test_re (#135713) (#135881)

gh-135494: Fix python -m test --pgo -x test_re (#135713)

Fix regrtest to support excluding tests from --pgo tests.

(cherry picked from commit 15c6d63fe6fc62c6d78d2fad81965a8e6f7b7b98)

5 months ago[3.13] Bump mypy to 1.16.1 (GH-135720) (#135849)
Hugo van Kemenade [Tue, 24 Jun 2025 07:20:55 +0000 (08:20 +0100)] 
[3.13] Bump mypy to 1.16.1 (GH-135720) (#135849)

Co-authored-by: sobolevn <mail@sobolevn.me>
5 months ago[3.13] Docs: Use `arguments` to replace `args` in `argparse.rst` (GH-135510) (GH...
Miss Islington (bot) [Mon, 23 Jun 2025 22:59:17 +0000 (00:59 +0200)] 
[3.13] Docs: Use `arguments` to replace `args` in `argparse.rst` (GH-135510) (GH-135867)

Docs: Use `arguments` to replace `args` in `argparse.rst` (GH-135510)
(cherry picked from commit caad163b691b2343d823541cfbf741f481ee9f3e)

Co-authored-by: Yongzi Li <204532581+Yzi-Li@users.noreply.github.com>
5 months ago[3.13] gh-135698: Fix Cross-interpreter Queue.full() With Negative/Default max_size...
Eric Snow [Mon, 23 Jun 2025 19:38:41 +0000 (13:38 -0600)] 
[3.13] gh-135698: Fix Cross-interpreter Queue.full() With Negative/Default max_size (gh-135778)

We weren't handling non-positive maxsize values (including the default) properly
in Queue.full().  This change fixes that and adjusts an associated assert.

(cherry picked from commit c5ea8e8, AKA gh-135724)

5 months ago[3.13] gh-134986: Catch PermissionError when trying to call perf in tests (GH-134987...
Miss Islington (bot) [Mon, 23 Jun 2025 10:51:51 +0000 (12:51 +0200)] 
[3.13] gh-134986: Catch PermissionError when trying to call perf in tests (GH-134987) (#135842)

gh-134986: Catch PermissionError when trying to call perf in tests (GH-134987)

Using Ubuntu 24.04 on the Windows Subsystem for Linux, perf will raise a
`PermissionError` instead of `FileNotFoundError`. This commit modifies
the tests to catch that.
(cherry picked from commit 6ab842fce50a6125797bcddfc4a4b2622aa6c6a9)

Co-authored-by: Emma Smith <emma@emmatyping.dev>
5 months ago[3.13] patchcheck: use URL paths to identify upstream remote (GH-135806) (#135809)
Miss Islington (bot) [Mon, 23 Jun 2025 09:57:03 +0000 (11:57 +0200)] 
[3.13] patchcheck: use URL paths to identify upstream remote (GH-135806) (#135809)

Co-authored-by: Kattni <kattni@kattni.com>
5 months ago[3.13] gh-135815: skip `netrc` security checks if `os.getuid` is missing (GH-135816...
Miss Islington (bot) [Sun, 22 Jun 2025 20:12:20 +0000 (22:12 +0200)] 
[3.13] gh-135815: skip `netrc` security checks if `os.getuid` is missing (GH-135816) (#135826)

gh-135815: skip `netrc` security checks if `os.getuid` is missing (GH-135816)
(cherry picked from commit b57b619e34cdfc87b47943c988b0b4d69f8f1fe4)

Co-authored-by: Bénédikt Tran <10796600+picnixz@users.noreply.github.com>
5 months ago[3.13] gh-135756: Fix nonexistent parameter in tkinter docs (GH-135770) (#135777)
Miss Islington (bot) [Fri, 20 Jun 2025 23:35:39 +0000 (01:35 +0200)] 
[3.13] gh-135756: Fix nonexistent parameter in tkinter docs (GH-135770) (#135777)

gh-135756: Fix nonexistent parameter in tkinter docs (GH-135770)

Remove nonexistent color parameter from tkinter.commondialog.Dialog.show() method documentation.
(cherry picked from commit 4ddf505d9982dc8afead8f52f5754eea5ebde623)

Co-authored-by: Marcell Perger <102254594+MarcellPerger1@users.noreply.github.com>
5 months ago[3.13] Docs: Document `PyExceptionClass` functions in the C API (GH-135697) (GH-135758)
Miss Islington (bot) [Fri, 20 Jun 2025 14:03:10 +0000 (16:03 +0200)] 
[3.13] Docs: Document `PyExceptionClass` functions in the C API (GH-135697) (GH-135758)

Docs: Document `PyExceptionClass` functions in the C API (GH-135697)

* Docs: Document `PyExceptionClass_Name`

`PyExceptionClass_Name` is an undocumented function in the limited API.

* Document `PyExceptionClass_Check`
(cherry picked from commit 59963e866a1bb8128a50cd53d1b13eeab03df06e)

Co-authored-by: Yuki Kobayashi <drsuaimqjgar@gmail.com>
5 months ago[3.13] gh-135273: Unify `ZoneInfo.from_file` signatures (GH-135274) (#135715)
Miss Islington (bot) [Thu, 19 Jun 2025 15:10:54 +0000 (17:10 +0200)] 
[3.13] gh-135273: Unify `ZoneInfo.from_file` signatures (GH-135274) (#135715)

gh-135273: Unify `ZoneInfo.from_file` signatures (GH-135274)

Align `ZoneInfo.from_file` pure-Python signature with Argument Clinic signature.
(cherry picked from commit 7cc89496922b7edb033e2ed47550c7c9e2ae8525)

Co-authored-by: Andrii Hrimov <andrew.hrimov@gmail.com>
5 months ago[3.13] Docs: Add missing lines between regex and text (GH-134505) (GH-135719)
Miss Islington (bot) [Thu, 19 Jun 2025 15:07:40 +0000 (17:07 +0200)] 
[3.13] Docs: Add missing lines between regex and text (GH-134505) (GH-135719)

Docs: Add missing lines between regex and text (GH-134505)
(cherry picked from commit 754190287ece5a2e66684161aadafb18f5f44868)

Co-authored-by: Rafael Fontenelle <rffontenelle@users.noreply.github.com>
5 months ago[3.13] Docs: Emphasize parameter name in `pkgutil.iter_importers` (GH-135597) (GH...
Miss Islington (bot) [Thu, 19 Jun 2025 13:04:46 +0000 (15:04 +0200)] 
[3.13] Docs: Emphasize parameter name in `pkgutil.iter_importers` (GH-135597) (GH-135711)

Docs: Emphasize parameter name in `pkgutil.iter_importers` (GH-135597)
(cherry picked from commit ff639af8eee11e7ca09999b2724bc10652a00e5d)

Co-authored-by: Rafael Fontenelle <rffontenelle@users.noreply.github.com>
5 months ago[3.13] gh-126112: Fix test_os.TimerfdTests: use 10 ms resolution (GH-135681) (#135705)
Miss Islington (bot) [Thu, 19 Jun 2025 10:04:48 +0000 (12:04 +0200)] 
[3.13] gh-126112: Fix test_os.TimerfdTests: use 10 ms resolution (GH-135681) (#135705)

gh-126112: Fix test_os.TimerfdTests: use 10 ms resolution (GH-135681)

Use 10 ms for CLOCK_RES instead of 100 ms to tolerate slow buildbots.
(cherry picked from commit 5c25c884b93eb79f640c47d6dba20f11fdf0ade4)

Co-authored-by: Victor Stinner <vstinner@python.org>
5 months ago[3.13] Document that PyType_GetModuleByDef returns a borrowed reference (GH-135666...
Miss Islington (bot) [Thu, 19 Jun 2025 07:18:00 +0000 (09:18 +0200)] 
[3.13] Document that PyType_GetModuleByDef returns a borrowed reference (GH-135666) (GH-135702)

(cherry picked from commit 140731ff671395fb7a869c2784429c14dc83fb27)

Co-authored-by: Petr Viktorin <encukou@gmail.com>
5 months agogh-134538: Add link to shutil.rmtree example in function docs (GH-135540)
Miss Islington (bot) [Wed, 18 Jun 2025 21:17:42 +0000 (23:17 +0200)] 
gh-134538: Add link to shutil.rmtree example in function docs (GH-135540)

(cherry picked from commit e9b647dd30d22cef465972d898a34c4b1bb6615d)

Co-authored-by: alexey semenyuk <alexsemenyuk88@gmail.com>
5 months ago[3.13] gh-135641: Fix flaky `test_capi.test_lock_two_threads` test case (gh-135642...
Miss Islington (bot) [Wed, 18 Jun 2025 18:47:59 +0000 (20:47 +0200)] 
[3.13] gh-135641: Fix flaky `test_capi.test_lock_two_threads` test case (gh-135642) (gh-135688)

The mutex may have the `_Py_HAS_PARKED` bit set.
(cherry picked from commit 17ac3933c3c860e08f7963cf270116a39a063be7)

Co-authored-by: Sam Gross <colesbury@gmail.com>
5 months ago[3.13] Docs: Fix markups for emphasis (GH-135598) (GH-135686)
Miss Islington (bot) [Wed, 18 Jun 2025 17:44:43 +0000 (19:44 +0200)] 
[3.13] Docs: Fix markups for emphasis (GH-135598) (GH-135686)

Docs: Fix markups for emphasis (GH-135598)

The word emphasis character `_` is not supported as sphinx markup, so changed to `*`.
(cherry picked from commit 46c60e0d0b716e8e6f0b74a0f9d0542605b1efd4)

Co-authored-by: Yuki Kobayashi <drsuaimqjgar@gmail.com>
5 months ago[3.13] gh-135335: flush stdout/stderr in forkserver after preloading modules (GH...
Miss Islington (bot) [Wed, 18 Jun 2025 12:40:21 +0000 (14:40 +0200)] 
[3.13] gh-135335: flush stdout/stderr in forkserver after preloading modules (GH-135338) (#135671)

gh-135335: flush stdout/stderr in forkserver after preloading modules (GH-135338)

If a preloaded module writes to stdout or stderr, and the stream is buffered,
child processes will inherit the buffered data after forking. Attempt to
prevent this by flushing the streams after preload.
(cherry picked from commit 9877d191f441741fc27ae5e7a6dd7ab6d4bcc6b7)

Co-authored-by: Duane Griffin <duaneg@dghda.com>
Co-authored-by: Mikhail Efimov <efimov.mikhail@gmail.com>
Co-authored-by: Victor Stinner <vstinner@python.org>
5 months ago[3.13] gh-135489: Show verbose output for failing tests during PGO profiling step...
Miss Islington (bot) [Tue, 17 Jun 2025 05:47:27 +0000 (07:47 +0200)] 
[3.13] gh-135489: Show verbose output for failing tests during PGO profiling step with `--enable-optimizations` (#135600)

Co-authored-by: PuQing <me@puqing.work>
5 months ago[3.13] Use replacements to update versions in "Using Python on macOS" (GH-130400...
Miss Islington (bot) [Mon, 16 Jun 2025 22:17:21 +0000 (00:17 +0200)] 
[3.13] Use replacements to update versions in "Using Python on macOS" (GH-130400) (#135587)

(cherry picked from commit 21bac3aecd03805ea74ca67a3a291a9eb347588f)

Co-authored-by: Hugo van Kemenade <1324225+hugovk@users.noreply.github.com>
5 months ago[3.13] gh-132617: Fix `dict.update()` mutation check (gh-134815) (gh-135582)
Sam Gross [Mon, 16 Jun 2025 17:30:52 +0000 (13:30 -0400)] 
[3.13] gh-132617: Fix `dict.update()` mutation check (gh-134815) (gh-135582)

Use `ma_used` instead of `ma_keys->dk_nentries` for modification check
so that we only check if the dictionary is modified, not if new keys are
added to a different dictionary that shared the same keys object.
(cherry picked from commit d8994b0a77cc9821772d05db00a6ab23382fa17d)

5 months ago[3.13] gh-132969: Fix error/hang when shutdown(wait=False) and task exited abnormall...
Miss Islington (bot) [Mon, 16 Jun 2025 12:08:03 +0000 (14:08 +0200)] 
[3.13] gh-132969:  Fix error/hang when shutdown(wait=False) and task exited abnormally (GH-133222) (GH-135343)

gh-132969:  Fix error/hang when shutdown(wait=False) and task exited abnormally (GH-133222)

When shutdown is called with wait=False, the executor thread keeps running
even after the ProcessPoolExecutor's state is reset. The executor then tries
to replenish the worker processes pool resulting in an error and a potential hang
when it comes across a worker that has died. Fixed the issue by having
_adjust_process_count() return without doing anything if the ProcessPoolExecutor's
state has been reset.

Added unit tests to validate two scenarios:
max_workers < num_tasks (exception)
max_workers > num_tasks (exception + hang)
(cherry picked from commit 598aa7cc98bc1b39f10ec41decddd8dd88799fe1)

Co-authored-by: Ajay Kamdar <140011370+ogbiggles@users.noreply.github.com>
5 months ago[3.13] gh-67022: Document bytes/str inconsistency in email.header.decode_header(...
Miss Islington (bot) [Sun, 15 Jun 2025 20:02:43 +0000 (22:02 +0200)] 
[3.13] gh-67022: Document bytes/str inconsistency in email.header.decode_header() and suggest email.headerregistry.HeaderRegistry as a sane alternative (GH-92900) (#135549)

gh-67022: Document bytes/str inconsistency in email.header.decode_header() and suggest email.headerregistry.HeaderRegistry as a sane alternative (GH-92900)

* gh-67022: Document bytes/str inconsistency in email.header.decode_header()

This function's possible return types have been surprising and error-prone
for the entirety of its Python 3.x history. It can return either:

1. `typing.List[typing.Tuple[bytes, typing.Optional[str]]]` of length >1
2. or `typing.List[typing.Tuple[str, None]]`, of length exactly 1

This means that any user of this function must be prepared to accept either
`bytes` or `str` for the first member of the 2-tuples it returns, which is a
very surprising behavior in Python 3.x, particularly given that the second
member of the tuple is supposed to represent the charset/encoding of the
first member.

This patch documents the behavior of this function, and adds test cases
to demonstrate it.

As discussed in bpo-22833, this cannot be changed in a backwards-compatible
way, and some users of this function depend precisely on the existing
behavior.

Add warnings about obsolescence of 'email.header.decode_header' and 'email.header.make_header' functions.

Recommend use of `email.headerregistry.HeaderRegistry` instead, as suggested
in https://github.com/python/cpython/pull/92900#discussion_r1112472177
(cherry picked from commit 60181f4ed0e48ff35dc296da6b51473bfc553d16)

Co-authored-by: Dan Lenski <dlenski@gmail.com>
5 months ago[3.13] gh-135171: Update documentation for the generator expression (GH-135351) ...
Miss Islington (bot) [Sun, 15 Jun 2025 00:38:52 +0000 (02:38 +0200)] 
[3.13] gh-135171: Update documentation for the generator expression (GH-135351) (GH-135525)

gh-135171: Update documentation for the generator expression (GH-135351)

* gh-135171: Update documentation for the generator expression

Document that the iterator for the leftmost "for" clause is created
immediately.

* Update Doc/reference/expressions.rst

---------
(cherry picked from commit 8979d3afe376c67931665070a79f6939ebcd940b)

Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
Co-authored-by: Brian Skinn <brian.skinn@gmail.com>
5 months ago[3.13] gh-135497: fix `MAXLOGNAME` detection in `configure.ac` (GH-135508) (#135517)
Miss Islington (bot) [Sat, 14 Jun 2025 16:49:13 +0000 (18:49 +0200)] 
[3.13] gh-135497: fix `MAXLOGNAME` detection in `configure.ac` (GH-135508) (#135517)

gh-135497: fix `MAXLOGNAME` detection in `configure.ac` (GH-135508)
(cherry picked from commit 2e15a50851da66eb8227ec6ea07a9cc7ed08fbf3)

Co-authored-by: Caleb Xu <calebcenter@live.com>
5 months ago[3.13] gh-135496: Fix f string exclamation mark error typo (GH-135495) (#135501)
GiGaGon [Sat, 14 Jun 2025 08:00:14 +0000 (01:00 -0700)] 
[3.13] gh-135496: Fix f string exclamation mark error typo (GH-135495) (#135501)

5 months ago[3.13] gh-125723: Fix crash with f_locals when generator frame outlive their generato...
Mikhail Efimov [Fri, 13 Jun 2025 18:08:03 +0000 (21:08 +0300)] 
[3.13] gh-125723: Fix crash with f_locals when generator frame outlive their generator (GH-135453)

Backport of 8e20e42cc63321dacc500d7670bfc225ca04e78b from GH-126956

Closes GH-125723

5 months ago[3.13] gh-133439: Fix dot commands with trailing spaces are mistaken for multi-line...
Tan Long [Fri, 13 Jun 2025 17:40:24 +0000 (01:40 +0800)] 
[3.13] gh-133439: Fix dot commands with trailing spaces are mistaken for multi-line sqlite statements in the sqlite3 command-line interface (GH-133440) (GH-133765)

(cherry picked from commit ebd4881db2e8448b238d8ca2f6fcf331826132dd)

5 months ago[3.13] gh-135462: Fix quadratic complexity in processing special input in HTMLParser...
Miss Islington (bot) [Fri, 13 Jun 2025 17:20:30 +0000 (19:20 +0200)] 
[3.13] gh-135462: Fix quadratic complexity in processing special input in HTMLParser (GH-135464) (GH-135482)

End-of-file errors are now handled according to the HTML5 specs --
comments and declarations are automatically closed, tags are ignored.
(cherry picked from commit 6eb6c5dbfb528bd07d77b60fd71fd05d81d45c41)

Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
5 months ago[3.13] doc: Remove what was essentially duplicate wording. (GH-135431) (GH-135441)
Miss Islington (bot) [Fri, 13 Jun 2025 16:53:52 +0000 (18:53 +0200)] 
[3.13] doc: Remove what was essentially duplicate wording. (GH-135431) (GH-135441)

(cherry picked from commit f273fd77d790300506c6443baa94d027b643f603)

5 months ago[3.13] gh-106318: Add example for `str.expandtabs()` (GH-134525) (#135477)
Miss Islington (bot) [Fri, 13 Jun 2025 15:50:53 +0000 (17:50 +0200)] 
[3.13] gh-106318: Add example for `str.expandtabs()` (GH-134525) (#135477)

Co-authored-by: Blaise Pabon <blaise@gmail.com>
5 months agogh-135455: Fix version and architecture detection in PC/layout script. (GH-135461)
Miss Islington (bot) [Fri, 13 Jun 2025 15:28:02 +0000 (17:28 +0200)] 
gh-135455: Fix version and architecture detection in PC/layout script. (GH-135461)

(cherry picked from commit afc5ab6cce9d7095b99c1410a6762bc4a96504dd)

Co-authored-by: Steve Dower <steve.dower@python.org>
5 months ago[3.13] gh-106318: Add example for `str.endswith()` (GH-134523) (#135460)
Miss Islington (bot) [Fri, 13 Jun 2025 12:13:59 +0000 (14:13 +0200)] 
[3.13] gh-106318: Add example for `str.endswith()` (GH-134523) (#135460)

gh-106318: Add example for `str.endswith()` (GH-134523)
(cherry picked from commit eed827ed091c6e55f11164046d287a76e30fbc0e)

Co-authored-by: Blaise Pabon <blaise@gmail.com>
Co-authored-by: Hugo van Kemenade <1324225+hugovk@users.noreply.github.com>
5 months ago[3.13] gh-106318: Add example for `str.encode()` (GH-134520) (#135458)
Miss Islington (bot) [Fri, 13 Jun 2025 11:46:14 +0000 (13:46 +0200)] 
[3.13] gh-106318: Add example for `str.encode()` (GH-134520) (#135458)

Co-authored-by: Blaise Pabon <blaise@gmail.com>
Co-authored-by: Hugo van Kemenade <1324225+hugovk@users.noreply.github.com>
5 months ago[3.13] Fix presentation of dataclasses' `unsafe_hash` default value (GH-116532) ...
Miss Islington (bot) [Thu, 12 Jun 2025 01:37:30 +0000 (03:37 +0200)] 
[3.13] Fix presentation of dataclasses' `unsafe_hash` default value (GH-116532) (#135417)

Fix presentation of dataclasses' `unsafe_hash` default value (GH-116532)

(cherry picked from commit 71f5fafdfb2e509f59cd584d45949c6496f88d41)

Co-authored-by: Victorien <65306057+Viicos@users.noreply.github.com>
Co-authored-by: Adam Turner <9087854+AA-Turner@users.noreply.github.com>
5 months agoPost 3.13.5
Thomas Wouters [Wed, 11 Jun 2025 21:32:50 +0000 (23:32 +0200)] 
Post 3.13.5

5 months agoPython 3.13.5 v3.13.5
Thomas Wouters [Wed, 11 Jun 2025 15:36:41 +0000 (17:36 +0200)] 
Python 3.13.5

5 months ago[3.13] gh-133264: Correct documentation of how Py_Main and Py_RunMain handle SystemEx...
Miss Islington (bot) [Wed, 11 Jun 2025 15:32:42 +0000 (17:32 +0200)] 
[3.13] gh-133264: Correct documentation of how Py_Main and Py_RunMain handle SystemExit (GH-135337) (#135395)

gh-133264: Correct documentation of how Py_Main and Py_RunMain handle SystemExit (GH-135337)
(cherry picked from commit b706ff003c536c5bca24dfdd3a8917bffcfa3df1)

Co-authored-by: Malcolm Smith <smith@chaquo.com>
5 months ago[3.13] GH-135171: Roll back all fixes for GH-127682 as they are not suitable for...
T. Wouters [Wed, 11 Jun 2025 14:57:35 +0000 (16:57 +0200)] 
[3.13] GH-135171: Roll back all fixes for GH-127682 as they are not suitable for 3.13 (#135390)

5 months ago[3.13] gh-132415: Update vendored setuptools in ``Lib/test/wheeldata`` (GH-132887...
Miss Islington (bot) [Wed, 11 Jun 2025 14:55:14 +0000 (16:55 +0200)] 
[3.13] gh-132415: Update vendored setuptools in ``Lib/test/wheeldata`` (GH-132887) (#135391)

(cherry picked from commit c9f3f5b4ed52d7bed6073ffa39717ece47202558)

Co-authored-by: Adam Turner <9087854+AA-Turner@users.noreply.github.com>
5 months ago[3.13] Docs: Add note to tutorial clarifying scope (GH-134534) (#134535)
Miss Islington (bot) [Wed, 11 Jun 2025 14:13:37 +0000 (16:13 +0200)] 
[3.13] Docs: Add note to tutorial clarifying scope (GH-134534) (#134535)

Co-authored-by: Kattni <kattni@kattni.com>
5 months ago[3.13] gh-135321: Always raise a correct exception for BINSTRING argument > 0x7ffffff...
Miss Islington (bot) [Wed, 11 Jun 2025 11:00:59 +0000 (13:00 +0200)] 
[3.13] gh-135321: Always raise a correct exception for BINSTRING argument > 0x7fffffff in pickle (GH-135322) (GH-135383)

(cherry picked from commit 2b8b4774d29a707330d463f226630185cbd3ceff)

Co-authored-by: Justin Applegate <70449145+Legoclones@users.noreply.github.com>
Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
5 months ago[3.13] gh-128605: Add branch protections for x86_64 in asm_trampoline.S (#128606...
stratakis [Wed, 11 Jun 2025 10:09:20 +0000 (12:09 +0200)] 
[3.13] gh-128605: Add branch protections for x86_64 in asm_trampoline.S (#128606) (#135353)

Apply Intel Control-flow Technology for x86-64 on asm_trampoline.S.

Required for mitigation against return-oriented programming (ROP)
and Call or Jump Oriented Programming (COP/JOP) attacks.

Manual application is required for the assembly files.

See also: https://sourceware.org/annobin/annobin.html/Test-cf-protection.html

5 months ago[3.13] gh-133967: Do not normalize locale name 'C.UTF-8' to 'en_US.UTF-8' (GH-135347...
Miss Islington (bot) [Wed, 11 Jun 2025 09:43:38 +0000 (11:43 +0200)] 
[3.13] gh-133967: Do not normalize locale name 'C.UTF-8' to 'en_US.UTF-8' (GH-135347) (GH-135350)

(cherry picked from commit 0f866cbfefd797b4dae25962457c5579bb90dde5)

Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
5 months ago[3.13] gh-135326: Restore support of __index__ in random.getrandbits() (#135332)
Serhiy Storchaka [Tue, 10 Jun 2025 10:41:10 +0000 (13:41 +0300)] 
[3.13] gh-135326: Restore support of __index__ in random.getrandbits() (#135332)

5 months ago[3.13] gh-133157: fix UBSan failures in `Parser/pegen.c` (GH-134048) (#135334)
Bénédikt Tran [Tue, 10 Jun 2025 09:12:41 +0000 (11:12 +0200)] 
[3.13] gh-133157: fix UBSan failures in `Parser/pegen.c` (GH-134048) (#135334)

[3.13] gh-133157: fix UBSan failures in `Parser/pegen.c` (GH-134048)
(cherry picked from commit 754e7c9b5187fcad22acf7555479603f173a4a09)

5 months ago[3.13] Heavily comment Python/perf_jit_trampoline.c to improve maintainability (GH...
Miss Islington (bot) [Mon, 9 Jun 2025 21:09:37 +0000 (23:09 +0200)] 
[3.13] Heavily comment Python/perf_jit_trampoline.c to improve maintainability (GH-134527) (#135300)

5 months ago[3.13] Use f-strings in csv docs example (GH-135245) (#135286)
Miss Islington (bot) [Mon, 9 Jun 2025 06:41:03 +0000 (08:41 +0200)] 
[3.13] Use f-strings in csv docs example (GH-135245) (#135286)

Use f-strings in csv docs example (GH-135245)
(cherry picked from commit 2677dd017a033eaaad3b8e1e0eb5664a44e7e231)

Co-authored-by: Ezio Melotti <ezio.melotti@gmail.com>
5 months ago[3.13] gh-135276: Refresh `zipfile.Path` from zipp 3.23 (GH-135277) (#135279)
Miss Islington (bot) [Sun, 8 Jun 2025 21:56:35 +0000 (23:56 +0200)] 
[3.13] gh-135276: Refresh `zipfile.Path` from zipp 3.23 (GH-135277) (#135279)

* gh-135276: Refresh `zipfile.Path` from zipp 3.23 (GH-135277)

Apply changes from zipp 3.23
(cherry picked from commit 8d6eb0c26276c4013346622580072908d46d2341)

Co-authored-by: Jason R. Coombs <jaraco@jaraco.com>
* Removed features slated for Python 3.15 only.

---------

Co-authored-by: Jason R. Coombs <jaraco@jaraco.com>
5 months ago[3.13] gh-135263: Fix typo in token.NAME documentation (GH-135275) (#135281)
Miss Islington (bot) [Sun, 8 Jun 2025 21:55:12 +0000 (23:55 +0200)] 
[3.13] gh-135263: Fix typo in token.NAME documentation (GH-135275) (#135281)

gh-135263: Fix typo in token.NAME documentation (GH-135275)
(cherry picked from commit 8d17a412da7e7d8412efc625d48dcb5eecea50b0)

Co-authored-by: Vladyslav Lazoryk <80263725+lazorikv@users.noreply.github.com>
5 months ago[3.13] Update tutorial for new "Copy" button (GH-135007) (#135271)
Miss Islington (bot) [Sun, 8 Jun 2025 17:13:34 +0000 (19:13 +0200)] 
[3.13] Update tutorial for new "Copy" button (GH-135007) (#135271)

Co-authored-by: Stan Ulbrych <89152624+StanFromIreland@users.noreply.github.com>
Co-authored-by: Sergey B Kirpichev <skirpichev@gmail.com>
5 months ago[3.13] gh-134976: document the exception type that can be raised by `s[i]` (GH-134977...
Miss Islington (bot) [Sun, 8 Jun 2025 12:37:55 +0000 (14:37 +0200)] 
[3.13] gh-134976: document the exception type that can be raised by `s[i]` (GH-134977) (#135259)

gh-134976: document the exception type that can be raised by `s[i]` (GH-134977)
(cherry picked from commit 158e5162bfaa8a49178ce2c3f2455c3e03b60157)

Co-authored-by: Yongzi Li <204532581+Yzi-Li@users.noreply.github.com>
5 months ago[3.13] gh-134151 Fix `TypeError` in `email.utils.decode_params` when sorting RFC...
Miss Islington (bot) [Sun, 8 Jun 2025 07:38:00 +0000 (09:38 +0200)] 
[3.13] gh-134151 Fix `TypeError` in `email.utils.decode_params` when sorting RFC 2231 continuations (GH-134687) (#135248)

gh-134151 Fix `TypeError` in `email.utils.decode_params` when sorting RFC 2231 continuations (GH-134687)

- Fix sorting logic in `email.utils.decode_params` to handle None values.
- Update tests for RFC 2231 continuation sorting.
(cherry picked from commit bcb6b45cb86a2f9f65b6c41f27c36059ba86a50b)

Co-authored-by: Jiucheng(Oliver) <git.jiucheng@gmail.com>
5 months ago[3.13] gh-134160: Use PyModuleDef.m_free in the example module xxlimited (GH-135174...
Miss Islington (bot) [Sat, 7 Jun 2025 09:03:32 +0000 (11:03 +0200)] 
[3.13] gh-134160: Use PyModuleDef.m_free in the example module xxlimited (GH-135174) (GH-135214)

gh-134160: Use PyModuleDef.m_free in the example module xxlimited (GH-135174)
(cherry picked from commit 1adca08d658ee2d520f3193960eaf3ae2ead1cef)

Co-authored-by: Petr Viktorin <encukou@gmail.com>
Co-authored-by: neonene <53406459+neonene@users.noreply.github.com>
5 months ago[3.13] gh-134155: fix AttributeError in email._header_value_parser.get_address (GH...
Miss Islington (bot) [Fri, 6 Jun 2025 18:11:15 +0000 (20:11 +0200)] 
[3.13] gh-134155: fix AttributeError in email._header_value_parser.get_address (GH-134194) (#135192)

gh-134155: fix AttributeError in email._header_value_parser.get_address (GH-134194)

Append the defect to defects instead of to the parse tree.
(cherry picked from commit d9cad074d52fe31327429fd81e4d2eeea3dbe35b)

Co-authored-by: Sergey Miryanov <sergey.miryanov@gmail.com>
Co-authored-by: Bénédikt Tran <10796600+picnixz@users.noreply.github.com>
Co-authored-by: Hugo van Kemenade <1324225+hugovk@users.noreply.github.com>
5 months ago[3.13] Docs: Update `PyExc_*` tables in the c-api documentation (GH-131640) (GH-135221)
Miss Islington (bot) [Fri, 6 Jun 2025 15:57:52 +0000 (17:57 +0200)] 
[3.13] Docs: Update `PyExc_*` tables in the c-api documentation (GH-131640) (GH-135221)

Docs: Update `PyExc_*` tables in the c-api documentation (GH-131640)

Add `PyExc_BaseExceptionGroup` and `PyExc_EncodingWarning`
(cherry picked from commit f00512db20561370faad437853f6ecee0eec4856)

Co-authored-by: Yuki Kobayashi <drsuaimqjgar@gmail.com>
5 months ago[3.13] gh-128605: Revert "Add branch protections for x86_64 in asm_tr…ampoline.S...
Miss Islington (bot) [Fri, 6 Jun 2025 14:09:09 +0000 (16:09 +0200)] 
[3.13] gh-128605: Revert "Add branch protections for x86_64 in asm_tr…ampoline.S (GH-128606) (GH-135077)" (GH-135175) (GH-135203)

[3.14] gh-128605: Revert "Add branch protections for x86_64 in asm_tr…ampoline.S (GH-128606) (GH-135077)" (GH-135175)

This reverts commit 899cca6dbf76bf3e06a99f60a5f996ad6ba0761f,
which broke buildbots.
(cherry picked from commit b477e21d5cb85bc764d6d9d18d122aa703d7b548)

Co-authored-by: Petr Viktorin <encukou@gmail.com>
5 months ago[3.13] feat(docs): type fix - apply pep8 by using docstring instead of comment in...
Miss Islington (bot) [Fri, 6 Jun 2025 13:23:07 +0000 (15:23 +0200)] 
[3.13] feat(docs): type fix - apply pep8 by using docstring instead of comment in the doc. (GH-135181) (#135211)

feat(docs): type fix - apply pep8 by using docstring instead of comment in the doc. (GH-135181)

Giving the right example incitates the tutorial readers to do the same in the future.
(cherry picked from commit 343182853f19a42c0ba8980d3104076a8c7bcfe7)

Co-authored-by: Jean-Louis GUENEGO <jlguenego@gmail.com>
5 months ago[3.13] gh-135120: Add test.support.subTests() (GH-135121) (GH-135210)
Serhiy Storchaka [Fri, 6 Jun 2025 13:16:50 +0000 (16:16 +0300)] 
[3.13] gh-135120: Add test.support.subTests() (GH-135121) (GH-135210)

(cherry picked from commit 6ef06fad84244261c695ec337c7d2734277054db)

5 months ago[3.13] gh-134993: Add os.lstat() to os.supports_dir_fd (GH-135188) (#135206)
Miss Islington (bot) [Fri, 6 Jun 2025 12:36:50 +0000 (14:36 +0200)] 
[3.13] gh-134993: Add os.lstat() to os.supports_dir_fd (GH-135188) (#135206)

gh-134993: Add os.lstat() to os.supports_dir_fd (GH-135188)
(cherry picked from commit e004cf8fd5c006a7a1c60807a03066f4c43452e5)

Co-authored-by: Victor Stinner <vstinner@python.org>
5 months ago[3.13] gh-135151: Fix incorrect packaging of pyconfig.h in Windows installer (GH...
Steve Dower [Thu, 5 Jun 2025 22:03:38 +0000 (23:03 +0100)] 
[3.13] gh-135151: Fix incorrect packaging of pyconfig.h in Windows installer (GH-135180)

5 months ago[3.13] gh-134989: Fix Py_RETURN_NONE in the limited C API (GH-135165) (#135182)
Victor Stinner [Thu, 5 Jun 2025 15:02:09 +0000 (17:02 +0200)] 
[3.13] gh-134989: Fix Py_RETURN_NONE in the limited C API (GH-135165) (#135182)

gh-134989: Fix Py_RETURN_NONE in the limited C API (GH-135165)

Fix Py_RETURN_NONE, Py_RETURN_TRUE and Py_RETURN_FALSE macros in the
limited C API 3.11 and older:
Don't treat Py_None, Py_True and Py_False as immortal.

(cherry picked from commit 9258f3da9175134d03f2c8c7c7eed223802ad945)

5 months ago[3.13] gh-131884: Fix incorrect formatting in json.dumps() when using indent and...
Serhiy Storchaka [Thu, 5 Jun 2025 14:38:11 +0000 (17:38 +0300)] 
[3.13] gh-131884: Fix incorrect formatting in json.dumps() when using indent and skipkeys=True (GH-132200) (GH-135061)

(cherry picked from commit ec12559ebafca01ded22c9013de64abe535c838d)

Co-authored-by: Roei Ben Artzi <155478676+roeibenartzi@users.noreply.github.com>
5 months ago[3.13] gh-135124: Change stdout errors in regrtest worker process (GH-135138) (#135169)
Miss Islington (bot) [Thu, 5 Jun 2025 10:11:26 +0000 (12:11 +0200)] 
[3.13] gh-135124: Change stdout errors in regrtest worker process (GH-135138) (#135169)

gh-135124: Change stdout errors in regrtest worker process (GH-135138)

Set sys.stdout encoder error handler to backslashreplace in regrtest
workers to avoid UnicodeEncodeError when printing a traceback
or any other non-encodable character.

Move the code from the Regrtest class to setup_process().

Call setup_process() earlier, before displaying regrtest headers.
(cherry picked from commit 3d396ab7591d544ac8bc1fb49615b4e867ca1c83)

Co-authored-by: Victor Stinner <vstinner@python.org>
5 months ago[3.13] gh-131531: android.py enhancements to support cibuildwheel (GH-132870) (#135164)
Malcolm Smith [Thu, 5 Jun 2025 09:23:46 +0000 (10:23 +0100)] 
[3.13] gh-131531: android.py enhancements to support cibuildwheel (GH-132870) (#135164)

Modifies the environment handling and execution arguments of the Android management
script to support the compilation of third-party binaries, and the use of the testbed to
invoke third-party test code.
(cherry picked from commit 2e1544fd2b0cd46ba93fc51e3cdd47f4781d7499)

Co-authored-by: Malcolm Smith <smith@chaquo.com>
Co-authored-by: Adam Turner <9087854+AA-Turner@users.noreply.github.com>
Co-authored-by: Russell Keith-Magee <russell@keith-magee.com>
5 months ago[3.13] gh-129876: Update IDLE News3.txt to May 2025 (GH-135139) (#135141)
Miss Islington (bot) [Wed, 4 Jun 2025 15:50:21 +0000 (17:50 +0200)] 
[3.13] gh-129876: Update IDLE News3.txt to May 2025 (GH-135139) (#135141)

gh-129876: Update IDLE News3.txt to May 2025 (GH-135139)
(cherry picked from commit 0df15d0d4d55dcf7b7a7f4b2985bf84fd092d257)

Co-authored-by: Terry Jan Reedy <tjreedy@udel.edu>
5 months ago[3.13] gh-134989: Implement PyObject_DelAttr() as a macro in the limited C API (GH...
Victor Stinner [Wed, 4 Jun 2025 15:10:51 +0000 (17:10 +0200)] 
[3.13] gh-134989: Implement PyObject_DelAttr() as a macro in the limited C API (GH-135021) (#135134)

gh-134989: Implement PyObject_DelAttr() as a macro in the limited C API (GH-135021)

(cherry picked from commit c21113072cd1f0da83729f99d3576647db85d816)

5 months ago[3.13] gh-133256: Add _Py_NONSTRING macro (#133257) (#135135)
Victor Stinner [Wed, 4 Jun 2025 15:10:35 +0000 (17:10 +0200)] 
[3.13] gh-133256: Add _Py_NONSTRING macro (#133257) (#135135)

gh-133256: Add _Py_NONSTRING macro (#133257)

Fix GCC 15 compiler warnings such as:

    In file included from Python/pylifecycle.c:26:
    Include/internal/pycore_runtime.h:47:26: warning:
    initializer-string for array of 'char' truncates NUL terminator
    but destination lacks 'nonstring' attribute (9 chars into 8
    available) [-Wunterminated-string-initialization]
       47 | #define _Py_Debug_Cookie "xdebugpy"
          |                          ^~~~~~~~~~

(cherry picked from commit e26bafd107aa86a4bdd6051848640f36a56d0efb)

5 months ago[3.13] gh-126483: disable warnings filters mutation in concurrent test (GH-132694...
Miss Islington (bot) [Wed, 4 Jun 2025 13:29:22 +0000 (15:29 +0200)] 
[3.13] gh-126483: disable warnings filters mutation in concurrent test (GH-132694) (GH-135132)

The `test_ssl_in_multiple_threads` test failed because `test_check_hostname_idn()`
modified the global warnings filters via `warnings_helper.check_no_resource_warning()`.
Disable the warnings check in the multi-threaded test because `warnings_helper` isn't
thread-safe in 3.13 or earlier.
(cherry picked from commit 40c8be0008ecadb5d0dc9a017434b1133a3a6e06)

Co-authored-by: Thomas Grainger <tagrain@gmail.com>
* Fix for 3.13

---------

Co-authored-by: Thomas Grainger <tagrain@gmail.com>
Co-authored-by: Sam Gross <colesbury@gmail.com>
5 months ago[3.13] gh-135074: Fix exception messages in test.support module (GH-135076) (GH-135130)
Miss Islington (bot) [Wed, 4 Jun 2025 13:22:02 +0000 (15:22 +0200)] 
[3.13] gh-135074: Fix exception messages in test.support module (GH-135076) (GH-135130)

(cherry picked from commit bc00ce941e03347dade3faa8822f19836b5bbfe4)

Co-authored-by: Daniel Hollas <daniel.hollas@bristol.ac.uk>
5 months ago[3.13] gh-135108: Fix utmp.h inclusion in posixmodule.c on NetBSD (GH-135109) (GH...
Miss Islington (bot) [Wed, 4 Jun 2025 13:16:09 +0000 (15:16 +0200)] 
[3.13] gh-135108: Fix utmp.h inclusion in posixmodule.c on NetBSD (GH-135109) (GH-135128)

(cherry picked from commit 5b3865418ceb1448bfbf15cddf52c900cd5882a3)

Co-authored-by: Furkan Onder <furkanonder@protonmail.com>
5 months ago[3.13] gh-134160: Improve multi-phase init note on isolation & subinterpreters (GH...
Miss Islington (bot) [Wed, 4 Jun 2025 12:50:54 +0000 (14:50 +0200)] 
[3.13] gh-134160: Improve multi-phase init note on isolation & subinterpreters (GH-134775) (GH-134983)

(cherry picked from commit eb145fabbdd755f803296beba2d235fc32efe592)

Co-authored-by: Petr Viktorin <encukou@gmail.com>
Co-authored-by: Adam Turner <9087854+AA-Turner@users.noreply.github.com>
5 months ago[3.13] gh-135101: When choosing the default simulator device, don't use `simctl ...
Miss Islington (bot) [Wed, 4 Jun 2025 00:54:42 +0000 (02:54 +0200)] 
[3.13] gh-135101: When choosing the default simulator device, don't use `simctl --set testing` (GH-135102) (#135114)

On a fresh Xcode install (including some CI provider configurations), there is
no pre-existing testing set that can be used to identify simulator models. Use
the default device set to detect available models instead. Live testing
simulators are still created in the testing set.
(cherry picked from commit dba9de731b231ca0c079205f496d1e3d178b4fd3)

Co-authored-by: Joe Rickerby <joerick@mac.com>
5 months agoMerge branch '3.13' of https://github.com/python/cpython into 3.13
Thomas Wouters [Tue, 3 Jun 2025 20:22:54 +0000 (22:22 +0200)] 
Merge branch '3.13' of https://github.com/python/cpython into 3.13

5 months agoPost 3.13.4
Thomas Wouters [Tue, 3 Jun 2025 20:22:30 +0000 (22:22 +0200)] 
Post 3.13.4

5 months ago[3.13] Backport PyManager support to PC/layout script (GH-135096)
Steve Dower [Tue, 3 Jun 2025 20:21:11 +0000 (21:21 +0100)] 
[3.13] Backport PyManager support to PC/layout script (GH-135096)

5 months ago[3.13] gh-127081: use `getlogin_r` if available (gh-132751) (#135098)
Sam Gross [Tue, 3 Jun 2025 18:41:26 +0000 (14:41 -0400)] 
[3.13] gh-127081: use `getlogin_r` if available (gh-132751) (#135098)

The `getlogin` function is not thread-safe: replace with `getlogin_r` where
available.
(cherry picked from commit 1ffe913c2017b44804aca18befd45689df06c069)

Co-authored-by: Duane Griffin <duaneg@dghda.com>
5 months agoPython 3.13.4 v3.13.4
Thomas Wouters [Tue, 3 Jun 2025 15:34:08 +0000 (17:34 +0200)] 
Python 3.13.4

5 months ago[3.13] gh-135034: Normalize link targets in tarfile, add `os.path.realpath(strict...
T. Wouters [Tue, 3 Jun 2025 13:59:54 +0000 (15:59 +0200)] 
[3.13] gh-135034: Normalize link targets in tarfile, add `os.path.realpath(strict='allow_missing')` (GH-135037) (GH-135064)

Addresses CVEs 2024-12718, 2025-4138, 2025-4330, and 2025-4517.
(cherry picked from commit 3612d8f51741b11f36f8fb0494d79086bac9390a)

Co-authored-by: Łukasz Langa <lukasz@langa.pl>
Signed-off-by: Łukasz Langa <lukasz@langa.pl>
Co-authored-by: Petr Viktorin <encukou@gmail.com>
Co-authored-by: Seth Michael Larson <seth@python.org>
Co-authored-by: Adam Turner <9087854+AA-Turner@users.noreply.github.com>
Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
5 months ago[3.13] gh-128605: Add branch protections for x86_64 in asm_trampoline.S (GH-128606...
Miss Islington (bot) [Tue, 3 Jun 2025 13:54:53 +0000 (15:54 +0200)] 
[3.13] gh-128605: Add branch protections for x86_64 in asm_trampoline.S (GH-128606) (GH-135077) (#135083)

[3.14] gh-128605: Add branch protections for x86_64 in asm_trampoline.S (GH-128606) (GH-135077)

Apply Intel Control-flow Technology for x86-64 on asm_trampoline.S.

Required for mitigation against return-oriented programming (ROP)
and Call or Jump Oriented Programming (COP/JOP) attacks.

Manual application is required for the assembly files.

See also: https://sourceware.org/annobin/annobin.html/Test-cf-protection.html
(cherry picked from commit 899cca6dbf76bf3e06a99f60a5f996ad6ba0761f)

Co-authored-by: stratakis <cstratak@redhat.com>
5 months ago[3.13] gh-134875: Fix mimallc build error for the old compilers (gh-134994) (gh-135054)
Miss Islington (bot) [Tue, 3 Jun 2025 08:04:20 +0000 (10:04 +0200)] 
[3.13] gh-134875: Fix mimallc build error for the old compilers (gh-134994) (gh-135054)

gh-134875: Fix mimallc build error for the old compilers (gh-134994)
(cherry picked from commit b525e31b7fc50e7a498f8b9b16437cb7b9656f6f)

Co-authored-by: Donghee Na <donghee.na@python.org>
5 months ago[3.13] gh-133454: Mark test_queue tests with many threads as bigmem (gh-134575) ...
Miss Islington (bot) [Mon, 2 Jun 2025 20:49:32 +0000 (22:49 +0200)] 
[3.13] gh-133454: Mark test_queue tests with many threads as bigmem (gh-134575) (GH-135047)

50 producer and 50 consumer threads need more than 5GB of memory.
(cherry picked from commit 7a79f52d83c22f5a9787e590f267325c1175d389)

Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
5 months ago[3.13] gh-74232: Add a note about roundtrip of non-float numerics in CSV (GH-134963...
Miss Islington (bot) [Mon, 2 Jun 2025 20:39:01 +0000 (22:39 +0200)] 
[3.13] gh-74232: Add a note about roundtrip of non-float numerics in CSV (GH-134963) (GH-135049)

(cherry picked from commit e814f43f2c655b931af8ee9e1c128bd1027549fb)

Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
5 months ago[3.13] gh-133489: Remove size restrictions on getrandbits() and randbytes() (GH-13365...
Serhiy Storchaka [Mon, 2 Jun 2025 20:16:30 +0000 (23:16 +0300)] 
[3.13] gh-133489: Remove size restrictions on getrandbits() and randbytes() (GH-133658) (GH-134965)

random.getrandbits() can now generate more that 2**31 bits.
random.randbytes() can now generate more that 256 MiB.
(cherry picked from commit 68784fed78aa297f0de0d038742495709185bef5)

5 months ago[3.13] gh-134908: Protect `textiowrapper_iternext` with critical section (gh-134910...
Sam Gross [Mon, 2 Jun 2025 19:40:42 +0000 (15:40 -0400)] 
[3.13] gh-134908: Protect `textiowrapper_iternext` with critical section (gh-134910) (gh-135040)

The `textiowrapper_iternext` function called `_textiowrapper_writeflush`, but did not
use a critical section, making it racy in free-threaded builds.
(cherry picked from commit 44fb7c361cb24dcf9989a7a1cfee4f6aad5c81aa)

Co-authored-by: Duane Griffin <duaneg@dghda.com>
5 months ago[3.13] gh-130999: Avoid exiting the new REPL when there are non-string candidates...
Miss Islington (bot) [Mon, 2 Jun 2025 14:58:29 +0000 (16:58 +0200)] 
[3.13] gh-130999: Avoid exiting the new REPL when there are non-string candidates for suggestions (gh-131001) (gh-135020)

Co-authored-by: Łukasz Langa <lukasz@langa.pl>
5 months ago[3.13] gh-122153: indicate that Windows does not support `socket.{send,recv}_fds...
Bénédikt Tran [Mon, 2 Jun 2025 10:44:39 +0000 (12:44 +0200)] 
[3.13] gh-122153: indicate that Windows does not support `socket.{send,recv}_fds` (GH-134960) (#135017)

This amends commit e3b6ff19aaa318a813130ba9ad2ab0a332f27feb.
(cherry picked from commit 128195e12eb6d5b9542558453df7045dd7aa1e15)

Co-authored-by: GalaxySnail <me@glxys.nl>
5 months ago[3.13] gh-133503: clarify `compileall -s/-p` docs (GH-134756) (#134996)
Miss Islington (bot) [Sun, 1 Jun 2025 08:27:26 +0000 (10:27 +0200)] 
[3.13] gh-133503: clarify `compileall -s/-p` docs (GH-134756) (#134996)

gh-133503: clarify `compileall -s/-p` docs (GH-134756)
(cherry picked from commit fe6f8a3619242b287a793a5b5d8645f402482c71)

Co-authored-by: Rihaan Meher <meherrihaan@gmail.com>
Co-authored-by: Bénédikt Tran <10796600+picnixz@users.noreply.github.com>
5 months ago[3.13] gh-134696: align OpenSSL and HACL*-based hash functions constructors AC signat...
Bénédikt Tran [Sun, 1 Jun 2025 08:27:02 +0000 (10:27 +0200)] 
[3.13] gh-134696: align OpenSSL and HACL*-based hash functions constructors AC signatures (GH-134713) (#134962)

OpenSSL and HACL*-based hash functions constructors now support both `data` and `string` parameters.
Previously these constructor functions inconsistently supported sometimes `data` and sometimes `string`,
while the documentation expected `data` to be given in all cases.

(cherry picked from commit c6e63d9d351f6d952000ec3bf84b3a7607989f92)
(cherry picked from commit 379d0bc95646dfe923e7ea05fb7f1befbd85572d)

5 months ago[3.13] gh-134835: Remove outdated list from `howto/urllib2.rst` (GH-134844) (#134985)
Miss Islington (bot) [Sat, 31 May 2025 17:54:38 +0000 (19:54 +0200)] 
[3.13] gh-134835: Remove outdated list from `howto/urllib2.rst` (GH-134844) (#134985)

gh-134835: Remove outdated list from `howto/urllib2.rst` (GH-134844)

:teapot:
(cherry picked from commit 3704171415c1ea6ebbeb2f992758b6565f42e378)

Co-authored-by: Stan Ulbrych <89152624+StanFromIreland@users.noreply.github.com>
5 months ago[3.13] gh-134954: Hard-cap max file descriptors in subprocess test fd_status (GH...
Miss Islington (bot) [Sat, 31 May 2025 14:51:48 +0000 (16:51 +0200)] 
[3.13] gh-134954: Hard-cap max file descriptors in subprocess test fd_status (GH-134955) (#134981)

gh-134954: Hard-cap max file descriptors in subprocess test fd_status (GH-134955)

* Hard-cap max file descriptors in subprocess test fd_status

On some systems, `SC_OPEN_MAX` may return a very large value (i.e. 10**30), leading to the subprocess test timing out (or run forever).
Prevent this situation by applying a hard cap on how many file descriptors are checked.

* Fix typo in usage docstring

s/fd_stats/fd_status/
(cherry picked from commit f58873e4b2b7aad8e3a08a6188c6eb08d0a3001b)

Co-authored-by: Itamar Oren <itamarost@gmail.com>
6 months ago[3.13] gh-134918: Fix and improve doctest's documentation (GH-134919) (GH-134967)
Miss Islington (bot) [Sat, 31 May 2025 09:09:07 +0000 (11:09 +0200)] 
[3.13] gh-134918: Fix and improve doctest's documentation (GH-134919) (GH-134967)

(cherry picked from commit 3c66e5976669a599adfb260514c03815b1a9e4e9)

Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
6 months ago[3.13] GH-106235: Clarify `parse_known_args` documentation by removing "remaining...
Miss Islington (bot) [Fri, 30 May 2025 20:24:22 +0000 (22:24 +0200)] 
[3.13] GH-106235: Clarify `parse_known_args` documentation by removing "remaining" (GH-126921) (#134914)

GH-106235: Clarify `parse_known_args` documentation by removing "remaining" (GH-126921)
(cherry picked from commit a4251411a97304ab001721c6231d86ddf4eac3f0)

Co-authored-by: Savannah Bailey <savannahostrowski@gmail.com>
6 months agogh-134923: Use /GENPROFILE and /USEPROFILE for Windows PGO builds (GH-134924)
Steve Dower [Fri, 30 May 2025 19:03:59 +0000 (20:03 +0100)] 
gh-134923: Use /GENPROFILE and /USEPROFILE for Windows PGO builds (GH-134924)

6 months ago[3.13] gh-134733: Fix documentation for the show_empty option of ast.dump() (GH-13492...
Miss Islington (bot) [Fri, 30 May 2025 16:30:26 +0000 (18:30 +0200)] 
[3.13] gh-134733: Fix documentation for the show_empty option of ast.dump() (GH-134925) (GH-134941)

Optional None values are always omitted.
(cherry picked from commit 1a89991d2362867a9127e151376135615bc92a4c)

Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>