Commit graph

120349 commits

Author SHA1 Message Date
sobolevn
f841099dc0
[3.12] gh-107526: Revert "gh-100357: Convert several functions in bltinsmodule to AC" (GH-107542) (#130371) 2025-02-26 12:27:33 +03:00
Miss Islington (bot)
2592402bba
[3.12] gh-130433: Update documentation for MultipartConversionError (GH-130436) (GH-130566)
(cherry picked from commit b536e37104)

Co-authored-by: Yuki Kobayashi <drsuaimqjgar@gmail.com>
2025-02-26 09:59:19 +01:00
Hugo van Kemenade
e28097682e
[3.12] gh-108303: Fix and move badsyntax_pep3120.py (GH-109513) (#130540)
(cherry picked from commit 4dd47c63a9)

Co-authored-by: Nikita Sobolev <mail@sobolevn.me>
Co-authored-by: Alex Waygood <Alex.Waygood@Gmail.com>
2025-02-26 09:46:12 +02:00
Kanishk Pachauri
ca9e52dac1
[3.12] gh-130461: Remove unnecessary usages of .. index:: directives in Doc/library/uuid.rst (#130526) (#130546)
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>
2025-02-25 15:25:20 +02:00
Bénédikt Tran
b1a188a7fa
[3.12] gh-130151: Fix reference leaks in _hashlib.hmac_{new,digest} (GH-130152) (#130539)
gh-130151: Fix reference leaks in `_hashlib.hmac_{new,digest}` (GH-130152)

* fix leak in `_hashlib.hmac_new`
* fix leak in `hmac_digest`
* fix exception type in `_hashlib.HMAC.copy`
(cherry picked from commit 071820113f)
2025-02-25 12:38:47 +01:00
Miss Islington (bot)
def2ee1280
[3.12] Fix a typo in code module test (GH-130530) (GH-130533)
(cherry picked from commit 56e337d32b)

Co-authored-by: Tian Gao <gaogaotiantian@hotmail.com>
2025-02-25 09:54:15 +00:00
Miss Islington (bot)
e38cded312
[3.12] gh-46236: Add docs for PyUnicode_GetDefaultEncoding() doc (GH-130335) (GH-130512)
* Clarify sys.getdefaultencoding() documentation

* Add missing documentation for PyUnicode_GetDefaultEncoding,
  the C equivalent of sys.getdefaultencoding
(cherry picked from commit 9f25c1f012)

Co-authored-by: RUANG (James Roy) <longjinyii@outlook.com>
2025-02-24 17:10:27 +01:00
Miss Islington (bot)
3c20e8bc3a
[3.12] gh-127522: wsgiref: indicate that start_response objects should follow a specific protocol (GH-127525) (GH-130505)
(cherry picked from commit 39ba4b6619)

Co-authored-by: Bénédikt Tran <10796600+picnixz@users.noreply.github.com>
2025-02-24 15:08:22 +01:00
Miss Islington (bot)
da471d9d79
[3.12] gh-127805: Clarify Formatter initialization in logging.rst. (GH-127850) (#130393)
gh-127805: Clarify Formatter initialization in logging.rst. (GH-127850)
(cherry picked from commit 5d66c55c8a)

Co-authored-by: UV <yuvrajpradhan667@gmail.com>
2025-02-23 23:01:30 -05:00
Miss Islington (bot)
b505d0f609
[3.12] gh-130160: use .. program:: directive for documenting idle CLI (GH-130278) (#130495)
gh-130160: use `.. program::` directive for documenting `idle` CLI (GH-130278)

---------




(cherry picked from commit 0ff1611574)

Co-authored-by: Kanishk Pachauri <itskanishkp.py@gmail.com>
2025-02-23 22:58:42 -05:00
Adam Turner
ac455678e7
[3.12] Docs: Test presence of optional extensions with importlib (GH-130445) (#130466)
* [3.12] Docs: Test presence of optional extensions with importlib (GH-130445)
(cherry picked from commit 3cc9e867eb)

Co-authored-by: Adam Turner <9087854+AA-Turner@users.noreply.github.com>
2025-02-22 21:06:13 +00:00
Adam Turner
9bd92fa241
[3.12] gh-121970: Replace .. coroutine{method,function} with :async: (GH-130448) (#130467)
(cherry picked from commit 5ec4bf86b7)

Co-authored-by: sobolevn <mail@sobolevn.me>
2025-02-22 18:22:29 +00:00
Miss Islington (bot)
6c59ea6f14
[3.12] Add measuring unit to sys.getswitchinterval docs (GH-130457) (#130459)
Add measuring unit to `sys.getswitchinterval` docs (GH-130457)
(cherry picked from commit 89d8b2d14b)

Co-authored-by: sobolevn <mail@sobolevn.me>
2025-02-22 16:13:31 +00:00
Miss Islington (bot)
8559dc3124
[3.12] gh-129712: Document the wheels tags corresponding to each universal SDK. (GH-130389) (#130450)
Document the architectures supported by macOS universal SDK configuration flags,
and add details on wheel tag naming.
(cherry picked from commit 474c388740)

Co-authored-by: Russell Keith-Magee <russell@keith-magee.com>
2025-02-22 08:38:41 +00:00
Adam Turner
35c30608e3
[3.12] GH-121970: Replace custom abstract method directive with the `:abstract:` option (GH-129311) (#130440)
(cherry picked from commit 30e892473e)
2025-02-22 02:11:47 +00:00
Adam Turner
59c3eb48f9
[3.12] GH-103180: Set a timeout for every job in GitHub Actions (GH-130375) (#130432)
(cherry picked from commit d0a1e5c222)
2025-02-22 01:52:41 +00:00
Miss Islington (bot)
f452b81b8d
[3.12] gh-130159: Fix list indentation in collections.abc (GH-130165) (#130438)
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:48:15 +00:00
Adam Turner
7a14c2a6ad
[3.12] gh-128446: Skip Windows CI for Unix build system changes (GH-128450) (#130435)
(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:33:56 +00:00
Miss Islington (bot)
8db2fa2575
[3.12] gh-130285: Fix handling of zero or empty counts in random.sample() (gh-130291) (gh-130417) 2025-02-21 17:48:46 +00:00
Hugo van Kemenade
91e5e246b3
[3.12] Convert change detection to a Python script (GH-129627) (#130370)
Co-authored-by: Adam Turner <9087854+AA-Turner@users.noreply.github.com>
Co-authored-by: Hugo van Kemenade <1324225+hugovk@users.noreply.github.com>
Co-authored-by: Sviatoslav Sydorenko (Святослав Сидоренко) <wk.cvs.github@sydorenko.org.ua>
2025-02-21 17:18:44 +02:00
Miss Islington (bot)
dd5bf313c6
[3.12] gh-129363: Change regrtest sequential mode output (GH-129476) (#130406)
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:16:27 +00:00
Miss Islington (bot)
6c4de3259d
[3.12] Fix outdated reference link in collections module (gh-130349) (gh-130387) 2025-02-21 00:15:48 +00:00
Hugo van Kemenade
546ac0191f
[3.12] Itertool recipe additions (gh-127483) (gh-130362) 2025-02-20 17:32:35 -06:00
Miss Islington (bot)
f314cc4db5
[3.12] gh-129838: Don't redefine _Py_NO_SANITIZE_UNDEFINED (GH-129839) (#130365)
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:20:27 +00:00
Miss Islington (bot)
5c0aba0b81
[3.12] gh-46236: Document PyUnicode_RSplit, PyUnicode_Partition and PyUnicode_RPartition (GH-130191) (#130361)
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:50:37 +00:00
Hugo van Kemenade
ecfca20719
[3.12] gh-119727: Add --single-process option to regrtest (GH-119728) (#130359)
Co-authored-by: Victor Stinner <vstinner@python.org>
2025-02-20 15:47:10 +00:00
Sam Gross
60410f3c76
[3.12] gh-129269: Exclude everything in sys.path in test_coverage_ignore (gh-130133) (gh-130358)
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:37:43 +00:00
Miss Islington (bot)
77cba87472
[3.12] [doc]: Update logging cookbook to mention domain socket configuration in a recipe. (GH-130348) (GH-130352)
(cherry picked from commit 8cbcf51d61)
2025-02-20 14:20:00 +00:00
Miss Islington (bot)
e6c3dd3487
[3.12] gh-101100: Fix sphinx warnings in readline.rst (GH-130300) (#130347)
Co-authored-by: Yuki Kobayashi <drsuaimqjgar@gmail.com>
Co-authored-by: Hugo van Kemenade <1324225+hugovk@users.noreply.github.com>
2025-02-20 15:39:09 +02:00
Miss Islington (bot)
e63ca56e3b
[3.12] gh-127750: Backport some tests for singledispatchmethod (GH-130309) (GH-130340) (GH-130341)
(cherry picked from commit 68c57d6f33)

(cherry picked from commit 395335d0ff)
(cherry picked from commit 10b32054ad)

Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
2025-02-20 12:16:19 +00:00
Miss Islington (bot)
96a914ad7e
[3.12] gh-130250: use support.swap_attr() in test and don't assume we're beginning with a clean system state (GH-130342) (#130345)
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:45:42 +00:00
Miss Islington (bot)
b259b7577f
[3.12] gh-69001: Convert links to more usable buttons (GH-129591) (#130339)
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:49:51 +00:00
Miss Islington (bot)
16a06be016
[3.12] gh-130130: Clarify hash=False docs in dataclasses.field (GH-130324) (#130336)
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:53:58 +00:00
Miss Islington (bot)
4fb2bb6edc
[3.12] gh-130250: fix cleanup in test (impacts refleaks runs) (GH-130329) (#130331)
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 01:54:37 +00:00
Miss Islington (bot)
8d58070d7e
[3.12] gh-130250: fix regression in traceback.print_last (GH-130318) (#130326)
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:01:32 +00:00
Miss Islington (bot)
720de0dc63
[3.12] gh-122876: Fix "End of lines" typo (GH-125310) (#130316)
Co-authored-by: za <za@python.or.id>
Co-authored-by: Hugo van Kemenade <1324225+hugovk@users.noreply.github.com>
2025-02-19 19:24:21 +00:00
Hugo van Kemenade
569615f207
[3.12] CI: Make macOS required to succeed (GH-110362) (#130299)
Co-authored-by: Hugo van Kemenade <hugovk@users.noreply.github.com>
2025-02-19 13:46:45 +02:00
Miss Islington (bot)
43898abd9a
[3.12] Docs: Upgrade Sphinx to 8.2 (GH-130171) (#130288)
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:55:11 +00:00
sobolevn
0931693f95
[3.12] gh-130160: use option instead of cmdoption in dis.rst (GH-130255) (#130265) 2025-02-18 17:18:30 +03:00
Miss Islington (bot)
aeefac90b7
[3.12] gh-130160: use .. program:: directive for documenting ensurepip CLI (gh-130253) (gh-130258)
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:53:02 +00:00
Serhiy Storchaka
4a6415cbac
[3.12] gh-130230: Add new tests for 3-arg pow() with Decimal (GH-130237) (GH-130247)
(cherry picked from commit b93b7e566e)
2025-02-18 08:18:40 +00:00
Miss Islington (bot)
0274115585
[3.12] gh-130214: Document PyEllipsis_Type (GH-130215) (#130224)
gh-130214: Document `PyEllipsis_Type` (GH-130215)
(cherry picked from commit fc8c99a8ce)

Co-authored-by: Yuki Kobayashi <drsuaimqjgar@gmail.com>
2025-02-17 19:24:30 +03:00
Miss Islington (bot)
5af357d27c
[3.12] gh-125741: Update build.yml for the new check_autoconf_regen job (GH-125772) (#130229)
Co-authored-by: Adam Turner <9087854+AA-Turner@users.noreply.github.com>
2025-02-17 18:01:27 +02:00
Hugo van Kemenade
3d86e659b2
[3.12] CI: Use ImageOS (ubuntu24) instead of runner.os (Linux) in cache keys (GH-130200) (#130226) 2025-02-17 13:42:19 +00:00
Stan Ulbrych
8a598fb623
[3.12] gh-82045: Correct and deduplicate "isprintable" docs; add test. (GH-130125)
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.

Co-authored-by: Greg Price <gnprice@gmail.com>
(cherry picked from commit 3402e133ef)
2025-02-17 14:07:59 +01:00
Miss Islington (bot)
fc1c35f44d
[3.12] gh-130193: Increase test coverage of gettext.c2py (GH-130208) (GH-130218)
(cherry picked from commit fb2d325725)

Co-authored-by: Tomas R <tomas.roun8@gmail.com>
2025-02-17 09:14:13 +00:00
Miss Islington (bot)
ad38c3c2b6
[3.12] gh-86069: Add more PyNumber_InPlacePower() tests (GH-130111) (GH-130212)
Test it with the third argument.
(cherry picked from commit cfe41037eb)

Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
2025-02-17 10:25:20 +02:00
Miss Islington (bot)
042b49246b
[3.12] gh-118761: Revert "Improve import time of subprocess (GH-129427)" (GH-130201) (#130205)
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 18:56:18 +00:00
Miss Islington (bot)
4f09a85aca
[3.12] gh-130185: Fix unintentionally skipped tests in test_functools (GH-130186) (#130189)
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:52:55 +00:00
Miss Islington (bot)
5e44d39ba1
[3.12] gh-127488: Add tests for Tools/i18n/msgfmt.py (GH-127540) (GH-130181)
(cherry picked from commit 361083b84b)

Co-authored-by: Tomas R <tomas.roun8@gmail.com>
2025-02-16 13:14:50 +00:00