Commit graph

123992 commits

Author SHA1 Message Date
Adam Turner
c7d6aa5b51
[3.13] GH-121970: Replace custom abstract method directive with the `:abstract:` option (#129311) (#130439)
(cherry picked from commit 30e892473e)
2025-02-22 02:04:54 +00:00
Adam Turner
9dd2cb7438
[3.13] GH-103180: Set a timeout for every job in GitHub Actions (GH-130375) (#130431)
(cherry picked from commit d0a1e5c222)
2025-02-22 02:01:19 +00:00
Miss Islington (bot)
bb4cd89d7a
[3.13] gh-130159: Fix list indentation in collections.abc (GH-130165) (#130437)
gh-130159: Fix list indentation in collections.abc (GH-130165)
(cherry picked from commit 8e96adf453)

Co-authored-by: Adam Turner <9087854+AA-Turner@users.noreply.github.com>
2025-02-22 01:47:18 +00:00
Miss Islington (bot)
ebb02da7b1
[3.13] gh-128446: Skip Windows CI for Unix build system changes (GH-128450) (#130434)
gh-128446: Skip Windows CI for Unix build system changes (GH-128450)
(cherry picked from commit b05fa90b21)

Authored-by: Adam Turner <9087854+aa-turner@users.noreply.github.com>
Co-authored-by: Srinivas Reddy Thatiparthy (తాటిపర్తి శ్రీనివాస్  రెడ్డి) <thatiparthysreenivas@gmail.com>
Co-authored-by: Adam Turner <9087854+aa-turner@users.noreply.github.com>
2025-02-22 01:37:22 +00:00
Hugo van Kemenade
019918a626
[3.13] Convert change detection to a Python script (GH-129627) (#130367)
Co-authored-by: Adam Turner <9087854+AA-Turner@users.noreply.github.com>
Co-authored-by: Sviatoslav Sydorenko (Святослав Сидоренко) <wk.cvs.github@sydorenko.org.ua>
2025-02-22 00:31:45 +00:00
Miss Islington (bot)
8ef89474b9
[3.13] gh-130285: Fix handling of zero or empty counts in random.sample() (gh-130291) (gh-130416) 2025-02-21 17:56:51 +00:00
Miss Islington (bot)
3d88c18303
[3.13] gh-126332: Add tests for _pyrepl.utils (GH-129325) (#130414)
gh-126332: Add tests for _pyrepl.utils (GH-129325)
(cherry picked from commit 0c4248f88e)

Co-authored-by: Pieter Eendebak <pieter.eendebak@gmail.com>
2025-02-21 17:22:42 +00:00
Miss Islington (bot)
8db3eee4cd
[3.13] gh-124234: Improve docs for Mock.reset_mock (GH-124237) (#130408)
Co-authored-by: sobolevn <mail@sobolevn.me>
2025-02-21 14:58:08 +00:00
Miss Islington (bot)
cb8d89d2e4
[3.13] gh-111609: Test end_offset in SyntaxError subclass (GH-127830) (#130407)
Co-authored-by: Nice Zombies <nineteendo19d0@gmail.com>
2025-02-21 16:56:39 +02:00
Miss Islington (bot)
8ce48c8ebc
[3.13] gh-129363: Change regrtest sequential mode output (GH-129476) (#130405)
gh-129363: Change regrtest sequential mode output (GH-129476)

First, write the test name without color. Then, write the test name
and the result with color. Each test is displayed twice.
(cherry picked from commit f1b81c408f)

Co-authored-by: Victor Stinner <vstinner@python.org>
Co-authored-by: Hugo van Kemenade <1324225+hugovk@users.noreply.github.com>
2025-02-21 14:18:32 +00:00
sobolevn
2a978e16d6
[3.13] Add .. versionadded directive to dis CLI options (GH-130267) (#130401)
(cherry picked from commit 9bf73c032f)
2025-02-21 13:14:27 +00:00
Miss Islington (bot)
ea15cefbf7
[3.13] Fix outdated reference link in collections module (gh-130349) (gh-130386) 2025-02-21 00:22:05 +00:00
Miss Islington (bot)
6cd2f356c3
[3.13] gh-129838: Don't redefine _Py_NO_SANITIZE_UNDEFINED (GH-129839) (#130366)
gh-129838: Don't redefine _Py_NO_SANITIZE_UNDEFINED (GH-129839)

Newer GCC versions accept both __attribute__((no_sanitize("undefined")))
and __attribute__((no_sanitize_undefined)) so check that the macro is
not already defined.
(cherry picked from commit 568db400ff)

Co-authored-by: Collin Funk <collin.funk1@gmail.com>
2025-02-20 16:30:46 +00:00
Miss Islington (bot)
38dfe014de
[3.13] Fix phrasing in paragraphs with leading "similar" (GH-121135) (#130364)
Co-authored-by: Rafael Fontenelle <rffontenelle@users.noreply.github.com>
2025-02-20 15:58:16 +00:00
Miss Islington (bot)
2ac25550bd
[3.13] gh-46236: Document PyUnicode_RSplit, PyUnicode_Partition and PyUnicode_RPartition (GH-130191) (#130360)
gh-46236: Document PyUnicode_RSplit, PyUnicode_Partition and PyUnicode_RPartition (GH-130191)
(cherry picked from commit 0f5b82169e)

Co-authored-by: Marc Mueller <30130371+cdce8p@users.noreply.github.com>
Co-authored-by: Petr Viktorin <encukou@gmail.com>
2025-02-20 15:48:13 +00:00
Sam Gross
ef66394677
[3.13] gh-129269: Exclude everything in sys.path in test_coverage_ignore (gh-130133) (gh-130357)
The `test_trace.test_coverage_ignore` test would fail if you had
`setuptools` installed, such as in `~/.local/lib/python3.xxx/site-packages/`.
Ignore everything in `sys.path` when running the test.
(cherry picked from commit 35925e9529)
2025-02-20 15:42:47 +00:00
Miss Islington (bot)
0a992ff383
[3.13] [doc]: Update logging cookbook to mention domain socket configuration in a recipe. (GH-130348) (GH-130351)
(cherry picked from commit 8cbcf51d61)
2025-02-20 14:20:26 +00:00
Miss Islington (bot)
c05d0d8425
[3.13] gh-101100: Fix sphinx warnings in readline.rst (GH-130300) (#130346)
Co-authored-by: Yuki Kobayashi <drsuaimqjgar@gmail.com>
2025-02-20 15:06:33 +02:00
Miss Islington (bot)
d103357785
[3.13] gh-130250: use support.swap_attr() in test and don't assume we're beginning with a clean system state (GH-130342) (#130344)
gh-130250: use support.swap_attr() in test and don't assume we're beginning with a clean system state (GH-130342)
(cherry picked from commit 048ee2d5ec)

Co-authored-by: Irit Katriel <1055913+iritkatriel@users.noreply.github.com>
2025-02-20 11:52:06 +00:00
Miss Islington (bot)
178b2ec81f
[3.13] Fix some ctypes docs typos (GH-130307) (GH-130343)
Fix some ctypes docs typos (GH-130307)
(cherry picked from commit 417372bd43)

Co-authored-by: Alcaro <floating@muncher.se>
2025-02-20 11:05:23 +00:00
Serhiy Storchaka
68c57d6f33
[3.13] gh-127750: Backport some tests for singledispatchmethod (GH-130309) (GH-130340)
(cherry picked from commit 395335d0ff)
(cherry picked from commit 10b32054ad)
2025-02-20 09:49:23 +00:00
Miss Islington (bot)
270ec26c51
[3.13] gh-69001: Convert links to more usable buttons (GH-129591) (#130338)
gh-69001: Convert links to more usable buttons (GH-129591)

In Lib/idlelib/help_about.py, there are 2 links that are not underlined or colored, hence hard to tell that clicking works.  All buttons might get converted to colored and underlined links in the future.
---------
(cherry picked from commit ed831b95a2)

Co-authored-by: Stan Ulbrych <89152624+StanFromIreland@users.noreply.github.com>
Co-authored-by: Terry Jan Reedy <tjreedy@udel.edu>
2025-02-20 08:54:31 +00:00
Miss Islington (bot)
6041dba911
[3.13] gh-130130: Clarify hash=False docs in dataclasses.field (GH-130324) (#130337)
gh-130130: Clarify `hash=False` docs in `dataclasses.field` (GH-130324)
(cherry picked from commit 47ace53995)

Co-authored-by: Sabfo <alpha.sabfo@gmail.com>
2025-02-20 07:51:39 +00:00
Miss Islington (bot)
439cba75d9
[3.13] gh-130293: Ensure test__colorize will pass on dumb terminals. (GH-130333) (#130334)
Ensure colorize tests will run on dumb terminals (or environment with TERM=dumb set)

(cherry picked from commit 1b070060c0)

Co-authored-by: Russell Keith-Magee <russell@keith-magee.com>
2025-02-20 07:12:56 +00:00
Miss Islington (bot)
46237d19d9
[3.13] gh-130250: fix cleanup in test (impacts refleaks runs) (GH-130329) (#130330)
gh-130250: fix cleanup in test (impacts refleaks runs) (GH-130329)
(cherry picked from commit c718c6be0f)

Co-authored-by: Irit Katriel <1055913+iritkatriel@users.noreply.github.com>
2025-02-20 02:00:49 +00:00
Miss Islington (bot)
d172415a4e
[3.13] gh-130250: fix regression in traceback.print_last (GH-130318) (#130325)
gh-130250: fix regression in traceback.print_last (GH-130318)
(cherry picked from commit 6c982aeb54)

Co-authored-by: Irit Katriel <1055913+iritkatriel@users.noreply.github.com>
2025-02-19 22:06:43 +00:00
Miss Islington (bot)
6c92424b94
[3.13] gh-122876: Fix "End of lines" typo (GH-125310) (#130315)
Co-authored-by: za <za@python.or.id>
Co-authored-by: Hugo van Kemenade <1324225+hugovk@users.noreply.github.com>
2025-02-19 21:23:49 +02:00
Tian Gao
094394a380
[3.13] gh-128396: Fix a crash when inline comprehension has the same … (#130311)
[3.13] gh-128396: Fix a crash when inline comprehension has the same local variable as the outside scope (GH-130235)
(cherry picked from commit ccf17323c2)
2025-02-19 17:40:03 +00:00
Miss Islington (bot)
5907cd6829
[3.13] Docs: Upgrade Sphinx to 8.2 (GH-130171) (#130289)
Docs: Upgrade Sphinx to 8.2 (GH-130171)
(cherry picked from commit 736ad664e0)

Co-authored-by: Adam Turner <9087854+AA-Turner@users.noreply.github.com>
2025-02-18 23:51:48 +00:00
sobolevn
57e8b0cbee
[3.13] gh-130160: use option instead of cmdoption in dis.rst (GH-130255) (#130264)
(cherry picked from commit 97d0011e7e)
2025-02-18 13:55:30 +00:00
Miss Islington (bot)
a273543444
[3.13] gh-130160: use .. program:: directive for documenting ensurepip CLI (gh-130253) (gh-130259)
gh-130160: use `.. program::` directive for documenting `ensurepip` CLI (gh-130253)
(cherry picked from commit 8cd7f8bf8d)

Co-authored-by: Kanishk Pachauri <itskanishkp.py@gmail.com>
2025-02-18 12:51:33 +00:00
Miss Islington (bot)
5d83b6c160
[3.13] gh-130230: Fix crash in pow() with only Decimal third argument (GH-130237) (GH-130246)
(cherry picked from commit b93b7e566e)

Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
2025-02-18 13:18:37 +02:00
Miss Islington (bot)
fc1c9f884e
[3.13] gh-130214: Document PyEllipsis_Type (GH-130215) (#130223)
gh-130214: Document `PyEllipsis_Type` (GH-130215)
(cherry picked from commit fc8c99a8ce)

Co-authored-by: Yuki Kobayashi <drsuaimqjgar@gmail.com>
2025-02-17 19:23:42 +03:00
Miss Islington (bot)
d78e113d1b
gh-128703: Fix mimetypes.guess_type for empty Content-Type in registry (GH-128854)
(cherry picked from commit 303043f506)

Co-authored-by: RUANG (James Roy) <longjinyii@outlook.com>
2025-02-17 15:36:49 +00:00
Stan Ulbrych
320316ef7e
[3.13] gh-82045: Correct and deduplicate "isprintable" docs; add test. (GH-130127)
We had the definition of what makes a character "printable" documented in three places, giving two different definitions.
The definition in the comment on `_PyUnicode_IsPrintable` was inverted; correct that.

With that correction, the two definitions turn out to be equivalent -- but to confirm that, you have to go look up, or happen to know, that those are the only five "Other" categories and only three "Separator" categories in the Unicode character database.  That makes it hard for the reader to tell whether they really are the same, or if there's some subtle difference in the intended semantics.

Fix that by cutting the C API docs' and the C comment's copies of the subtle details, in favor of referring to the Python-level docs. That ensures it's explicit that these are all meant to agree, and also lets us concentrate improvements to the wording in one place.

Speaking of which, borrow some ideas from the C comment, along with other tweaks, to hopefully add a bit more clarity to that one newly-centralized copy in the docs.

Also add a thorough test that the implementation agrees with this definition.

Author:    Greg Price <gnprice@gmail.com>

Co-authored-by: Greg Price <gnprice@gmail.com>
(cherry picked from commit 3402e133ef)
2025-02-17 15:02:39 +01:00
Hugo van Kemenade
fefd2c53f2
[3.13] CI: Use ImageOS (ubuntu24) instead of runner.os (Linux) in cache keys (GH-130200) (#130222) 2025-02-17 13:18:30 +00:00
Miss Islington (bot)
1b2cfb73f9
[3.13] gh-130193: Increase test coverage of gettext.c2py (GH-130208) (GH-130217)
(cherry picked from commit fb2d325725)

Co-authored-by: Tomas R <tomas.roun8@gmail.com>
2025-02-17 09:21:00 +00:00
Pieter Eendebak
8f33c7ac17
[3.13] gh-127750: Fix functools.singledispatchmethod() (GH-130029)
Revert gh-107148
2025-02-17 11:12:24 +02:00
Miss Islington (bot)
30ed4523c0
[3.13] gh-86069: Add more PyNumber_InPlacePower() tests (GH-130111) (GH-130211)
Test it with the third argument.
(cherry picked from commit cfe41037eb)

Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
2025-02-17 10:24:59 +02:00
sobolevn
4d941d3fd1
[3.13] gh-129805: Fix bytes annotation in Tools/jit (GH-129806) (#130216)
(cherry picked from commit 422f8e9e02)
2025-02-17 08:21:47 +00:00
Miss Islington (bot)
831695b04c
[3.13] gh-118761: Revert "Improve import time of subprocess (GH-129427)" (GH-130201) (#130204)
gh-118761: Revert "Improve import time of `subprocess` (GH-129427)" (GH-130201)

* Revert "gh-118761: Improve import time of `subprocess` (GH-129427)"

This reverts commit 49f24650e4.
Also known as f502c8f6a6 in 3.13 (PR GH-129447)
Also known as f65aa0d1bf in 3.12 (PR GH-129448)

This caused bugs in the `__del__` finalizer:
 https://github.com/python/cpython/issues/118761#issuecomment-2661504264

---------
(cherry picked from commit ae30646089)

Co-authored-by: Gregory P. Smith <greg@krypto.org>
Co-authored-by: Bénédikt Tran <10796600+picnixz@users.noreply.github.com>
2025-02-16 19:03:32 +00:00
Miss Islington (bot)
2fcad2a47b
[3.13] gh-130179: Fix persistent_{id,load}_attr reference leaks in _pickle (GH-130180) (#130190)
gh-130179: Fix `persistent_{id,load}_attr` reference leaks in `_pickle` (GH-130180)
(cherry picked from commit e7f00cd14f)

Co-authored-by: Sergey Miryanov <sergey.miryanov@gmail.com>
Co-authored-by: Bénédikt Tran <10796600+picnixz@users.noreply.github.com>
2025-02-16 14:22:23 +00:00
Miss Islington (bot)
ff92f6b228
[3.13] gh-130185: Fix unintentionally skipped tests in test_functools (GH-130186) (#130188)
gh-130185: Fix unintentionally skipped tests in `test_functools` (GH-130186)
(cherry picked from commit 73d03005b0)

Co-authored-by: Tomas R <tomas.roun8@gmail.com>
2025-02-16 13:57:27 +00:00
Miss Islington (bot)
945dcb05ce
[3.13] gh-127488: Add tests for Tools/i18n/msgfmt.py (GH-127540) (GH-130182)
(cherry picked from commit 361083b84b)

Co-authored-by: Tomas R <tomas.roun8@gmail.com>
2025-02-16 13:20:49 +00:00
Miss Islington (bot)
5d240c7bb8
[3.13] gh-130177: Fix unintentionally skipped tests in test_gettext (GH-130178) (GH-130183)
(cherry picked from commit 2e8044a4f7)

Co-authored-by: Tomas R <tomas.roun8@gmail.com>
2025-02-16 12:36:23 +00:00
Miss Islington (bot)
5740b95076
[3.13] gh-130169: Fix broken list markup in Doc/c-api/function.rst (GH-130174) (#130175)
gh-130169: Fix broken list markup in `Doc/c-api/function.rst` (GH-130174)
(cherry picked from commit 9837c2a214)

Co-authored-by: Stan Ulbrych <89152624+StanFromIreland@users.noreply.github.com>
2025-02-16 11:01:45 +00:00
Miss Islington (bot)
1a7b8c0f4d
[3.13] gh-130145: fix loop.run_forever when loop is already running (GH-130146) (#130147)
gh-130145: fix `loop.run_forever` when loop is already running (GH-130146)
(cherry picked from commit a545749b0e)

Co-authored-by: Kumar Aditya <kumaraditya@python.org>
2025-02-15 09:55:08 +00:00
Miss Islington (bot)
692d36f1fc
Doc: update term "namespace package" (GH-129251)
(cherry picked from commit e65e9f9062)
2025-02-15 15:10:24 +09:00
Miss Islington (bot)
e5ee784a7c
[3.13] gh-130106: Fix a typo in unittest.mock doc (GH-130107) (#130143)
gh-130106: Fix a typo in unittest.mock doc (GH-130107)
(cherry picked from commit d2e60d8e59)

Co-authored-by: Srinivas Reddy Thatiparthy (తాటిపర్తి శ్రీనివాస్  రెడ్డి) <thatiparthysreenivas@gmail.com>
2025-02-15 03:37:05 +00:00
Andrew Svetlov
7b0543ebe6
[3.13] gh-128308: pass **kwargs to asyncio task_factory (GH-128768) (#130084)
* [3.13] gh-128308: pass `**kwargs` to asyncio task_factory (GH-128768)
(cherry picked from commit 38a9956876)

Co-authored-by: Thomas Grainger <tagrain@gmail.com>
Co-authored-by: Kumar Aditya <kumaraditya@python.org>


---------

Co-authored-by: Thomas Grainger <tagrain@gmail.com>
Co-authored-by: Kumar Aditya <kumaraditya@python.org>
2025-02-14 22:04:17 +05:30