]> git.ipfire.org Git - thirdparty/Python/cpython.git/log
thirdparty/Python/cpython.git
7 months ago[3.13] gh-117657: Fix TSAN data race in _PyEval_SetTrace assertion (gh-131561) (...
Miss Islington (bot) [Fri, 21 Mar 2025 18:48:40 +0000 (19:48 +0100)] 
[3.13] gh-117657: Fix TSAN data race in _PyEval_SetTrace assertion (gh-131561) (#131564)

The `sys_tracing_threads` variable should be read inside `LOCK_SETUP()`.
(cherry picked from commit 0de5e0c5442abddbe17481ef450e4abc992058f5)

Co-authored-by: Sam Gross <colesbury@gmail.com>
7 months ago[3.13] gh-131507: Refactor screen and cursor position calculations (GH-131547) (GH...
Miss Islington (bot) [Fri, 21 Mar 2025 17:58:06 +0000 (18:58 +0100)] 
[3.13] gh-131507: Refactor screen and cursor position calculations (GH-131547) (GH-131557)

gh-131507: Refactor screen and cursor position calculations (GH-131547)

This is based off GH-131509.
(cherry picked from commit 4cc82ffa377db5073fdc6f85c6f35f9c47397796)

Co-authored-by: Łukasz Langa <lukasz@langa.pl>
7 months ago[3.13] gh-131507: Clean up tests and type checking for `_pyrepl` (GH-131509) (GH...
Łukasz Langa [Fri, 21 Mar 2025 16:25:45 +0000 (17:25 +0100)] 
[3.13] gh-131507: Clean up tests and type checking for `_pyrepl` (GH-131509) (GH-131546)

(cherry picked from commit 5d8e981c8477ce483374b2fe6cd309a08c956299)

7 months ago[3.13] gh-131492, gh-131461: handle exceptions in GzipFile constructor while owning...
Miss Islington (bot) [Fri, 21 Mar 2025 10:20:52 +0000 (11:20 +0100)] 
[3.13] gh-131492, gh-131461: handle exceptions in GzipFile constructor while owning resources (GH-131462) (#131518)

(cherry picked from commit ce79274e9f093bd06d2285c9af48dbcbc92173de)

Co-authored-by: Thomas Grainger <tagrain@gmail.com>
Co-authored-by: Victor Stinner <vstinner@python.org>
7 months ago[3.13] gh-131441: Add a set of asserts to test.test_capi.test_list (GH-131442) (...
Miss Islington (bot) [Thu, 20 Mar 2025 19:25:16 +0000 (20:25 +0100)] 
[3.13] gh-131441: Add a set of asserts to test.test_capi.test_list (GH-131442) (#131523)

gh-131441: Add a set of asserts to test.test_capi.test_list (GH-131442)
(cherry picked from commit 2433cc79d79d9c1db8e53d4b9bde26e9a47fb0b9)

Co-authored-by: Nybblista <170842536+nybblista@users.noreply.github.com>
7 months ago[3.13] gh-88887: Cleanup `multiprocessing.resource_tracker.ResourceTracker` upon...
Miss Islington (bot) [Thu, 20 Mar 2025 17:08:58 +0000 (18:08 +0100)] 
[3.13] gh-88887: Cleanup `multiprocessing.resource_tracker.ResourceTracker` upon deletion (GH-130429) (#131516)

gh-88887: Cleanup `multiprocessing.resource_tracker.ResourceTracker` upon deletion (GH-130429)
(cherry picked from commit f53e7de6a84a0f535efb75c3671283b801a1af0f)

Co-authored-by: luccabb <32229669+luccabb@users.noreply.github.com>
Co-authored-by: Victor Stinner <vstinner@python.org>
Co-authored-by: Gregory P. Smith <greg@krypto.org>
7 months ago[3.13] GH-121970: Extract `pydoc_topics` into a new extension (GH-131256) (#131511)
Adam Turner [Thu, 20 Mar 2025 15:34:10 +0000 (15:34 +0000)] 
[3.13] GH-121970: Extract `pydoc_topics` into a new extension (GH-131256) (#131511)

(cherry picked from commit c1a02f9101f0b2d9dc7cfb4b8be5193e7459a906)

7 months ago[3.13] Docs: Fix documentation for "PyTypeObject Definition" (GH-130936) (GH-131458)
Miss Islington (bot) [Thu, 20 Mar 2025 12:41:06 +0000 (13:41 +0100)] 
[3.13] Docs: Fix documentation for "PyTypeObject Definition" (GH-130936) (GH-131458)

The structure definition for `PyTypeObject` is in `Include/cpython/object.h`,
not in `Include/object.h`.
(cherry picked from commit a0478c9f0c6d6a75ca35a8dc2c74d3b58877f094)

Co-authored-by: Yuki Kobayashi <drsuaimqjgar@gmail.com>
7 months ago[3.13] gh-131117: Update tp_finalize example to use PyErr_GetRaisedException (GH...
Miss Islington (bot) [Wed, 19 Mar 2025 17:34:15 +0000 (18:34 +0100)] 
[3.13] gh-131117: Update tp_finalize example to use PyErr_GetRaisedException (GH-131118) (#131476)

gh-131117: Update tp_finalize example to use PyErr_GetRaisedException (GH-131118)

The tp_finalize C API doc used PyErr_Fetch() and PyErr_Restore() in
its example code. That API was deprecated in 3.12.

Update to point to the suggested replacement function
PyErr_GetRaisedException() which has a sample usage.
(cherry picked from commit a4832f6b9a62771725b159bc7cd6c49fb45e3bc8)

Co-authored-by: Cody Maloney <cmaloney@users.noreply.github.com>
7 months ago[3.13] gh-131263: Skip test_timerfd_negative on NetBSD to prevent system freeze ...
Miss Islington (bot) [Wed, 19 Mar 2025 11:52:11 +0000 (12:52 +0100)] 
[3.13] gh-131263: Skip test_timerfd_negative on NetBSD to prevent system freeze (GH-131431) (#131451)

gh-131263: Skip test_timerfd_negative on NetBSD to prevent system freeze (GH-131431)
(cherry picked from commit 8ad4646c675211dc1df0254a3160f50a18e4c6c3)

Co-authored-by: Furkan Onder <furkanonder@protonmail.com>
7 months ago[3.13] gh-118915: Document `PY_MONITORING_IS_INSTRUMENTED_EVENT` (GH-128026) (GH...
Miss Islington (bot) [Wed, 19 Mar 2025 10:37:34 +0000 (11:37 +0100)] 
[3.13] gh-118915: Document `PY_MONITORING_IS_INSTRUMENTED_EVENT` (GH-128026) (GH-131424)

(cherry picked from commit f81990024554a75e2ab31133a72d9f0954690435)

Co-authored-by: Yuki Kobayashi <drsuaimqjgar@gmail.com>
7 months ago[3.13] gh-131417: Mention asyncio Future and Task in docs for generic classes list...
Miss Islington (bot) [Wed, 19 Mar 2025 09:23:48 +0000 (10:23 +0100)] 
[3.13] gh-131417: Mention asyncio Future and Task in docs for generic classes list (GH-131422) (#131445)

gh-131417: Mention asyncio Future and Task in docs for generic classes list (GH-131422)

Mention asyncio Future and Task in docs for generic classes list
(cherry picked from commit 61b4b2c57c9327273f2e306bafa23cf2c70eac8e)

Co-authored-by: Andrew Svetlov <andrew.svetlov@gmail.com>
7 months ago[3.13] Docs: fix shell command formatting (GH-131310) (#131443)
Miss Islington (bot) [Wed, 19 Mar 2025 07:50:53 +0000 (08:50 +0100)] 
[3.13] Docs: fix shell command formatting (GH-131310) (#131443)

Docs: fix shell command formatting (GH-131310)

replace "zypper in" with "zypper install" to avoid incorrect highlighting
(cherry picked from commit 267c06d6a8290aa299098b4fcd3f270001b01e72)

Co-authored-by: partev <petrosyan@gmail.com>
7 months ago[3.13] gh-124666: Improve thread cleanup in test_android (GH-131427) (#131433)
Miss Islington (bot) [Wed, 19 Mar 2025 00:30:59 +0000 (01:30 +0100)] 
[3.13] gh-124666: Improve thread cleanup in test_android (GH-131427) (#131433)

Ensures that failures in test setup don't result in dangling threads.
(cherry picked from commit 01b5abbc53b2a9ee8d85e0518c98efce27dbd061)

Co-authored-by: Malcolm Smith <smith@chaquo.com>
7 months ago[3.13] gh-121284: Fix email address header folding with parsed encoded-word (GH-12275...
Miss Islington (bot) [Tue, 18 Mar 2025 19:34:00 +0000 (20:34 +0100)] 
[3.13] gh-121284: Fix email address header folding with parsed encoded-word (GH-122754) (#131403)

gh-121284: Fix email address header folding with parsed encoded-word (GH-122754)

Email generators using email.policy.default may convert an RFC 2047
encoded-word to unencoded form during header refolding. In a structured
header, this could allow 'specials' chars outside a quoted-string,
leading to invalid address headers and enabling spoofing. This change
ensures a parsed encoded-word that contains specials is kept as an
encoded-word while the header is refolded.

[Better fix from @bitdancer.]

---------
(cherry picked from commit 295b53df2aa18deb625a7da41f7e4babfe6ef34b)

Co-authored-by: Mike Edmunds <medmunds@gmail.com>
Co-authored-by: R David Murray <rdmurray@bitdance.com>
Co-authored-by: Petr Viktorin <encukou@gmail.com>
7 months ago[3.13] gh-131277: allow EnvironmentVarGuard to unset more than one environment variab...
Bénédikt Tran [Tue, 18 Mar 2025 12:48:59 +0000 (13:48 +0100)] 
[3.13] gh-131277: allow EnvironmentVarGuard to unset more than one environment variable at once (GH-131280) (#131409)

(cherry picked from commit 3185e3115c918ec189e16cf9f5b51a13a0146556)

---------

Co-authored-by: Hugo van Kemenade <1324225+hugovk@users.noreply.github.com>
7 months ago[3.13] gh-116666: Add "token" glossary term (GH-130888) (GH-131367)
Miss Islington (bot) [Tue, 18 Mar 2025 11:51:02 +0000 (12:51 +0100)] 
[3.13] gh-116666: Add "token" glossary term (GH-130888) (GH-131367)

gh-116666: Add "token" glossary term (GH-130888)

Add glossary entry for `token`, and link to it.
Avoid talking about tokens in the SyntaxError intro (errors.rst); at this point
tokenization is too much of a technical detail. (Even to an advanced reader,
the fact that a *single* token is highlighted isn't too relevant. Also, we don't
need to guarantee that it's a single token.)
(cherry picked from commit 30d52058493e07fd1d3efea960482f4001bd2f86)

Co-authored-by: Petr Viktorin <encukou@gmail.com>
Co-authored-by: Adam Turner <9087854+AA-Turner@users.noreply.github.com>
7 months ago[3.13] gh-131002: clarify how to enforce sqlite3 column types for generated fields...
Miss Islington (bot) [Tue, 18 Mar 2025 11:09:41 +0000 (12:09 +0100)] 
[3.13] gh-131002: clarify how to enforce sqlite3 column types for generated fields (GH-131006) (#131385)

(cherry picked from commit f48887fb97651c02c5e412a75ed8b51a4ca11e6a)

Co-authored-by: Erlend E. Aasland <erlend@python.org>
7 months ago[3.13] gh-130132: properly free resources in `urrlib.urlopen` examples (GH-130280...
Miss Islington (bot) [Tue, 18 Mar 2025 09:33:19 +0000 (10:33 +0100)] 
[3.13] gh-130132: properly free resources in `urrlib.urlopen` examples (GH-130280) (#131394)

gh-130132: properly free resources in `urrlib.urlopen` examples (GH-130280)
(cherry picked from commit 77d2fd441320ca365c34e21c475d3878f3d5d833)

Co-authored-by: Kanishk Pachauri <itskanishkp.py@gmail.com>
Co-authored-by: sobolevn <mail@sobolevn.me>
Co-authored-by: Bénédikt Tran <10796600+picnixz@users.noreply.github.com>
7 months ago[3.13] gh-131094: Refine `math.isclose` docs (GH-131139) (#131392)
Miss Islington (bot) [Tue, 18 Mar 2025 09:21:13 +0000 (10:21 +0100)] 
[3.13] gh-131094: Refine `math.isclose` docs (GH-131139) (#131392)

gh-131094: Refine `math.isclose` docs (GH-131139)
(cherry picked from commit 3f50f96586d46497e4d9de065c4424fe2d72508e)

Co-authored-by: Guy Jacoby <49398101+guyjacoby@users.noreply.github.com>
7 months ago[3.13] gh-127667: refactor and improve `_hashopenssl.c` error branches (#131145)...
Bénédikt Tran [Tue, 18 Mar 2025 09:16:49 +0000 (10:16 +0100)] 
[3.13] gh-127667: refactor and improve `_hashopenssl.c` error branches (#131145) (#131347)

gh-127667: refactor and improve `_hashopenssl.c` error branches (#131145)

Refactor `_setException()` into different helpers that can be used separately:

- set_ssl_exception_from_errcode(): set an exception from an explicit SSL error code.
- raise_ssl_error(): set an exception from the last SSL error code or use a user-defined message.
- notify_ssl_error_occurred(): same as raise_ssl_error() but with a generic default message.

(cherry-picked from commit ac50ece6cea8745834e4ec0a9617809a51245bfc).

7 months ago[3.13] gh-118201: Simplify conv_confname (#126089) (#131375)
Malcolm Smith [Tue, 18 Mar 2025 04:53:10 +0000 (04:53 +0000)] 
[3.13] gh-118201: Simplify conv_confname (#126089) (#131375)

gh-118201: Simplify conv_confname (#126089)

(cherry picked from commit c5c9286804e38c95fe717f22ce1bf2f18eee5b17)

7 months ago[3.13] gh-131325: fix sendfile fallback implementation to drain data after writing...
Miss Islington (bot) [Mon, 17 Mar 2025 19:46:30 +0000 (20:46 +0100)] 
[3.13] gh-131325: fix sendfile fallback implementation to drain data after writing to transport (GH-131376) (#131377)

gh-131325: fix sendfile fallback implementation to drain data after writing to transport (GH-131376)
(cherry picked from commit 94f4d87aeb4d2d7bddcb4c3aad4f62a727ac91ee)

Co-authored-by: Kumar Aditya <kumaraditya@python.org>
7 months ago[3.13] Docs: Fix incorrect sphinx markup for a class member (GH-130970) (GH-131366)
Miss Islington (bot) [Mon, 17 Mar 2025 15:46:05 +0000 (16:46 +0100)] 
[3.13] Docs: Fix incorrect sphinx markup for a class member (GH-130970) (GH-131366)

(cherry picked from commit 9a634c5c0cde70a0575c006d04e4cfe917f647ef)

Co-authored-by: Yuki Kobayashi <drsuaimqjgar@gmail.com>
7 months ago[3.13] gh-129675: Update documentation for tp_basicsize & tp_itemsize (GH-129850...
Miss Islington (bot) [Mon, 17 Mar 2025 15:18:26 +0000 (16:18 +0100)] 
[3.13] gh-129675: Update documentation for tp_basicsize & tp_itemsize (GH-129850) (GH-131079)

- Add alignment requirement
- Mention that ob_size is unreliable if you don't control it
- Add some links for context
- basicsize should include the base type in generaly not just PyObject
- suggest Py_SIZE & Py_SET_SIZE

This adds a “by-the-way” link to `PyObject_New`, which shouldn't be
used for GC types. In order to be comfortable linking to it, I also
add a link to `PyObject_GC_New` from its docs. And the same for
`*Var` variants, while I'm here.

(cherry picked from commit ad0f618ab3eb1f26f8830a863aaf7bb70835c00d)

Co-authored-by: Petr Viktorin <encukou@gmail.com>
7 months ago[3.13] gh-131261: Update libexpat to 2.7.0 (CVE-2024-8176)
Petr Viktorin [Mon, 17 Mar 2025 14:44:28 +0000 (15:44 +0100)] 
[3.13] gh-131261: Update libexpat to 2.7.0 (CVE-2024-8176)

(cherry picked from commit bb0268f60dfe903a9bdb8d84104247a9318c6b18)

Co-authored-by: Gregory P. Smith <greg@krypto.org>
7 months ago[3.13] gh-129843: fix pure Python implementation of `warnings.warn_explicit` (GH...
Miss Islington (bot) [Mon, 17 Mar 2025 11:18:42 +0000 (12:18 +0100)] 
[3.13] gh-129843: fix pure Python implementation of `warnings.warn_explicit` (GH-129848) (#131349)

gh-129843: fix pure Python implementation of `warnings.warn_explicit` (GH-129848)

The pure Python implementation of `warnings.warn_explicit` constructs a `WarningMessage`
with an incorrect source (it incorrectly sets the WarningMessage's line to the given `source`).
(cherry picked from commit 80e00ecc399db8aeaa9f3a1c87a2cfb34517d7be)

Co-authored-by: Srinivas Reddy Thatiparthy (తాటిపర్తి శ్రీనివాస్ రెడ్డి) <thatiparthysreenivas@gmail.com>
7 months ago[3.13] gh-131339: test PyBytes_Size for a zero-size bytes object (GH-131340) (#131343)
Miss Islington (bot) [Mon, 17 Mar 2025 09:01:40 +0000 (10:01 +0100)] 
[3.13] gh-131339: test PyBytes_Size for a zero-size bytes object (GH-131340) (#131343)

gh-131339: test PyBytes_Size for a zero-size bytes object (GH-131340)
(cherry picked from commit 3ae67ba97e88d6f066a5b6f0c809f57fe4a1ecbe)

Co-authored-by: Nybblista <170842536+nybblista@users.noreply.github.com>
7 months ago[3.13] gh-131327: Document winsound.SND_APPLICATION (GH-131328) (#131330)
Miss Islington (bot) [Sun, 16 Mar 2025 15:52:48 +0000 (16:52 +0100)] 
[3.13] gh-131327: Document winsound.SND_APPLICATION (GH-131328) (#131330)

gh-131327: Document winsound.SND_APPLICATION (GH-131328)
(cherry picked from commit bf4c1bf344ed1f80c4e8f4fd5b1a8f0e0858777e)

Co-authored-by: AN Long <aisk@users.noreply.github.com>
Co-authored-by: Bénédikt Tran <10796600+picnixz@users.noreply.github.com>
7 months ago[3.13] gh-130160: use `.. program::` directive for documenting `doctest` CLI (GH...
Miss Islington (bot) [Sun, 16 Mar 2025 11:59:26 +0000 (12:59 +0100)] 
[3.13] gh-130160: use `.. program::` directive for documenting `doctest` CLI (GH-131034) (#131320)

gh-130160: use `.. program::` directive for documenting `doctest` CLI (GH-131034)
(cherry picked from commit 9558d22ac308c102e4f843541eead2022050225e)

Co-authored-by: donBarbos <donbarbos@proton.me>
Co-authored-by: Bénédikt Tran <10796600+picnixz@users.noreply.github.com>
7 months ago[3.13] gh-130160: use `.. program::` directive for documenting `http.server` CLI...
Miss Islington (bot) [Sat, 15 Mar 2025 19:12:40 +0000 (20:12 +0100)] 
[3.13] gh-130160: use `.. program::` directive for documenting `http.server` CLI (GH-131010) (#131293)

gh-130160: use `.. program::` directive for documenting `http.server` CLI (GH-131010)
(cherry picked from commit 7ae9c5dd25cccfc4e44fae6c6974ab9f32c5e985)

Co-authored-by: donBarbos <donbarbos@proton.me>
7 months ago[3.13] gh-130382: add missing `_PyReftracerTrack` to ceval `Py_DECREF` (GH-130689...
Sam Gross [Fri, 14 Mar 2025 13:52:05 +0000 (09:52 -0400)] 
[3.13] gh-130382: add missing `_PyReftracerTrack` to ceval `Py_DECREF` (GH-130689) (#131195)

(cherry picked from commit c5abded09995f208b21ebaf012185ca5acb0180b)

Co-authored-by: Tomasz Pytel <tompytel@gmail.com>
7 months ago[3.13] gh-131204: Fix `difflib.HtmlDiff` may not use monospaced font (GH-131221)...
Wulian233 [Fri, 14 Mar 2025 12:27:13 +0000 (20:27 +0800)] 
[3.13] gh-131204: Fix `difflib.HtmlDiff` may not use monospaced font (GH-131221) (#131242)

(cherry picked from commit 7fd6160)

7 months ago[3.13] gh-131234: Improve `test_popen` with more asserts (GH-131235) (#131240)
Miss Islington (bot) [Fri, 14 Mar 2025 12:02:47 +0000 (13:02 +0100)] 
[3.13] gh-131234: Improve `test_popen` with more asserts (GH-131235) (#131240)

gh-131234: Improve `test_popen` with more asserts (GH-131235)
(cherry picked from commit fc07f863ee2a942dd96e1ca9edf049603fbb574e)

Co-authored-by: sobolevn <mail@sobolevn.me>
7 months ago[3.13] gh-131219: Improve tests in `test_lzma.py` by adding more asserts (GH-131220...
Miss Islington (bot) [Fri, 14 Mar 2025 11:05:59 +0000 (12:05 +0100)] 
[3.13] gh-131219: Improve tests in `test_lzma.py` by adding more asserts (GH-131220) (#131231)

gh-131219: Improve tests in `test_lzma.py` by adding more asserts (GH-131220)
(cherry picked from commit f6c24a5c89a1f08d583ab7f4d5c6751223f8e280)

Co-authored-by: sobolevn <mail@sobolevn.me>
7 months ago[3.13] gh-130814: Enhance documentation for Python C API type objects (GH-130817...
Miss Islington (bot) [Fri, 14 Mar 2025 09:59:19 +0000 (10:59 +0100)] 
[3.13] gh-130814: Enhance documentation for Python C API type objects (GH-130817) (#131225)

gh-130814: Enhance documentation for Python C API type objects (GH-130817)

The "Type Objects" title in `c-api/typeobj.rst`, duplicating the title of `c-api/type.rst`,
has been changed to "Type Objects Structures", thereby slightly improving Sphinx
search.
(cherry picked from commit 6b932edc5216d9766e70fef300a6b842ab33204c)

Co-authored-by: sharktide <meherrihaan@gmail.com>
7 months ago[3.13] gh-124269: Simplify `typing.Annotated` docs (GH-130770) (#131222)
Miss Islington (bot) [Fri, 14 Mar 2025 09:53:03 +0000 (10:53 +0100)] 
[3.13] gh-124269: Simplify `typing.Annotated` docs (GH-130770) (#131222)

gh-124269: Simplify `typing.Annotated` docs (GH-130770)

---------
(cherry picked from commit e4ac196aaaa9fd2f1bd0050797b58959671c549a)

Co-authored-by: Stan Ulbrych <89152624+StanFromIreland@users.noreply.github.com>
Co-authored-by: Jelle Zijlstra <jelle.zijlstra@gmail.com>
Co-authored-by: Bénédikt Tran <10796600+picnixz@users.noreply.github.com>
7 months ago[3.13] gh-85012: Properly reset msgctxt when compiling messages with msgfmt (GH-13052...
Serhiy Storchaka [Thu, 13 Mar 2025 19:15:28 +0000 (21:15 +0200)] 
[3.13] gh-85012: Properly reset msgctxt when compiling messages with msgfmt (GH-130525) (GH-131205)

Add also human-readable snapshots for tests.
(cherry picked from commit 7ea6e88eb490635518c63c3305c03baf3e151555)

Co-authored-by: Tomas R <tomas.roun8@gmail.com>
7 months ago[3.13] gh-131032: Add support.linked_to_musl() function (#131071) (#131179)
Victor Stinner [Thu, 13 Mar 2025 09:59:57 +0000 (10:59 +0100)] 
[3.13] gh-131032: Add support.linked_to_musl() function (#131071) (#131179)

gh-131032: Add support.linked_to_musl() function (#131071)

Skip test_math.test_fma_zero_result() if Python is linked to the musl
C library.

(cherry picked from commit 68922ace4dabb6635e6d5b51bbe6485ef2e9dad2)

7 months ago[3.13] gh-131141: fix data race in instrumentation while registering callback (#131166)
Kumar Aditya [Thu, 13 Mar 2025 09:41:26 +0000 (15:11 +0530)] 
[3.13] gh-131141: fix data race in instrumentation while registering callback (#131166)

7 months ago[3.13] gh-130940: Remove PyConfig.use_system_logger (#131129)
Russell Keith-Magee [Thu, 13 Mar 2025 03:53:11 +0000 (11:53 +0800)] 
[3.13] gh-130940: Remove PyConfig.use_system_logger (#131129)

Removes ``PyConfig.use_system_logger``, resolving an ABI incompatibility introduced in
3.13.2.

Changes the default behavior of iOS to *always* direct stdout/stderr to the system log.

7 months ago[3.13] gh-93096: Load doctests in `test_itertools` (GH-131133) (#131136)
Miss Islington (bot) [Wed, 12 Mar 2025 08:03:24 +0000 (09:03 +0100)] 
[3.13] gh-93096: Load doctests in `test_itertools` (GH-131133) (#131136)

gh-93096: Load doctests in `test_itertools` (GH-131133)
(cherry picked from commit 15a8412b5e12ae46761843d4442c7b56ffa75176)

Co-authored-by: donBarbos <donbarbos@proton.me>
7 months ago[3.13] Use subTest() in math.fma() tests (GH-131125) (#131132)
Miss Islington (bot) [Wed, 12 Mar 2025 06:47:01 +0000 (07:47 +0100)] 
[3.13] Use subTest() in math.fma() tests (GH-131125) (#131132)

Use subTest() in math.fma() tests (GH-131125)
(cherry picked from commit 52756c30dbedafc6e5db3950049f18db2020b4bb)

Co-authored-by: Sergey B Kirpichev <skirpichev@gmail.com>
7 months ago[3.13] gh-117174: Fix reference leak and gdb tests (GH-131095) (#131120)
Pablo Galindo Salgado [Tue, 11 Mar 2025 23:43:07 +0000 (23:43 +0000)] 
[3.13] gh-117174: Fix reference leak and gdb tests (GH-131095) (#131120)

(cherry picked from commit ebc24d54bcf554403e9bf4b590d5c1f49e648e0d)

7 months ago[3.13] gh-131113: Fix data race in dict.popitem() (gh-131115) (#131119)
Miss Islington (bot) [Tue, 11 Mar 2025 23:39:29 +0000 (00:39 +0100)] 
[3.13] gh-131113: Fix data race in dict.popitem() (gh-131115) (#131119)

The clearing of the key, hash, and value need to use atomic operations
to avoid a data race with concurrent read operations.
(cherry picked from commit c00ac578241b3213ceb79c1f32bc83ea471f02da)

Co-authored-by: Sam Gross <colesbury@gmail.com>
7 months ago[3.13] gh-130957: Use `sleeping_retry` in `test_free_reference` (GH-130958) (#131091)
Miss Islington (bot) [Tue, 11 Mar 2025 14:14:28 +0000 (15:14 +0100)] 
[3.13] gh-130957: Use `sleeping_retry` in `test_free_reference` (GH-130958) (#131091)

The weak reference may not be immediately dead.
(cherry picked from commit 19081158713526a3042c2ad3c6d5a589579b420f)

Co-authored-by: Sam Gross <colesbury@gmail.com>
7 months ago[3.13] gh-101100: Fix sphinx warnings in `library/asyncio-subprocess.rst` (GH-130994...
Yuki Kobayashi [Tue, 11 Mar 2025 12:30:47 +0000 (21:30 +0900)] 
[3.13] gh-101100: Fix sphinx warnings in `library/asyncio-subprocess.rst` (GH-130994) (#131074)

(cherry picked from commit 7cc99a54b755cc7cc0b3680fde7834cf612d4fbc)

7 months ago[3.13] gh-131082: Add missing guards for WIN32_LEAN_AND_MEAN (GH-131044) (#131084)
Miss Islington (bot) [Tue, 11 Mar 2025 11:56:54 +0000 (12:56 +0100)] 
[3.13] gh-131082: Add missing guards for WIN32_LEAN_AND_MEAN (GH-131044) (#131084)

(cherry picked from commit de8818ae233b8e7722aa5d6f91d4b5a04bd039df)

Co-authored-by: Max Bachmann <kontakt@maxbachmann.de>
7 months ago[3.13] gh-130959: Reject whitespace in fractions, in pure Python `fromisoformat(...
Victor Stinner [Tue, 11 Mar 2025 11:39:27 +0000 (12:39 +0100)] 
[3.13] gh-130959: Reject whitespace in fractions, in pure Python `fromisoformat()` (#130962) (#131076)

gh-130959: Reject whitespace in fractions, in pure Python `fromisoformat()` (#130962)

Fix the pure Python implementation of `fromisoformat()` to reject any
non-digit characters, including whitespace, in the fractional part
of time specification.  This makes the behavior consistent with the C
implementation, and prevents incorrect parsing of these fractions
(e.g. `.400 ` would be misinterpreted as `.04`).

Co-authored-by: Peter Bierma <zintensitydev@gmail.com>
Co-authored-by: Paul Ganssle <1377457+pganssle@users.noreply.github.com>
(cherry picked from commit 33494b4d0dafc34ff4f1c118b7b3b5d8de3dd0f4)

Co-authored-by: Michał Górny <mgorny@gentoo.org>
7 months ago[3.13] gh-93096: Fix loading doctests in test_pickle (GH-131069) (GH-131080)
Miss Islington (bot) [Tue, 11 Mar 2025 10:49:14 +0000 (11:49 +0100)] 
[3.13] gh-93096: Fix loading doctests in test_pickle (GH-131069) (GH-131080)

(cherry picked from commit 3bb20d13a88a178dae809016b3d0a457f38aa686)

Co-authored-by: donBarbos <donbarbos@proton.me>
7 months ago[3.13] gh-130932: cwd cannot be removed on Solaris/Illumos (GH-131037) (#131073)
Miss Islington (bot) [Tue, 11 Mar 2025 09:33:50 +0000 (10:33 +0100)] 
[3.13] gh-130932: cwd cannot be removed on Solaris/Illumos (GH-131037) (#131073)

gh-130932: cwd cannot be removed on Solaris/Illumos (GH-131037)
(cherry picked from commit 69309a55bcb5381a9a218edc910da135f4d67479)

Co-authored-by: Jakub Kulík <Kulikjak@gmail.com>
7 months ago[3.13] gh-117174: Add a new route in linecache to fetch interactive source code ...
Miss Islington (bot) [Mon, 10 Mar 2025 23:11:24 +0000 (00:11 +0100)] 
[3.13] gh-117174: Add a new route in linecache to fetch interactive source code (GH-117500) (#131060)

gh-117174: Add a new route in linecache to fetch interactive source code (GH-117500)
(cherry picked from commit a931a8b32415f311008dbb3f09079aae1e6d7a3d)

Co-authored-by: Pablo Galindo Salgado <Pablogsal@gmail.com>
7 months ago[3.13] gh-125331: Allow the parser to activate future imports on the fly (GH-125482...
Miss Islington (bot) [Mon, 10 Mar 2025 22:20:38 +0000 (23:20 +0100)] 
[3.13] gh-125331: Allow the parser to activate future imports on the fly (GH-125482) (#131062)

gh-125331: Allow the parser to activate future imports on the fly (GH-125482)
(cherry picked from commit 3bd3e09588bfde7edba78c55794a0e28e2d21ea5)

Co-authored-by: Pablo Galindo Salgado <Pablogsal@gmail.com>
7 months ago[3.13] gh-124927: Fix conversion issue between coordinates and position in REPL ...
Miss Islington (bot) [Mon, 10 Mar 2025 22:18:13 +0000 (23:18 +0100)] 
[3.13] gh-124927: Fix conversion issue between coordinates and position in REPL (GH-125001) (#131061)

gh-124927: Fix conversion issue between coordinates and position in REPL (GH-125001)
(cherry picked from commit 6ab5c4aa05bf35832a3ccd1e71b28b8475fa30f4)

Co-authored-by: FeH2 <i@feh2.im>
7 months ago[3.13] gh-131020: py.exe launcher does not correctly detect a BOM when searching...
Miss Islington (bot) [Mon, 10 Mar 2025 19:54:10 +0000 (20:54 +0100)] 
[3.13] gh-131020: py.exe launcher does not correctly detect a BOM when searching for the shebang (GH-131021) (#131047)

gh-131020: py.exe launcher does not correctly detect a BOM when searching for the shebang (GH-131021)
(cherry picked from commit 36ef3bfe39d767e283b55fe86f34e7671b7f5d1c)

Co-authored-by: Chris Eibl <138194463+chris-eibl@users.noreply.github.com>
7 months ago[3.13] gh-130711: Document `PyBaseObject_Type` (GH-130712) (GH-130792)
Miss Islington (bot) [Mon, 10 Mar 2025 14:05:38 +0000 (15:05 +0100)] 
[3.13] gh-130711: Document `PyBaseObject_Type` (GH-130712) (GH-130792)

(cherry picked from commit b3c18bfd828ba90b9c712da74095c4a052887655)

Co-authored-by: Yuki Kobayashi <drsuaimqjgar@gmail.com>
Co-authored-by: Peter Bierma <zintensitydev@gmail.com>
8 months ago[3.13] gh-80421: Correct definitions of time (GH-130984) (#131022)
Miss Islington (bot) [Sun, 9 Mar 2025 20:15:37 +0000 (21:15 +0100)] 
[3.13] gh-80421: Correct definitions of time (GH-130984) (#131022)

gh-80421: Correct definitions of time (GH-130984)

Based on the Wikipedia article, UTC is better said to be a successor than a renaming of GTC and language agnostic rather than an English-French compromise.
(cherry picked from commit 98fa4a49fecbac3c990a25ce5d300592dad31be0)

Co-authored-by: Stan Ulbrych <89152624+StanFromIreland@users.noreply.github.com>
8 months ago[3.13] gh-130160: use `.. program::` directive for documenting `pdb` CLI (GH-130996...
Miss Islington (bot) [Sun, 9 Mar 2025 16:15:41 +0000 (17:15 +0100)] 
[3.13] gh-130160: use `.. program::` directive for documenting `pdb` CLI (GH-130996) (#131014)

gh-130160: use `.. program::` directive for documenting `pdb` CLI (GH-130996)
(cherry picked from commit c240c2d88a080fc3c68c220aa81062cf5f130ab9)

Co-authored-by: donBarbos <donbarbos@proton.me>
8 months ago[3.13] gh-130160: use `.. program::` directive for documenting `webbrowser` CLI ...
Miss Islington (bot) [Sun, 9 Mar 2025 07:03:56 +0000 (08:03 +0100)] 
[3.13] gh-130160: use `.. program::` directive for documenting `webbrowser` CLI (GH-130995) (#131003)

gh-130160: use `.. program::` directive for documenting `webbrowser` CLI (GH-130995)

use `.. program::` directive for documenting `webbrowser` CLI
(cherry picked from commit 92e5f826ace1eab29920a0a3487a3cac7eeab925)

Co-authored-by: donBarbos <donbarbos@proton.me>
8 months ago[3.13] gh-123726: Document caveats of zipfile.Path around name sanitization (GH-13053...
Miss Islington (bot) [Sat, 8 Mar 2025 21:43:12 +0000 (22:43 +0100)] 
[3.13] gh-123726: Document caveats of zipfile.Path around name sanitization (GH-130537) (#130986)

gh-123726: Document caveats of zipfile.Path around name sanitization (GH-130537)

Add a note to the `zipfile.Path` class documentation clarifying that it does not sanitize filenames. This emphasizes the caller's responsibility to validate or sanitize inputs, especially when handling untrusted ZIP archives, to prevent path traversal vulnerabilities. The note also references the `extract` and `extractall` methods for comparison and suggests using `os.path.abspath` and `os.path.commonpath` for safe filename resolution.
(cherry picked from commit a3990df6121880e8c67824a101bb1316de232898)

Co-authored-by: Affan Shaikhsurab <51104750+AffanShaikhsurab@users.noreply.github.com>
8 months ago[3.13] gh-130954: Fix multiprocessing test_notify_n (GH-130955) (#130981)
Miss Islington (bot) [Sat, 8 Mar 2025 18:28:07 +0000 (19:28 +0100)] 
[3.13] gh-130954: Fix multiprocessing test_notify_n (GH-130955) (#130981)

The test could deadlock trying join on the worker processes.
Apply the same technique as gh-130933.

Join the process before the test ends in `test_notify` as well.
(cherry picked from commit edd1eca336976b3431cf636aea87f08a40c94935)

Co-authored-by: Sam Gross <colesbury@gmail.com>
8 months ago[3.13] gh-130851: Only intern constants of types generated by the compiler (GH-130901...
Sam Gross [Sat, 8 Mar 2025 18:07:39 +0000 (13:07 -0500)] 
[3.13] gh-130851: Only intern constants of types generated by the compiler (GH-130901) (#130953)

The free-threading build interns and immortalizes most constants
generated by the bytecode compiler. However, users can construct their
own code objects with arbitrary constants. We should not intern or
immortalize these objects if they are not of a type that we know how to
handle.

This change fixes a reference leak failure in the recently added
`test_code.test_unusual_constants` test. It also addresses a potential
crash that could occur when attempting to destroy an immortalized
object during interpreter shutdown.
(cherry picked from commit 12db45211d411583cbe272c7ba6811a811b721ca)

8 months ago[3.13] gh-130917: update timer and workload in test_signal (GH-130918) (#130969)
Miss Islington (bot) [Sat, 8 Mar 2025 01:05:29 +0000 (02:05 +0100)] 
[3.13] gh-130917: update timer and workload in test_signal (GH-130918) (#130969)

The workload to advance the virtual timeout is too lightweight for some
platforms. As result the test goes in timeout as it never reaches the
end of the timer. By having a heavier workload, the virtual timer
advances rapidly and the SIGVTALRM is sent before the timeout.
(cherry picked from commit 78790811989ab47319e2ee725e0c435b3cdd21ab)

Co-authored-by: Diego Russo <diego.russo@arm.com>
8 months ago[3.13] gh-110206: Fix multiprocessing test_notify_all (GH-130933) (#130950)
Miss Islington (bot) [Fri, 7 Mar 2025 17:22:51 +0000 (18:22 +0100)] 
[3.13] gh-110206: Fix multiprocessing test_notify_all (GH-130933) (#130950)

The test could deadlock trying join on the worker processes due to a
combination of behaviors:

* The use of `assertReachesEventually` did not ensure that workers
  actually woken.release() because the SyncManager's Semaphore does not
  implement get_value.

* This mean that the test could finish and the variable "sleeping" would
  got out of scope and be collected. This unregisters the proxy leading
  to failures in the worker or possibly the manager.

* The subsequent call to `p.join()` during cleanUp therefore never
  finished.

This takes two approaches to fix this:

1) Use woken.acquire() to ensure that the workers actually finish
   calling woken.release()

2) At the end of the test, wait until the workers are finished, while `cond`,
   `sleeping`, and `woken` are still valid.
(cherry picked from commit c476410dc5ae62ffb5e32f64f9a3a622485c7d93)

Co-authored-by: Sam Gross <colesbury@gmail.com>
8 months ago[3.13] Correct function name in `Doc/extending/embedding.rst` (GH-127539) (#130945)
Miss Islington (bot) [Fri, 7 Mar 2025 13:12:44 +0000 (14:12 +0100)] 
[3.13] Correct function name in `Doc/extending/embedding.rst` (GH-127539) (#130945)

Correct function name in `Doc/extending/embedding.rst` (GH-127539)
(cherry picked from commit e5527f2cdda501542bf94179093e1a15d7889b74)

Co-authored-by: Boris Verkhovskiy <boris.verk@gmail.com>
8 months ago[3.13] gh-130932: Fix incorrect exception handling in _PyModule_IsPossiblyShadowing...
Miss Islington (bot) [Fri, 7 Mar 2025 09:28:47 +0000 (10:28 +0100)] 
[3.13] gh-130932: Fix incorrect exception handling in _PyModule_IsPossiblyShadowing (GH-130934) (#130939)

gh-130932: Fix incorrect exception handling in _PyModule_IsPossiblyShadowing (GH-130934)

I chose to not raise an exception here because I think it would be
confusing for module attribute access to start raising something other
than AttributeError if e.g. the cwd goes away

Without the change in moduleobject.c
```
./python.exe -m unittest test.test_import.ImportTests.test_script_shadowing_stdlib_cwd_failure
...
Assertion failed: (PyErr_Occurred()), function _PyObject_SetAttributeErrorContext, file object.c, line 1253.
```
(cherry picked from commit 0a9ae5ed48e6ea078f67ba03635c1c26209b5def)

Co-authored-by: Shantanu <12621235+hauntsaninja@users.noreply.github.com>
8 months ago[3.13] gh-128364: Fix flaky `test_concurrent_futures.test_wait` tests (gh-130742...
Sam Gross [Thu, 6 Mar 2025 18:49:03 +0000 (13:49 -0500)] 
[3.13] gh-128364: Fix flaky `test_concurrent_futures.test_wait` tests (gh-130742) (#130922)

Use events instead of relying on `time.sleep()`. The tests are also now about
four times faster.
(cherry picked from commit c4d37eefb7b33f10f776183447af44faf8efa7f6)

8 months ago[3.13] gh-130851: Don't crash when deduping unusual code constants (GH-130853) (...
Miss Islington (bot) [Wed, 5 Mar 2025 20:22:57 +0000 (21:22 +0100)] 
[3.13] gh-130851: Don't crash when deduping unusual code constants (GH-130853) (#130880)

The bytecode compiler only generates a few different types of constants,
like str, int, tuple, slices, etc. Users can construct code objects with
various unusual constants, including ones that are not hashable or not
even constant.

The free threaded build previously crashed with a fatal error when
confronted with these constants. Instead, treat distinct objects of
otherwise unhandled types as not equal for the purposes of deduplication.
(cherry picked from commit 2905690a91bf72cdf0fb919b5193849bb67732e2)

Co-authored-by: Sam Gross <colesbury@gmail.com>
8 months ago[3.13] gh-127371 Avoid unbounded growth SpooledTempfile.writelines (GH-127372) (...
Miss Islington (bot) [Wed, 5 Mar 2025 17:42:55 +0000 (18:42 +0100)] 
[3.13] gh-127371 Avoid unbounded growth SpooledTempfile.writelines (GH-127372) (#130886)

gh-127371 Avoid unbounded growth SpooledTempfile.writelines (GH-127372)
(cherry picked from commit cb67b44ca92f9930b3aa2aba8420c89d12a25303)

Co-authored-by: Bert Peters <bert@bertptrs.nl>
8 months ago[3.13] Update links from typing.readthedocs.io to typing.python.org (GH-130877) ...
Miss Islington (bot) [Wed, 5 Mar 2025 15:34:17 +0000 (16:34 +0100)] 
[3.13] Update links from typing.readthedocs.io to typing.python.org (GH-130877) (#130883)

Update links from typing.readthedocs.io to typing.python.org (GH-130877)
(cherry picked from commit 4f6218959e35f649061484cce9de7fc810586533)

Co-authored-by: Sebastian Rittau <srittau@rittau.biz>
8 months ago[3.13] gh-116742: Fix subprocess test_check_output_timeout() (GH-130836) (#130873)
Miss Islington (bot) [Wed, 5 Mar 2025 12:01:06 +0000 (13:01 +0100)] 
[3.13] gh-116742: Fix subprocess test_check_output_timeout() (GH-130836) (#130873)

gh-116742: Fix subprocess test_check_output_timeout() (GH-130836)

Fix a race condition in test_check_output_timeout() of
test_subprocess. Don't write into stdout anymore, since there is no
reliable way to synchronize the parent and the child processes.

Change the timeout from 3 seconds to 0.1 seconds, and remove
@requires_resource('walltime') decorator.
(cherry picked from commit 67a942d4272145ccdbdf4ceff31318e176f71355)

Co-authored-by: Victor Stinner <vstinner@python.org>
8 months ago[3.13] gh-130824: Add tests for `NULL` in `PyLong_*AndOverflow` functions (GH-130828...
Miss Islington (bot) [Wed, 5 Mar 2025 11:51:52 +0000 (12:51 +0100)] 
[3.13] gh-130824: Add tests for `NULL` in `PyLong_*AndOverflow` functions (GH-130828) (GH-130869)

(cherry picked from commit 90130807d9c5a55b2a64024f5dfbee4785b9a27c)

Co-authored-by: Peter Bierma <zintensitydev@gmail.com>
Co-authored-by: Sergey B Kirpichev <skirpichev@gmail.com>
8 months ago[3.13] gh-130547: Fix race between dict_dealloc and split_keys_entry_added (gh-130778...
Miss Islington (bot) [Wed, 5 Mar 2025 01:41:29 +0000 (02:41 +0100)] 
[3.13] gh-130547: Fix race between dict_dealloc and split_keys_entry_added (gh-130778) (gh-130833)

gh-130547: Fix race between dict_dealloc and split_keys_entry_added (gh-130778)
(cherry picked from commit 80e6d3ec4972220587c8b883161311a49ea8d0ff)

Co-authored-by: Donghee Na <donghee.na@python.org>
8 months ago[3.13] GH-125722: Increase minimum supported Sphinx to 8.2.0 (GH-130444) (#130858)
Miss Islington (bot) [Wed, 5 Mar 2025 00:37:14 +0000 (01:37 +0100)] 
[3.13] GH-125722: Increase minimum supported Sphinx to 8.2.0 (GH-130444) (#130858)

GH-125722: Increase minimum supported Sphinx to 8.2.0 (GH-130444)
(cherry picked from commit e53d105872fafa77507ea33b7ecf0faddd4c3b60)

Co-authored-by: Adam Turner <9087854+AA-Turner@users.noreply.github.com>
8 months ago[3.13] gh-130794: Process interpreter QSBR queue in _PyMem_AbandonDelayed. (gh-130808...
Sam Gross [Tue, 4 Mar 2025 23:35:22 +0000 (18:35 -0500)] 
[3.13] gh-130794: Process interpreter QSBR queue in _PyMem_AbandonDelayed. (gh-130808) (#130857)

This avoids a case where the interpreter's queue of memory to be freed
could grow rapidly if there are many short lived threads.
(cherry picked from commit 2f6e0e9f7001769be746ee96356656d3ebdc7f96)

8 months ago[3.13] gh-130730: Fix multiprocessing test_active_children() (GH-130837) (#130845)
Miss Islington (bot) [Tue, 4 Mar 2025 17:28:33 +0000 (18:28 +0100)] 
[3.13] gh-130730: Fix multiprocessing test_active_children() (GH-130837) (#130845)

gh-130730: Fix multiprocessing test_active_children() (GH-130837)

Replace a sleep with an event: sleep is not a reliable
synchronization primitive.
(cherry picked from commit 3dd3675492a3fc3b7996613ef75a9044ee7449b0)

Co-authored-by: Victor Stinner <vstinner@python.org>
8 months ago[3.13] gh-130727: Retry test_wmi on TimeoutError (GH-130832) (#130839)
Miss Islington (bot) [Tue, 4 Mar 2025 15:31:22 +0000 (16:31 +0100)] 
[3.13] gh-130727: Retry test_wmi on TimeoutError (GH-130832) (#130839)

gh-130727: Retry test_wmi on TimeoutError (GH-130832)

Use sleeping_retry() in test_wmi to retry multiple times on
TimeoutError. Wait up to LONG_TIMEOUT seconds (5 minutes by default).
(cherry picked from commit f67ff9e82071b21c1960401aed4844b00b5bfb53)

Co-authored-by: Victor Stinner <vstinner@python.org>
8 months ago[3.13] gh-129567: Add a note to `typing.TypedDict` docs about name mangling (GH-13023...
Miss Islington (bot) [Tue, 4 Mar 2025 15:21:11 +0000 (16:21 +0100)] 
[3.13] gh-129567: Add a note to `typing.TypedDict` docs about name mangling (GH-130233) (#130841)

gh-129567: Add a note to `typing.TypedDict` docs about name mangling (GH-130233)
(cherry picked from commit 63ffb406bb000a42b0dbddcfc01cb98a12f8f76a)

Co-authored-by: sobolevn <mail@sobolevn.me>
8 months ago[3.13] gh-130736: Fix asyncio test_shutdown_default_executor_timeout() (GH-130800...
Miss Islington (bot) [Tue, 4 Mar 2025 12:11:31 +0000 (13:11 +0100)] 
[3.13] gh-130736: Fix asyncio test_shutdown_default_executor_timeout() (GH-130800) (#130825)

gh-130736: Fix asyncio test_shutdown_default_executor_timeout() (GH-130800)

Replace time.sleep() with threading.Event.
(cherry picked from commit 6c48ed7d62c6ca0eb24935b0e612f9e4a1a3b1bc)

Co-authored-by: Victor Stinner <vstinner@python.org>
8 months ago[3.13] gh-130737: Fix multiprocessing test_notify() (GH-130797) (#130802)
Miss Islington (bot) [Mon, 3 Mar 2025 19:09:34 +0000 (20:09 +0100)] 
[3.13] gh-130737: Fix multiprocessing test_notify() (GH-130797) (#130802)

gh-130737: Fix multiprocessing test_notify() (GH-130797)

Replace hardcoded delay (100 ms) with a loop awaiting until a
condition is true: replace assertReturnsIfImplemented() with
assertReachesEventually().

Use sleeping_retry() in assertReachesEventually() to tolerate slow
buildbots and raise an exception on timeout (30 seconds).
(cherry picked from commit 8a64a62002fa3cdc93cb4cfee315edb235cad8cb)

Co-authored-by: Victor Stinner <vstinner@python.org>
8 months ago[3.13] gh-128388: pyrepl on Windows: add meta and ctrl+arrow keybindings (GH-128389...
Miss Islington (bot) [Mon, 3 Mar 2025 15:57:53 +0000 (16:57 +0100)] 
[3.13] gh-128388: pyrepl on Windows: add meta and ctrl+arrow keybindings (GH-128389) (GH-130500)

gh-128388: pyrepl on Windows: add meta and ctrl+arrow keybindings (GH-128389)

Fix `Lib/_pyrepl/windows_console.py` to support more keybindings, like the
`Ctrl`+`←` and `Ctrl`+`→` word-skipping keybindings and those with meta (i.e. Alt),
e.g. to `kill-word` or `backward-kill-word`.

Specifics: if Ctrl is pressed, emit "ctrl left" and "ctrl right" instead of just "left" or
"right," and if Meta/Alt is pressed, emit the special key code for meta before
emitting the other key that was pressed.
(cherry picked from commit 688f3a0d4b94874ff6d72af3baafd8bbf911153e)

Co-authored-by: Paulie Peña <203125+paulie4@users.noreply.github.com>
Co-authored-by: Hugo van Kemenade <1324225+hugovk@users.noreply.github.com>
Co-authored-by: Pieter Eendebak <pieter.eendebak@gmail.com>
8 months ago[3.13] gh-130379: Fix incorrect zipapp logic to avoid including the target in itself...
Miss Islington (bot) [Mon, 3 Mar 2025 15:20:05 +0000 (16:20 +0100)] 
[3.13] gh-130379: Fix incorrect zipapp logic to avoid including the target in itself (gh-130509) (gh-130791)

gh-130379: Fix incorrect zipapp logic to avoid including the target in itself (gh-130509)
(cherry picked from commit 64ccbbbf367c7510090a6f5faf826a21102a8bc6)

Co-authored-by: Paul Moore <p.f.moore@gmail.com>
8 months ago[3.13] Docs: Fix a misplaced statement in the document for `ServerProxy` (GH-130616...
Miss Islington (bot) [Mon, 3 Mar 2025 14:09:26 +0000 (15:09 +0100)] 
[3.13] Docs: Fix a misplaced statement in the document for `ServerProxy` (GH-130616) (GH-130640)

Docs: Fix a misplaced statement in the document for `ServerProxy` (GH-130616)

The sentence "If an HTTPS URL ..." explains what the parameter means,
so moved it to the paragraph explaining what the other parameters mean.
(cherry picked from commit b26286ca49d87ad8491e411f7b0283b0f15ad5be)

Co-authored-by: Yuki Kobayashi <drsuaimqjgar@gmail.com>
8 months ago[3.13] gh-130740: Move some `stdbool.h` includes after `Python.h` (#130738) (#130756)
Bénédikt Tran [Mon, 3 Mar 2025 12:09:59 +0000 (13:09 +0100)] 
[3.13] gh-130740: Move some `stdbool.h` includes after `Python.h` (#130738) (#130756)

gh-130740: Move some `stdbool.h` includes after `Python.h` (#130738)

Move some `#include <stdbool.h>` after `#include "Python.h"` when `pyconfig.h` is not
included first and when we are in a platform-agnostic context. This is to avoid having
features defined by `stdbool.h` before those decided by `Python.h` (this caused some
build failures when compiling CPython with `zig cc`).

(cherry-picked from commit 214562ed4ddc248b007f718ed92ebcc0c3669611)

---------

Co-authored-by: Hugo Beauzée-Luyssen <hugo@beauzee.fr>
8 months ago[3.13] gh-127667: fix memory leaks in `hashlib` (GH-127668) (#130784)
Bénédikt Tran [Mon, 3 Mar 2025 11:01:01 +0000 (12:01 +0100)] 
[3.13] gh-127667: fix memory leaks in `hashlib` (GH-127668) (#130784)

gh-127667: fix memory leaks in `hashlib` (GH-127668)

- Correctly handle `NULL` values returned by `EVP_MD_CTX_md`.
- Correctly free resources in error branches.
- Consistently suppress `_setException()` return value when needed.
- Collapse `_setException() + return NULL` into a single statement.

(cherry-picked from commit 097846502b7f33cb327d512e2a396acf4f4de46e)

8 months ago[3.13] gh-101100: Fix sphinx warnings in `library/email.errors.rst` (GH-130774) ...
Miss Islington (bot) [Mon, 3 Mar 2025 10:04:51 +0000 (11:04 +0100)] 
[3.13] gh-101100: Fix sphinx warnings in `library/email.errors.rst` (GH-130774) (#130781)

gh-101100: Fix sphinx warnings in `library/email.errors.rst` (GH-130774)
(cherry picked from commit a105f990199f99a352efd481ac039604feceaab5)

Co-authored-by: Yuki Kobayashi <drsuaimqjgar@gmail.com>
8 months ago[3.13] gh-101100: Fix Sphinx documentation warnings in `collections.rst` (GH-130629...
Miss Islington (bot) [Mon, 3 Mar 2025 09:57:28 +0000 (10:57 +0100)] 
[3.13] gh-101100: Fix Sphinx documentation warnings in `collections.rst` (GH-130629) (#130779)

gh-101100: Fix Sphinx documentation warnings in `collections.rst` (GH-130629)
(cherry picked from commit 373eb1b47af6843678c477b237d787c04dda2818)

Co-authored-by: Victorien <65306057+Viicos@users.noreply.github.com>
8 months ago[3.13] gh-129015: Improve disambiguation between `NotImplemented` and `NotImplemented...
Miss Islington (bot) [Mon, 3 Mar 2025 08:29:29 +0000 (09:29 +0100)] 
[3.13] gh-129015: Improve disambiguation between `NotImplemented` and `NotImplementedError` (GH-129562) (#130776)

gh-129015: Improve disambiguation between `NotImplemented` and `NotImplementedError` (GH-129562)

---------

(cherry picked from commit a85eeb97710617404ba7a0fac3b264f586caf70c)

Co-authored-by: Mike Castle <dalgoda+github@gmail.com>
Co-authored-by: Bénédikt Tran <10796600+picnixz@users.noreply.github.com>
Co-authored-by: Adam Turner <9087854+AA-Turner@users.noreply.github.com>
8 months ago[3.13] gh-130637: Add validation for numeric response data in `stat()` method (GH...
Miss Islington (bot) [Sun, 2 Mar 2025 20:28:56 +0000 (21:28 +0100)] 
[3.13] gh-130637: Add validation for numeric response data in `stat()` method (GH-130646) (#130763)

gh-130637: Add validation for numeric response data in `stat()` method (GH-130646)
(cherry picked from commit a42168d316f0c9a4fc5658dab87682dc19054efb)

Co-authored-by: Kanishk Pachauri <itskanishkp.py@gmail.com>
Co-authored-by: Eric V. Smith <ericvsmith@users.noreply.github.com>
8 months ago[3.13] gh-128481: indicate that the default value for `FrameSummary.end_lineno` chang...
Miss Islington (bot) [Sun, 2 Mar 2025 17:22:48 +0000 (18:22 +0100)] 
[3.13] gh-128481: indicate that the default value for `FrameSummary.end_lineno` changed in 3.13 (GH-130755) (#130767)

gh-128481: indicate that the default value for `FrameSummary.end_lineno` changed in 3.13 (GH-130755)

The value taken by `FrameSummary.end_lineno` when passing `end_lineno=None` changed in gh-112097.

Previously, a `end_lineno` could be specified to be `None` directly but since 939fc6d, passing None makes
the constructor use the value of `lineno` instead.
(cherry picked from commit c6513f7a627c8918a5e3f3733fa47d34a94ddff9)

Co-authored-by: Bénédikt Tran <10796600+picnixz@users.noreply.github.com>
8 months ago[3.13] Fix grammar typo in `Doc/c-api/arg.rst` (GH-130741) (#130759)
Miss Islington (bot) [Sun, 2 Mar 2025 11:14:29 +0000 (12:14 +0100)] 
[3.13] Fix grammar typo in `Doc/c-api/arg.rst` (GH-130741) (#130759)

Fix grammar typo in `Doc/c-api/arg.rst` (GH-130741)
(cherry picked from commit 37145cb89fe806377a5e9ed1fdac92dd3a5df2c0)

Co-authored-by: Arijit Kumar Das <arijitkrdas2004@outlook.com>
8 months ago[3.13] Add link in the `importlib.metadata.version()` docs (GH-130739) (#130761)
Miss Islington (bot) [Sun, 2 Mar 2025 10:42:15 +0000 (11:42 +0100)] 
[3.13] Add link in the `importlib.metadata.version()` docs (GH-130739) (#130761)

Add link in the `importlib.metadata.version()` docs (GH-130739)

Link the specification for the returned data makes it clearer what this is
and what the format of the version string can be.
(cherry picked from commit c71e55869e7bc56b2bd04f3055f810026a66c076)

Co-authored-by: Tim Hoffmann <2836374+timhoffm@users.noreply.github.com>
8 months ago[3.13] gh-128481: Improve documentation for `traceback.FrameSummary` (GH-128484)...
Miss Islington (bot) [Sun, 2 Mar 2025 09:48:30 +0000 (10:48 +0100)] 
[3.13] gh-128481: Improve documentation for `traceback.FrameSummary` (GH-128484) (#130753)

* gh-128481: Improve documentation for `traceback.FrameSummary` (GH-128484)

Complete the `traceback.FrameSummary` signature and add missing
documentation for the `colno` and `end_{col,line}no` attributes.
(cherry picked from commit 051f0e5683fec3840fa7fc99723741dd2d701eae)

Co-authored-by: Damien <81557462+Damien-Chen@users.noreply.github.com>
8 months ago[3.13] gh-130160: use `.. program::` directive for documenting `cProfile` CLI (GH...
Miss Islington (bot) [Sat, 1 Mar 2025 20:45:33 +0000 (21:45 +0100)] 
[3.13] gh-130160: use `.. program::` directive for documenting `cProfile` CLI (GH-130314) (#130745)

gh-130160: use `.. program::` directive for documenting `cProfile` CLI (GH-130314)
(cherry picked from commit 5181ddb29f969c1718f3f4f9618c260807b2886c)

Co-authored-by: Apostol Fet <90645107+ApostolFet@users.noreply.github.com>
Co-authored-by: Bénédikt Tran <10796600+picnixz@users.noreply.github.com>
Co-authored-by: Adam Turner <9087854+AA-Turner@users.noreply.github.com>
8 months ago[3.13] gh-130618: Fix parser error when using lambdas inside f-strings (GH-130638...
Pablo Galindo Salgado [Sat, 1 Mar 2025 18:10:03 +0000 (18:10 +0000)] 
[3.13] gh-130618: Fix parser error when using lambdas inside f-strings (GH-130638) (#130642)

(cherry picked from commit e06bebb87e1b33f7251196e1ddb566f528c3fc98)

Signed-off-by: Pablo Galindo <pablogsal@gmail.com>
8 months ago[3.13] Revert "gh-128364: Fix flaky `test_timeout` test (gh-130724)" (gh-130732)...
Miss Islington (bot) [Sat, 1 Mar 2025 17:44:50 +0000 (18:44 +0100)] 
[3.13] Revert "gh-128364: Fix flaky `test_timeout` test (gh-130724)" (gh-130732) (#130734)

Revert "gh-128364: Fix flaky `test_timeout` test (gh-130724)" (gh-130732)

Change broke Android and iOS buildbots that do not have multiprocessing.

This reverts commit cfa0b1dc375e63cde28e61a47108c645b0e74834.
(cherry picked from commit 5221d9ce0e2beb0fe04bed072e1bb448fd522882)

Co-authored-by: Sam Gross <colesbury@gmail.com>
8 months ago[3.13] gh-128364: Fix flaky `test_timeout` test (gh-130724) (gh-130728)
Miss Islington (bot) [Sat, 1 Mar 2025 16:46:58 +0000 (17:46 +0100)] 
[3.13] gh-128364: Fix flaky `test_timeout` test (gh-130724) (gh-130728)

gh-128364: Fix flaky `test_timeout` test (gh-130724)
(cherry picked from commit cfa0b1dc375e63cde28e61a47108c645b0e74834)

Co-authored-by: Sam Gross <colesbury@gmail.com>
8 months ago[3.13] gh-124878: Add temporary TSAN suppression for free_threadstate (gh-130602...
Sam Gross [Fri, 28 Feb 2025 14:53:35 +0000 (09:53 -0500)] 
[3.13] gh-124878: Add temporary TSAN suppression for free_threadstate (gh-130602) (gh-130687)

The race condition with `free_threadstate` and daemon threads exists in
both the free threading and default builds. We were missing a
suppression in the default build.
(cherry picked from commit cc17307faaa248535c65f6a7668e06dc8ef04575)

8 months ago[3.13] gh-130607: Extend and cleanup IPv6 tests (GH-121518) (GH-130679)
Miss Islington (bot) [Fri, 28 Feb 2025 11:41:41 +0000 (12:41 +0100)] 
[3.13] gh-130607: Extend and cleanup IPv6 tests (GH-121518) (GH-130679)

Extend IPv6 tests and made little syntax refactoring
(cherry picked from commit 9f0879baf15fdcf89f1b85cc244d596d4d0f4e47)

Co-authored-by: Ilya Bazhenov <31971067+bazhil@users.noreply.github.com>
8 months ago[3.13] Postpone <stdbool.h> inclusion after Python.h (#130641) (#130675)
Victor Stinner [Fri, 28 Feb 2025 09:40:06 +0000 (10:40 +0100)] 
[3.13] Postpone <stdbool.h> inclusion after Python.h (#130641) (#130675)

Postpone <stdbool.h> inclusion after Python.h (#130641)

Remove inclusions prior to Python.h.

<stdbool.h> will cause <features.h> to be included before Python.h can
define some macros to enable some additional features, causing multiple
types not to be defined down the line.

(cherry picked from commit 830f04b5056db92ba96387db0a778dcd19a39522)

Co-authored-by: Hugo Beauzée-Luyssen <hugo@beauzee.fr>