Commit graph

124288 commits

Author SHA1 Message Date
Miss Islington (bot)
e0aefbd263
gh-133597: Fix memory leak if error occurred in _sys_getwindowsversion_from_kernel32 (GH-133598)
(cherry picked from commit 0ec8fc83a8)

Co-authored-by: Sergey Miryanov <sergey.miryanov@gmail.com>
2025-05-08 11:32:59 +00:00
TERESH1
a719e5fbb6
[3.13] gh-133516: Raise ValueError when constants True, False or None are used as an identifier after NFKC normalization (GH-133523) (#133615) 2025-05-08 12:18:26 +01:00
Miss Islington (bot)
eefe7e22b8
[3.13] Doc: Allow translating a code block in the tutorial (GH-131353) (#133649)
Doc: Allow translating a code block in the tutorial (GH-131353)
(cherry picked from commit 3224b99872)

Co-authored-by: Stan Ulbrych <89152624+StanFromIreland@users.noreply.github.com>
Co-authored-by: Chris Markiewicz <effigies@gmail.com>
Co-authored-by: Adam Turner <9087854+AA-Turner@users.noreply.github.com>
2025-05-08 09:29:34 +00:00
Miss Islington (bot)
a0dd4f0c56
[3.13] gh-133639: Fix test_auto_indent_default() doesn't run input_code (GH-133640) (#133647) 2025-05-08 08:47:38 +00:00
sobolevn
aed613fe2f
[3.13] gh-133403: Type Tools/build/update_file.py and check it with mypy (GH-133404) (#133637)
(cherry picked from commit 50b52cba2d)
2025-05-08 06:59:04 +00:00
Miss Islington (bot)
a063d6c794
[3.13] gh-127833: lexical analysis: Add backticks to BOM example (GH-132407) (#133633)
gh-127833: lexical analysis: Add backticks to BOM example (GH-132407)
(cherry picked from commit 0552ce0fb2)

Co-authored-by: Stan Ulbrych <89152624+StanFromIreland@users.noreply.github.com>
2025-05-08 01:42:05 +00:00
Miss Islington (bot)
6beec6c813
[3.13] gh-133361: move the explanation of dict equal before its use (GH-133424) (#133621)
gh-133361: move the explanation of dict equal before its use (GH-133424)

Also move up the explanation of insertion order preservation.  Both paragraphs seemed out of place down where they were.
---------
(cherry picked from commit 61ac88c06e)

Co-authored-by: Yongzi Li <1538321957@qq.com>
Co-authored-by: Terry Jan Reedy <tjreedy@udel.edu>
2025-05-07 22:11:03 +00:00
Miss Islington (bot)
ce9d708e8c
[3.13] gh-131535: Fix stale example in html.parser docs, make examples doctests (GH-131551) (GH-133587)
(cherry picked from commit ee76e36d76)

Co-authored-by: Brian Schubert <brianm.schubert@gmail.com>
2025-05-07 20:33:23 +03:00
Steve Dower
ac99d7e5cc
gh-133512: Adds warnings to py.exe launcher about subcommands belonging to Python install manager (GH-133514) 2025-05-07 13:24:33 +01:00
Brandt Bucher
3f93295bbe
[3.13] GH-133231: Backport PYTHON_JIT documentation to 3.13 (GH-133539) 2025-05-06 21:31:54 +00:00
Victor Stinner
d4f6367b8e
[3.13] gh-132921: Fix setuptools._distutils.dep_util deprecation (#133522)
gh-132921: Fix setuptools._distutils.dep_util deprecation

Get newer_group from setuptools.modified on recent setuptools
versions, but keep support for old setuptools versions.
2025-05-06 20:40:36 +02:00
Miss Islington (bot)
fe18437089
[3.13] gh-130117: Document why nested Union, Literal, and Annotated types referenced through a type alias are not flattened (GH-130119) (#133488)
gh-130117: Document why nested `Union`, `Literal`, and `Annotated` types referenced through a type alias are not flattened (GH-130119)

(cherry picked from commit b936ccdb6f)

Co-authored-by: Valentin Berlier <berlier.v@gmail.com>
Co-authored-by: Jelle Zijlstra <jelle.zijlstra@gmail.com>
2025-05-06 02:13:22 +00:00
Stan Ulbrych
1dfe5def08
[3.13] gh-132017: Handle SIGCONT in pyrepl (#132918) (#133470) 2025-05-05 23:13:08 +02:00
Łukasz Langa
891232f338
[3.13] gh-131878: Fix input of unicode characters with two or more code points in new pyrepl on Windows (gh-131901) (gh-133468)
(cherry picked from commit 0c5151bc81)

Co-authored-by: Sergey Miryanov <sergey.miryanov@gmail.com>
Co-authored-by: Tomas R. <tomas.roun8@gmail.com>
Co-authored-by: Chris Eibl <138194463+chris-eibl@users.noreply.github.com>
2025-05-05 23:08:09 +02:00
Łukasz Langa
76f52c434c
[3.13] gh-130804: Fix support of typing unicode chars in pyrepl (GH-130805) (GH-133462)
(cherry picked from commit 7c98b0674d)

Co-authored-by: Sergey Miryanov <sergey.miryanov@gmail.com>
2025-05-05 21:39:21 +02:00
Łukasz Langa
e4d68488bc
[3.13] GH-132439: Fix REPL swallowing characters entered with AltGr on cmd.exe (GH-132440) (GH-133460)
(cherry picked from commit 07f416a3f0)

Co-authored-by: Chris Eibl <138194463+chris-eibl@users.noreply.github.com>
Co-authored-by: Stan Ulbrych <89152624+StanFromIreland@users.noreply.github.com>
2025-05-05 20:09:34 +02:00
Miss Islington (bot)
a2bf7a0a47
[3.13] gh-124096: Enable REPL virtual terminal support on Windows (GH-124119) (GH-133457)
To support virtual terminal mode in Windows PYREPL, we need a scanner
to read over the supported escaped VT sequences.

Windows REPL input was using virtual key mode, which does not support
terminal escape sequences. This patch calls `SetConsoleMode` properly
when initializing and send sequences to enable bracketed-paste modes
to support verbatim copy-and-paste.
(cherry picked from commit a65366ed87)

Co-authored-by: Y5 <124019959+y5c4l3@users.noreply.github.com>
Signed-off-by: y5c4l3 <y5c4l3@proton.me>
Co-authored-by: Petr Viktorin <encukou@gmail.com>
Co-authored-by: Pablo Galindo Salgado <Pablogsal@gmail.com>
Co-authored-by: Dustin L. Howett <dustin@howett.net>
Co-authored-by: wheeheee <104880306+wheeheee@users.noreply.github.com>
2025-05-05 19:39:06 +02:00
Miss Islington (bot)
1105ed316b
[3.13] GH-133410: Use commit hashes for change detection (gh-133416) (#133427)
GH-133410: Use commit hashes for change detection (gh-133416)
(cherry picked from commit d530e74e44)

Co-authored-by: Adam Turner <9087854+AA-Turner@users.noreply.github.com>
2025-05-05 10:26:58 -07:00
Miss Islington (bot)
d84a762a64
[3.13] gh-63882: Break down and tests in test_minidom (GH-133026) (#133451)
Co-authored-by: Stan Ulbrych <89152624+StanFromIreland@users.noreply.github.com>
2025-05-05 19:31:53 +03:00
Łukasz Langa
87b14c8f21
[3.13] gh-131878: Handle top level exceptions in new pyrepl and prevent of closing it (GH-131910) (GH-133445)
Co-authored-by: Sergey Miryanov <sergey.miryanov@gmail.com>
2025-05-05 17:20:54 +02:00
Miss Islington (bot)
f371b23bab
[3.13] gh-107006: Move threading.local docstring to docs (GH-131840) (#133432)
Co-authored-by: Lysandros Nikolaou <lisandrosnik@gmail.com>
Co-authored-by: Hugo van Kemenade <1324225+hugovk@users.noreply.github.com>
2025-05-05 16:18:00 +03:00
Miss Islington (bot)
df1669ed20
[3.13] Bump mypy to 1.15 (GH-133405) (#133429)
Bump mypy to 1.15 (GH-133405)
(cherry picked from commit 8467026ed6)

Co-authored-by: sobolevn <mail@sobolevn.me>
2025-05-05 10:54:56 +00:00
Miss Islington (bot)
e89ca3991c
[3.13] [tests] test_subprocess maybe avoid a timeout race condition? (GH-133420) (#133421)
[tests] test_subprocess maybe avoid a timeout race condition? (GH-133420)

The few buildbot failures on https://github.com/python/cpython/pull/133103
are possibly just due to racing a child process launch and exit?
(cherry picked from commit b64aa302d7)

Co-authored-by: Gregory P. Smith <greg@krypto.org>
2025-05-05 04:25:41 +00:00
Miss Islington (bot)
3d1b8e2a96
[3.13] gh-133089: Use original timeout value for TimeoutExpired when the func subprocess.run is called with a timeout (GH-133103) (#133418)
gh-133089: Use original timeout value for `TimeoutExpired` when the func `subprocess.run` is called with a timeout (GH-133103)
(cherry picked from commit 2bbcaedb75)

Signed-off-by: Manjusaka <me@manjusaka.me>
Co-authored-by: Nadeshiko Manju <me@manjusaka.me>
Co-authored-by: Gregory P. Smith <greg@krypto.org>
2025-05-05 01:38:30 +00:00
Miss Islington (bot)
5daeebbbf2
[3.13] gh-109700: Improve stress tests for interpreter creation (GH-109946) (GH-133391)
* Ensure that destructors are called in the test that created interpreters, not after finishing it.
* Try to create/run interpreters in threads simultaneously.
* Mark tests that requires over 6GB of memory with bigmemtest.
(cherry picked from commit 61b50a98b4)

Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
2025-05-04 19:18:49 +00:00
Serhiy Storchaka
973e2d3e29
[3.13] gh-122559: Synchronize C and Python implementation of the io module about pickling (GH-122628) (GH-133381)
In the C implementation, remove __reduce__ and __reduce_ex__ methods
that always raise TypeError and restore __getstate__ methods that always
raise TypeErrori.

This restores fine details of the pre-3.12 behavior and unifies
both implementations.
(cherry picked from commit e9253ebf74)
2025-05-04 16:04:09 +00:00
Serhiy Storchaka
3c9d1778ef
[3.13] bpo-44172: Keep reference to original window in curses subwindow objects (GH-26226) (GH-133370)
The X/Open curses specification[0] and ncurses documentation[1]
both state that subwindows must be deleted before the main window.

Deleting the windows in the wrong order causes a double-free with
NetBSD's curses implementation.

To fix this, keep track of the original window object in the subwindow
object, and keep a reference to the original for the lifetime of
the subwindow.

[0] https://pubs.opengroup.org/onlinepubs/7908799/xcurses/delwin.html
[1] https://invisible-island.net/ncurses/man/curs_window.3x.html
(cherry picked from commit 0af61fe2f4)

Co-authored-by: Michael Forney <mforney@mforney.org>
2025-05-04 11:15:43 +00:00
Miss Islington (bot)
e090f8e3f5
[3.13] gh-133210: Fix test_rlcompleter in --without-doc-strings mode (GH-133332) (#133348)
gh-133210: Fix `test_rlcompleter` in `--without-doc-strings` mode (GH-133332)
(cherry picked from commit 881144fa58)

Co-authored-by: sobolevn <mail@sobolevn.me>
2025-05-03 16:01:36 +00:00
Miss Islington (bot)
85252236b1
[3.13] gh-133117: Enable stricter mypy checks for tomllib (GH-133206) (#133343)
gh-133117: Enable stricter mypy checks for `tomllib` (GH-133206)
(cherry picked from commit cb3174113e)

Co-authored-by: sobolevn <mail@sobolevn.me>
2025-05-03 14:20:34 +00:00
Hugo van Kemenade
130491f6cc
[3.13] gh-130160: use .. program:: directive for documenting platform CLI (GH-133335) (#133341)
Co-authored-by: Semyon Moroz <donbarbos@proton.me>
2025-05-03 15:37:09 +03:00
Miss Islington (bot)
c9c0beb00d
[3.13] gh-114713: Revert gh-114731 (GH-133330) (#133331)
gh-114713: Revert gh-114731 (GH-133330)

Revert "gh-114713: Handle case of an empty string passed to `zoneinfo.ZoneInfo` (GH-114731)"

This reverts commit 884df116d7.
(cherry picked from commit fe44fc4f43)

Co-authored-by: Kirill Podoprigora <kirill.bast9@mail.ru>
2025-05-03 08:09:54 +00:00
Miss Islington (bot)
bb0a8575a7
gh-91156: Document how TextIOWrapper interacts with UTF-8 mode (GH-132885)
Document how TextIOWrapper interacts with UTF-8 mode
(cherry picked from commit 245cd6c532)

Co-authored-by: Malcolm Smith <smith@chaquo.com>
2025-05-03 11:38:35 +09:00
Miss Islington (bot)
8a05dbe004
[3.13] gh-132995: Upgrade bundled pip to 25.1.1 (gh-133308)
gh-132995: Upgrade bundled pip to 25.1.1 (gh-132997)

* gh-132995: Upgrade bundled pip to 25.1.1
(cherry picked from commit a512905e15)

Co-authored-by: Paul Moore <p.f.moore@gmail.com>
2025-05-02 18:26:38 +01:00
Miss Islington (bot)
e2ad2c8042
[3.13] gh-112936: Fix IDLE: no Shell menu item in single-process mode (GH-126598) (GH-133310)
(cherry picked from commit 7e7e49be78)

Co-authored-by: Zhikang Yan <2951256653@qq.com>
2025-05-02 17:26:26 +00:00
Miss Islington (bot)
e75f528e78
[3.13] gh-133290: Use PyObject_SetAttr to set _type_ (GH-133292) (GH-133295)
gh-133290: Use PyObject_SetAttr to set _type_ (GH-133292)
(cherry picked from commit 2590774c9b)

Co-authored-by: Petr Viktorin <encukou@gmail.com>
2025-05-02 18:10:32 +02:00
Miss Islington (bot)
16e9e74a8b
[3.13] gh-132385: Fix instance error suggestions trigger potential exceptions in traceback (GH-132387) (#133297)
gh-132385: Fix instance error suggestions trigger potential exceptions in `traceback` (GH-132387)
(cherry picked from commit 641253cfac)

Co-authored-by: sobolevn <mail@sobolevn.me>
2025-05-02 13:27:54 +00:00
Miss Islington (bot)
6a919d0488
[3.13] gh-133210: Fix test_descr in --without-doc-strings mode (GH-133294) (#133298)
gh-133210: Fix `test_descr` in `--without-doc-strings` mode (GH-133294)
(cherry picked from commit ba16ba3a18)

Co-authored-by: sobolevn <mail@sobolevn.me>
2025-05-02 13:27:30 +00:00
Miss Islington (bot)
b225ce7744
[3.13] Docs: delete title links in turtle.rst and typing.rst (GH-133283) (#133293)
Co-authored-by: Yongzi Li <1538321957@qq.com>
Co-authored-by: Alex Waygood <Alex.Waygood@Gmail.com>
2025-05-02 13:24:12 +01:00
Miss Islington (bot)
b64cc74b14
[3.13] gh-133210: Fix test_pydoc in --without-doc-strings mode (GH-133271) (#133288)
gh-133210: Fix `test_pydoc` in `--without-doc-strings` mode (GH-133271)
(cherry picked from commit 4912b29166)

Co-authored-by: sobolevn <mail@sobolevn.me>
2025-05-02 10:36:35 +00:00
Tomas R.
ae775dcc24
[3.13] gh-130197: Improve test coverage of msgfmt.py (GH-133048) (GH-133255)
(cherry picked from commit c73d46076e)
2025-05-02 07:28:28 +00:00
Miss Islington (bot)
766c5f75b9
[3.13] gh-119605: Respect follow_wrapped for __init__ and __new__ when getting class signature with inspect.signature (GH-132055) (#133277)
gh-119605: Respect `follow_wrapped` for `__init__` and `__new__` when getting class signature with `inspect.signature` (GH-132055)
(cherry picked from commit b8633f9aca)

Co-authored-by: Xuehai Pan <XuehaiPan@pku.edu.cn>
2025-05-01 20:06:07 -07:00
Miss Islington (bot)
f7d1109a12
[3.13] gh-133210: Fix test_inspect in --without-doc-strings mode (GH-133250) (#133263)
gh-133210: Fix `test_inspect` in `--without-doc-strings` mode (GH-133250)
(cherry picked from commit 27e011455d)

Co-authored-by: sobolevn <mail@sobolevn.me>
2025-05-01 16:36:12 +00:00
Miss Islington (bot)
90c786e377
[3.13] gh-130655: Add a test for big-endian MO files in gettext (GH-132469) (GH-133248)
(cherry picked from commit 474f296718)

Co-authored-by: Tomas R <tomas.roun8@gmail.com>
2025-05-01 11:36:06 +00:00
Miss Islington (bot)
679e632c5e
[3.13] gh-132246: Add PEP 688 to C Buffer Protocol docs (GH-132249) (#132282)
gh-132246: Add PEP 688 to C Buffer Protocol docs (GH-132249)
(cherry picked from commit 8421b648e9)

Co-authored-by: Cody Maloney <cmaloney@users.noreply.github.com>
2025-05-01 12:09:33 +01:00
Miss Islington (bot)
bf8eecdca7
[3.13] gh-131531: Make Android build retry after network failures (GH-133193) (#133236)
Adds a retry strategy when downloading compilation resources for Android, plus some other cleanups.
(cherry picked from commit feac343d1a)

Co-authored-by: Malcolm Smith <smith@chaquo.com>
2025-05-01 04:41:44 +00:00
Miss Islington (bot)
f68be0f38e
[3.13] gh-133183: Include IPHONEOS_DEPLOYMENT_TARGET in iOS shim targets. (GH-133184) (#133234)
Include IPHONEOS_DEPLOYMENT_TARGET in iOS shim targets.
(cherry picked from commit 6e907c4d1f)

Co-authored-by: Russell Keith-Magee <russell@keith-magee.com>
2025-05-01 02:59:27 +00:00
Miss Islington (bot)
4f006ffdb9
[3.13] Apply 'mod' role to typing module (GH-133201) (#133217)
Apply 'mod' role to typing module (GH-133201)
(cherry picked from commit 2b67db7ce3)

Co-authored-by: Rafael Fontenelle <rffontenelle@users.noreply.github.com>
Co-authored-by: Adam Turner <9087854+AA-Turner@users.noreply.github.com>
2025-04-30 16:58:19 +00:00
Miss Islington (bot)
110bec88bf
[3.13] Remove redundant `--keep-going` when running Sphinx (GH-133156) (#133214)
Remove redundant ``--keep-going`` when running Sphinx (GH-133156)
(cherry picked from commit c78216e42c)

Co-authored-by: Hugo van Kemenade <1324225+hugovk@users.noreply.github.com>
2025-04-30 17:44:00 +01:00
Miss Islington (bot)
704a3f8c0a
[3.13] gh-133167: Fix compilation process with --enable-optimizations and --without-docstrings (GH-133187) (#133207)
gh-133167: Fix compilation process with `--enable-optimizations` and `--without-docstrings` (GH-133187)
(cherry picked from commit cc39b19f0f)

Co-authored-by: sobolevn <mail@sobolevn.me>
2025-04-30 14:06:31 +00:00
Miss Islington (bot)
0458554482
[3.13] gh-133117: Run mypy on tomllib in CI (GH-133118) (#133192)
gh-133117: Run mypy on `tomllib` in CI (GH-133118)
(cherry picked from commit 5ea9010e89)

Co-authored-by: sobolevn <mail@sobolevn.me>
2025-04-30 12:57:57 +00:00