]>
git.ipfire.org Git - thirdparty/Python/cpython.git/log
Miss Islington (bot) [Mon, 3 Jul 2023 15:13:21 +0000 (08:13 -0700)]
[3.12] gh-91053: make func watcher tests resilient to other func watchers (GH-106286) (#106365)
gh-91053: make func watcher tests resilient to other func watchers (GH-106286)
(cherry picked from commit
58906213cc5d8f2be311664766b4923ef29dae1f )
Co-authored-by: Carl Meyer <carl@oddbird.net>
Miss Islington (bot) [Mon, 3 Jul 2023 13:42:20 +0000 (06:42 -0700)]
[3.12] gh-106359: Fix corner case bugs in Argument Clinic converter parser (GH-106361) (#106364)
gh-106359: Fix corner case bugs in Argument Clinic converter parser (GH-106361)
DSLParser.parse_converter() could return unusable kwdicts in some rare cases
(cherry picked from commit
0da4c883cf4185efe27b711c3e0a1e6e94397610 )
Co-authored-by: Erlend E. Aasland <erlend@python.org>
Co-authored-by: Alex Waygood <Alex.Waygood@Gmail.com>
Miss Islington (bot) [Mon, 3 Jul 2023 03:23:27 +0000 (20:23 -0700)]
[3.12] Replace the esoteric term 'datum' when describing dict comprehensions (GH-106119) (#106348)
Replace the esoteric term 'datum' when describing dict comprehensions (GH-106119)
(cherry picked from commit
987b712b4aeeece336eed24fcc87a950a756c3e2 )
Co-authored-by: Ned Batchelder <ned@nedbatchelder.com>
Miss Islington (bot) [Sat, 1 Jul 2023 23:16:14 +0000 (16:16 -0700)]
[3.12] gh-102541: Fix Helper.help("mod") for non-existent mod (GH-105934) (#106322)
gh-102541: Fix Helper.help("mod") for non-existent mod (GH-105934)
If the output arg to Helper() is a stream rather than the default None, which means 'page to stdout', the ImportError from pydoc.resolve is currently not caught in pydoc.doc. The same error is caught when output is None.
---------
(cherry picked from commit
0530f4f64629ff97f3feb7524da0833b9535e8b6 )
Co-authored-by: Kirill Podoprigora <kirill.bast9@mail.ru>
Co-authored-by: Terry Jan Reedy <tjreedy@udel.edu>
Miss Islington (bot) [Sat, 1 Jul 2023 02:40:43 +0000 (19:40 -0700)]
[3.12] gh-106232: Make timeit doc command lines compatible with Windows. (GH-106296) (#106298)
gh-106232: Make timeit doc command lines compatible with Windows. (GH-106296)
Command Prompt (CMD Shell) and older versions of PowerShell
require double quotes and single quotes inside the string.
This form also works on linux and macOS.
(cherry picked from commit
04dfc6fa9018e92a5b51c29fc0ff45419c596bc3 )
Co-authored-by: Terry Jan Reedy <tjreedy@udel.edu>
Miss Islington (bot) [Sat, 1 Jul 2023 00:32:44 +0000 (17:32 -0700)]
[3.12] gh-105486: Change the `repr` of `ParamSpec` list of args in `GenericAlias` (GH-105488) (#106297)
gh-105486: Change the `repr` of `ParamSpec` list of args in `GenericAlias` (GH-105488)
(cherry picked from commit
eb7d6e7ad844955f9af88707d296e003c7ce4394 )
Co-authored-by: Nikita Sobolev <mail@sobolevn.me>
Miss Islington (bot) [Sat, 1 Jul 2023 00:15:18 +0000 (17:15 -0700)]
[3.12] gh-106145: Make `end_{lineno,col_offset}` required on `type_param` nodes (GH-106224) (#106295)
gh-106145: Make `end_{lineno,col_offset}` required on `type_param` nodes (GH-106224)
(cherry picked from commit
46c1097868745eeb47abbc8af8c34e8fcb80ff1d )
Co-authored-by: Nikita Sobolev <mail@sobolevn.me>
Miss Islington (bot) [Fri, 30 Jun 2023 14:39:52 +0000 (07:39 -0700)]
[3.12] gh-101100: Docs: Fix references to several numeric dunders (GH-106278) (#106281)
gh-101100: Docs: Fix references to several numeric dunders (GH-106278)
(cherry picked from commit
a8ae73965b02302b7661ea07a6e4f955a961aca9 )
Co-authored-by: F3eQnxN3RriK <drsuaimqjgar@gmail.com>
Co-authored-by: Alex Waygood <Alex.Waygood@Gmail.com>
Miss Islington (bot) [Fri, 30 Jun 2023 10:21:36 +0000 (03:21 -0700)]
[3.12] gh-77782: Deprecate Py_HasFileSystemDefaultEncoding (GH-106272) (#106274)
gh-77782: Deprecate Py_HasFileSystemDefaultEncoding (GH-106272)
Deprecate Py_HasFileSystemDefaultEncoding variable.
(cherry picked from commit
f3cf2ddd8ddc7dfa6b06e6da640391a1bcd62b8a )
Co-authored-by: Victor Stinner <vstinner@python.org>
Miss Islington (bot) [Thu, 29 Jun 2023 23:39:18 +0000 (16:39 -0700)]
[3.12] GH-106152: Add PY_THROW event to cProfile (GH-106256)
GH-106152: Add PY_THROW event to cProfile (GH-106161)
(cherry picked from commit
cea9d4ea82abcb2c6f1d83a2fe819859da4bbda4 )
Co-authored-by: Tian Gao <gaogaotiantian@hotmail.com>
Miss Islington (bot) [Thu, 29 Jun 2023 18:41:01 +0000 (11:41 -0700)]
[3.12] Fix possible refleak in CodeType.replace() (GH-106243) (GH-106244)
Fix possible refleak in CodeType.replace() (GH-106243)
A reference to c_code was leaked if PySys_Audit() failed.
(cherry picked from commit
3c70d467c148875f2ce17bacab8909ecc3e9fc1d )
Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
Miss Islington (bot) [Thu, 29 Jun 2023 10:46:51 +0000 (03:46 -0700)]
[3.12] gh-101006: Improve error handling when read marshal data (GH-101007) (GH-106226)
* EOFError no longer overrides other errors such as MemoryError or OSError at
the start of the object.
* Raise more relevant error when the NULL object occurs as a code object
component.
* Minimize an overhead of calling PyErr_Occurred().
(cherry picked from commit
8bf6904b229583033035d91a3800da5604dcaad4 )
Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
Miss Islington (bot) [Thu, 29 Jun 2023 10:45:39 +0000 (03:45 -0700)]
[3.12] gh-106033: Get rid of PyDict_GetItem in _PyFunction_FromConstructor (GH-106044) (GH-106228)
gh-106033: Get rid of PyDict_GetItem in _PyFunction_FromConstructor (GH-106044)
(cherry picked from commit
08c08d21b03d949452a77d9ed5e3cf48d6b9804d )
Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
Miss Islington (bot) [Wed, 28 Jun 2023 21:12:12 +0000 (14:12 -0700)]
[3.12] gh-106194: Rename duplicated tests in `test_curses` (GH-106196) (#106216)
Co-authored-by: Nikita Sobolev <mail@sobolevn.me>
Miss Islington (bot) [Wed, 28 Jun 2023 15:13:57 +0000 (08:13 -0700)]
[3.12] gh-106197: Deduplicate tests in `test_buffer` (GH-106198) (#106206)
gh-106197: Deduplicate tests in `test_buffer` (GH-106198)
(cherry picked from commit
c283a0cff5603540f06d9017e484b3602cc62e7c )
Co-authored-by: Nikita Sobolev <mail@sobolevn.me>
Miss Islington (bot) [Wed, 28 Jun 2023 12:44:23 +0000 (05:44 -0700)]
[3.12] gh-101100: Fix reference to `parse_args` in `optparse.rst` (GH-105265) (#106204)
Co-authored-by: F3eQnxN3RriK <drsuaimqjgar@gmail.com>
Miss Islington (bot) [Wed, 28 Jun 2023 11:54:53 +0000 (04:54 -0700)]
[3.12] gh-106118: Add O_CLOEXEC preprocessor guard (GH-106120) (#106199)
(cherry picked from commit
6c60684bf5d34fae27a2f6a142ff794b38cefe1b )
Co-authored-by: Erlend E. Aasland <erlend@python.org>
Miss Islington (bot) [Wed, 28 Jun 2023 11:06:49 +0000 (04:06 -0700)]
[3.12] gh-105993: Add possible `None` return type to `asyncio.EventLoop.start_tls` docs (GH-105995) (#106188)
gh-105993: Add possible `None` return type to `asyncio.EventLoop.start_tls` docs (GH-105995)
(cherry picked from commit
6b52a581c151914e59c8c367a03bc7309713a73b )
Co-authored-by: Sam Bull <git@sambull.org>
Miss Islington (bot) [Wed, 28 Jun 2023 11:06:02 +0000 (04:06 -0700)]
[3.12] gh-101100: Fix reference to asynchronous methods (GH-106172) (#106191)
gh-101100: Fix reference to asynchronous methods (GH-106172)
(cherry picked from commit
bbf722dcd39c66418e45991dcf1cdf140c2ce20e )
Co-authored-by: F3eQnxN3RriK <drsuaimqjgar@gmail.com>
Miss Islington (bot) [Wed, 28 Jun 2023 10:46:16 +0000 (03:46 -0700)]
[3.12] GH-106160: Fix test_gzip failing under WASI, which does not have zlib. (GH-106167) (#106170)
GH-106160: Fix test_gzip failing under WASI, which does not have zlib. (GH-106167)
Fix test_gzip's failure under WASI, which does not have zlib, by using
test.support.import_helper.import_module to import zlib. (gzip
unconditionally imports zlib, so this does not cause any new skips.)
(cherry picked from commit
161012fc25910a47423bae8012398bf519a88140 )
Co-authored-by: T. Wouters <thomas@python.org>
Miss Islington (bot) [Wed, 28 Jun 2023 05:38:01 +0000 (22:38 -0700)]
[3.12] Refer to `TimeoutError` instead of `asyncio.TimeoutError` in `asyncio-task.rst` (GH-106136) (#106179)
Co-authored-by: lightdrk <108566237+lightdrk@users.noreply.github.com>
Co-authored-by: Hugo van Kemenade <hugovk@users.noreply.github.com>
Miss Islington (bot) [Wed, 28 Jun 2023 03:41:36 +0000 (20:41 -0700)]
[3.12] Fix c-analyzer for GCC: ignore LANG env var (GH-106173) (#106178)
Fix c-analyzer for GCC: ignore LANG env var (GH-106173)
The c-analyzer doesn't support GCC localized messages, so just unset
the LANG environment variable.
(cherry picked from commit
1f74b9e933d546a015e8497e3b8728357196acc8 )
Co-authored-by: Victor Stinner <vstinner@python.org>
Miss Islington (bot) [Wed, 28 Jun 2023 02:55:27 +0000 (19:55 -0700)]
[3.12] gh-101634: regrtest reports decoding error as failed test (GH-106169) (#106174)
gh-101634: regrtest reports decoding error as failed test (GH-106169)
When running the Python test suite with -jN option, if a worker stdout
cannot be decoded from the locale encoding report a failed testn so the
exitcode is non-zero.
(cherry picked from commit
2ac3eec103cf450aaaebeb932e51155d2e7fb37b )
Co-authored-by: Victor Stinner <vstinner@python.org>
Pablo Galindo Salgado [Tue, 27 Jun 2023 18:33:01 +0000 (19:33 +0100)]
[3.12] gh-106140: Reorder some more fields to facilitate out-of-process inspection (GH-106148) (#106155)
(cherry picked from commit
9126a6a9ce3772d5dc785cbee159b07a1ff7d531 )
Miss Islington (bot) [Tue, 27 Jun 2023 17:44:37 +0000 (10:44 -0700)]
[3.12] gh-106140: Reorder some fields to facilitate out-of-process inspection (GH-106143) (#106147)
gh-106140: Reorder some fields to facilitate out-of-process inspection (GH-106143)
(cherry picked from commit
2d5a1c281161d037148ffb5983decc6d31c2557d )
Signed-off-by: Pablo Galindo <pablogsal@gmail.com>
Co-authored-by: Pablo Galindo Salgado <Pablogsal@gmail.com>
Miss Islington (bot) [Tue, 27 Jun 2023 17:35:48 +0000 (10:35 -0700)]
[3.12] IDLE: Condense run.main threading.Thread start. (GH-106125) (#106154)
IDLE: Condense run.main threading.Thread start. (GH-106125)
Use daemon argument added in 3.3 and directly call .start.
Remove now unused 'sockthread' name.
(cherry picked from commit
eaa1eae55ea66d74c5303924320185dac74d4eb1 )
Co-authored-by: Terry Jan Reedy <tjreedy@udel.edu>
Miss Islington (bot) [Tue, 27 Jun 2023 13:44:44 +0000 (06:44 -0700)]
[3.12] gh-92788: Add docs for `ast.Module`, `ast.Expression`, and others (GH-101055) (#106139)
gh-92788: Add docs for `ast.Module`, `ast.Expression`, and others (GH-101055)
(cherry picked from commit
33608fd67df8b1033519f808441ee00289e2dac0 )
Co-authored-by: Nikita Sobolev <mail@sobolevn.me>
Miss Islington (bot) [Tue, 27 Jun 2023 05:49:32 +0000 (22:49 -0700)]
[3.12] gh-106123: Modules/_sha3 appears to no longer be necessary (GH-106124) (#106127)
Co-authored-by: Skip Montanaro <skip.montanaro@gmail.com>
Miss Islington (bot) [Tue, 27 Jun 2023 04:32:16 +0000 (21:32 -0700)]
[3.12] GH-105774: Clarify operation of normalize() (GH-106093) (GH-106128)
Miss Islington (bot) [Tue, 27 Jun 2023 03:43:20 +0000 (20:43 -0700)]
[3.12] gh-106030: Miscellaneous fixes in Python/suggestions.c (GH-106031) (#106036)
Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
Miss Islington (bot) [Tue, 27 Jun 2023 03:41:52 +0000 (20:41 -0700)]
[3.12] gh-84976: Add back UTC to datetime.__all__ (GH-104920) (#106019)
Co-authored-by: Shantanu <12621235+hauntsaninja@users.noreply.github.com>
Miss Islington (bot) [Mon, 26 Jun 2023 19:11:49 +0000 (12:11 -0700)]
[3.12] Revert "GH-96145: Add AttrDict to JSON module for use with object_hook (GH-96146)" (GH-105948) (#106117)
Revert "GH-96145: Add AttrDict to JSON module for use with object_hook (GH-96146)" (GH-105948)
This reverts commit
1f0eafa844bf5a380603d55e8d4b42d8c2a3439d .
(cherry picked from commit
d3af83b9342457d8b24476baeb799f7506ff04f3 )
Co-authored-by: Łukasz Langa <lukasz@langa.pl>
Miss Islington (bot) [Mon, 26 Jun 2023 18:12:52 +0000 (11:12 -0700)]
[3.12] gh-106107: document correct error that's raised when a mutable default value for a field is detected (gh-106109) (gh-106115)
gh-106107: document correct error that's raised when a mutable default value for a field is detected (gh-106109)
(cherry picked from commit
512f299e557f4ab60768d36cee9968bd92116367 )
Co-authored-by: Roderich Schupp <roderich.schupp@gmail.com>
Miss Islington (bot) [Mon, 26 Jun 2023 16:26:40 +0000 (09:26 -0700)]
[3.12] gh-106111: Remove zipapp documentation on creating a Windows executable (GH-106112) (#106114)
Remove zipapp documentation on creating a Windows executable
(cherry picked from commit
5d4dbf0e309255e5bce9e31d805a8f950ebf9161 )
Co-authored-by: Paul Moore <p.f.moore@gmail.com>
Miss Islington (bot) [Mon, 26 Jun 2023 16:11:48 +0000 (09:11 -0700)]
[3.12] Update test.support.interpreters to include missing RunFailedError import (GH-103841) (#106110)
(cherry picked from commit
1a2bc94fc2bbdf5f810b441ebbbd8fec95a3207c )
Co-authored-by: Bruce Eckel <BruceTEckel@gmail.com>
Co-authored-by: Alex Waygood <Alex.Waygood@Gmail.com>
Miss Islington (bot) [Mon, 26 Jun 2023 12:26:15 +0000 (05:26 -0700)]
[3.12] gh-106075: add `asyncio.taskgroups.__all__` to `asyncio.__all__` (GH-106090) (#106098)
gh-106075: add `asyncio.taskgroups.__all__` to `asyncio.__all__` (GH-106090)
(cherry picked from commit
a12e8ffb49e05a1d1874389318911ce9685db232 )
Co-authored-by: James Webber <jamestwebber@users.noreply.github.com>
Co-authored-by: Kumar Aditya <59607654+kumaraditya303@users.noreply.github.com>
Kumar Aditya [Mon, 26 Jun 2023 08:51:28 +0000 (14:21 +0530)]
[3.12] gh-105987: Fix reference counting issue in `_asyncio._swap_cur… (#106099)
[3.12] gh-105987: Fix reference counting issue in `_asyncio._swap_current_task` (GH-105989).
(cherry picked from commit
d2cbb6e918d9ea39f0dd44acb53270f2dac07454 )
Co-authored-by: chgnrdv <52372310+chgnrdv@users.noreply.github.com>
Miss Islington (bot) [Mon, 26 Jun 2023 08:43:24 +0000 (01:43 -0700)]
[3.12] Improve typing docs on the type of class objects (GH-106081) (#106096)
Improve typing docs on the type of class objects (GH-106081)
(cherry picked from commit
3eeb8c89063d5ac22c0b1d26e4ae2fd12c149650 )
Co-authored-by: Alex Waygood <Alex.Waygood@Gmail.com>
Miss Islington (bot) [Mon, 26 Jun 2023 08:32:00 +0000 (01:32 -0700)]
[3.12] gh-84436: update docs on Py_None/Py_True/Py_False/Py_Ellipsis becoming immortal (GH-105195) (#105977)
gh-84436: update docs on Py_None/Py_True/Py_False/Py_Ellipsis becoming immortal (GH-105195)
(cherry picked from commit
a2392720d6108041d17960a86514ba859b436f05 )
Co-authored-by: Irit Katriel <1055913+iritkatriel@users.noreply.github.com>
Miss Islington (bot) [Mon, 26 Jun 2023 08:31:01 +0000 (01:31 -0700)]
[3.12] gh-105979: Fix exception handling in `unmarshal_frozen_code` (`Python/import.c`) (GH-105980) (#106055)
gh-105979: Fix exception handling in `unmarshal_frozen_code` (`Python/import.c`) (GH-105980)
(cherry picked from commit
cd5280367a3a7065d13b8f7234474f7a2e9a18fd )
Co-authored-by: chgnrdv <52372310+chgnrdv@users.noreply.github.com>
Miss Islington (bot) [Sun, 25 Jun 2023 15:14:18 +0000 (08:14 -0700)]
[3.12] gh-104212: Explain how to port imp.load_source() (GH-105978) (#106083)
gh-104212: Explain how to port imp.load_source() (GH-105978)
Explain how to port removed imp.load_source() to importlib in What's
New in Python 3.12.
(cherry picked from commit
18a7c86697493510993e43bafe8bd4046928bec5 )
Co-authored-by: Victor Stinner <vstinner@python.org>
Miss Islington (bot) [Sun, 25 Jun 2023 11:18:22 +0000 (04:18 -0700)]
[3.12] Add end-of-file-fixer to pre-commit (GH-106065) (#106080)
Add end-of-file-fixer to pre-commit (GH-106065)
(cherry picked from commit
8c24a837371439b8e922ff47275085b581f510c5 )
Co-authored-by: Hugo van Kemenade <hugovk@users.noreply.github.com>
Miss Islington (bot) [Sun, 25 Jun 2023 08:16:12 +0000 (01:16 -0700)]
[3.12] Docs: add links to 'callable' term in sqlite3 docs (GH-106072) (#106073)
(cherry picked from commit
bef1c8761e3b0dfc5708747bb646ad8b669cbd67 )
Co-authored-by: Erlend E. Aasland <erlend@python.org>
Serhiy Storchaka [Sat, 24 Jun 2023 23:36:34 +0000 (02:36 +0300)]
[3.12] gh-106033: Get rid of new occurrences of PyDict_GetItem and Py… (#106041)
[3.12] gh-106033: Get rid of new occurrences of PyDict_GetItem and PyObject_HasAttr (GH-106034)
These functions are broken by design because they discard any exceptions raised
inside, including MemoryError and KeyboardInterrupt. They should not be
used in new code.
(cherry picked from commit
1d33d5378058671bfabb6f4d4b5bfd4726973ff9 )
Miss Islington (bot) [Sat, 24 Jun 2023 23:30:27 +0000 (16:30 -0700)]
[3.12] gh-106033: [docs] Improve C API GetItem & HasAttr notes. (GH-106047) (#106070)
gh-106033: [docs] Improve C API GetItem & HasAttr notes. (GH-106047)
Use a note:: tag so that these dict and object API deficiencies show up clearly.
A caution:: tag was considered, but our current python docs rendering doesn't do much with that (no box or color change). warning:: seemed too extreme. note looks good.
(cherry picked from commit
19d6511b0b8f3f74e668ae32ccef89bcbf1a8a62 )
Co-authored-by: Gregory P. Smith <greg@krypto.org>
Barney Gale [Sat, 24 Jun 2023 15:25:47 +0000 (16:25 +0100)]
[3.12] GH-104375: Use `versionchanged` to describe new arguments in pathlib docs (GH-104376, GH-106058)
(cherry picked from commit
4a6c84fc1ea8f26d84a0fbeeff6f8dedc32263d4 )
Miss Islington (bot) [Fri, 23 Jun 2023 20:35:00 +0000 (13:35 -0700)]
[3.12] Typing docs: fix typo in annotating tuples comment (GH-106048) (#106049)
Typing docs: fix typo in annotating tuples comment (GH-106048)
(cherry picked from commit
8ef0ee4ebc84ee68f16cea85ffdb949ecccb4ba5 )
Co-authored-by: Eamon Tracey <66919574+EamonTracey@users.noreply.github.com>
Miss Islington (bot) [Fri, 23 Jun 2023 15:26:37 +0000 (08:26 -0700)]
[3.12] gh-105974: Revert unintentional behaviour change for protocols with non-callable members and custom `__subclasshook__` methods (GH-105976) (#106032)
gh-105974: Revert unintentional behaviour change for protocols with non-callable members and custom `__subclasshook__` methods (GH-105976)
(cherry picked from commit
9499b0f138cc53b9a2590350d0b545d2f69ee126 )
Co-authored-by: Alex Waygood <Alex.Waygood@Gmail.com>
Miss Islington (bot) [Fri, 23 Jun 2023 14:48:29 +0000 (07:48 -0700)]
[3.12] Typing docs: improve the guidance on annotating tuples (GH-106021) (#106027)
Typing docs: improve the guidance on annotating tuples (GH-106021)
(cherry picked from commit
968435ddb1c1af9333befb26f7970cded8a5c710 )
Co-authored-by: Alex Waygood <Alex.Waygood@Gmail.com>
Miss Islington (bot) [Fri, 23 Jun 2023 08:07:58 +0000 (01:07 -0700)]
[3.12] Docs: Avoid a DeprecationWarning in `pyspecific.py` when running with Sphinx >=6.1 (GH-105886) (#106010)
Docs: Avoid a DeprecationWarning in `pyspecific.py` when running with Sphinx >=6.1 (GH-105886)
(cherry picked from commit
a72683ba8e0337650cc490dbe593a5e46aba60cb )
Co-authored-by: Alex Waygood <Alex.Waygood@Gmail.com>
Co-authored-by: Hugo van Kemenade <hugovk@users.noreply.github.com>
Miss Islington (bot) [Thu, 22 Jun 2023 16:28:06 +0000 (09:28 -0700)]
[3.12] gh-98931: Add custom error messages to invalid import/from with multiple targets (GH-105985) (#105991)
Co-authored-by: Pablo Galindo Salgado <Pablogsal@gmail.com>
Co-authored-by: Alex Waygood <Alex.Waygood@Gmail.com>
Miss Islington (bot) [Wed, 21 Jun 2023 14:40:54 +0000 (07:40 -0700)]
[3.12] stdtypes.rst: remove a period (GH-105959) (#105968)
stdtypes.rst: remove a period (GH-105959)
(cherry picked from commit
c5a722be5f7979c73e2451e537a8fc58bf9af12e )
Co-authored-by: Mathieu Dupuy <deronnax@gmail.com>
Miss Islington (bot) [Tue, 20 Jun 2023 23:03:54 +0000 (16:03 -0700)]
[3.12] gh-104212: Explain how to port imp code to importlib (GH-105905) (#105952)
gh-104212: Explain how to port imp code to importlib (GH-105905)
(cherry picked from commit
7a56a4148c521969d64164d2776641f19e3ca9e8 )
Co-authored-by: Victor Stinner <vstinner@python.org>
Miss Islington (bot) [Tue, 20 Jun 2023 15:08:29 +0000 (08:08 -0700)]
[3.12] gh-105915: Fix SyntaxWarning becoming a SyntaxError with -We in test_fstring (GH-105943) (#105945)
(cherry picked from commit
6e40ee6e8456da04d6970a46863300c043c81208 )
Co-authored-by: Lysandros Nikolaou <lisandrosnik@gmail.com>
Thomas Wouters [Tue, 20 Jun 2023 13:32:39 +0000 (15:32 +0200)]
Merge branch '3.12' of https://github.com/python/cpython into 3.12
Thomas Wouters [Tue, 20 Jun 2023 13:32:24 +0000 (15:32 +0200)]
Post 3.12.0b3
Miss Islington (bot) [Tue, 20 Jun 2023 13:16:21 +0000 (06:16 -0700)]
[3.12] gh-105915: Add 'r' prefix to not emit SyntaxWarning in test_fstring (GH-105940) (#105942)
(cherry picked from commit
4b431d2e90bf5760a57aa40af2dd78e7bbf0b1ae )
Co-authored-by: @sunmy2019
Co-authored-by: Lysandros Nikolaou <lisandrosnik@gmail.com>
Miss Islington (bot) [Tue, 20 Jun 2023 13:09:48 +0000 (06:09 -0700)]
[3.12] gh-105938: Emit a SyntaxWarning for escaped braces in an f-string (GH-105939) (#105941)
(cherry picked from commit
6586cee27f32f0354fe4e77c7b8c6e399329b5e2 )
Co-authored-by: Lysandros Nikolaou <lisandrosnik@gmail.com>
Miss Islington (bot) [Tue, 20 Jun 2023 03:05:20 +0000 (20:05 -0700)]
[3.12] gh-105908: fix `barry_as_FLUFL` future import (GH-105909) (#105930)
(cherry picked from commit
28187a9c4f95affe50fd37e0db0db177e2b9c2e9 )
Co-authored-by: Crowthebird <78076854+thatbirdguythatuknownot@users.noreply.github.com>
Thomas Wouters [Mon, 19 Jun 2023 18:55:07 +0000 (20:55 +0200)]
Python 3.12.0b3
Miss Islington (bot) [Mon, 19 Jun 2023 17:42:23 +0000 (10:42 -0700)]
[3.12] GH-105808: Fix a regression introduced in GH-101251 (GH-105910) (#105920)
GH-105808: Fix a regression introduced in GH-101251 (GH-105910)
Fix a regression introduced in pythonGH-101251, causing GzipFile.flush() to
not flush the compressor (nor pass along the zip_mode argument).
(cherry picked from commit
1858db7cbdbf41aa600c954c15224307bf81a258 )
Co-authored-by: T. Wouters <thomas@python.org>
Miss Islington (bot) [Mon, 19 Jun 2023 00:02:48 +0000 (17:02 -0700)]
[3.12] typing docs: Improve the intro to each section (GH-105901) (#105902)
typing docs: Improve the intro to each section (GH-105901)
(cherry picked from commit
4426279a4399158027a1145cff1c4c92424bf5b5 )
Co-authored-by: Alex Waygood <Alex.Waygood@Gmail.com>
Miss Islington (bot) [Sun, 18 Jun 2023 17:56:35 +0000 (10:56 -0700)]
[3.12] gh-105844: Use devguide terminology to denote versions (GH-105882) (#105892)
(cherry picked from commit
dba72175116373c1d15e25d84c88b516daf9f5c4 )
Co-authored-by: Erlend E. Aasland <erlend.aasland@protonmail.com>
Miss Islington (bot) [Sun, 18 Jun 2023 12:21:34 +0000 (05:21 -0700)]
[3.12] Docs: move sphinx-lint to pre-commit (GH-105750) (#105894)
Docs: move sphinx-lint to pre-commit (GH-105750)
(cherry picked from commit
bc07c8f096791d678ca5c1e3486cb9648f7a027b )
Co-authored-by: Hugo van Kemenade <hugovk@users.noreply.github.com>
Miss Islington (bot) [Fri, 16 Jun 2023 19:34:46 +0000 (12:34 -0700)]
[3.12] CI: Bump macOS build to use OpenSSL v3.0 (GH-105538) (#105867)
(cherry picked from commit
34e93d3998bab8acd651c50724eb1977f4860a08 )
Co-authored-by: Erlend E. Aasland <erlend.aasland@protonmail.com>
Miss Islington (bot) [Fri, 16 Jun 2023 18:29:55 +0000 (11:29 -0700)]
[3.12] GH-105840: Fix assertion failures when specializing calls with too many __defaults__ (GH-105863)
GH-105840: Fix assertion failures when specializing calls with too many __defaults__ (GH-105847)
(cherry picked from commit
2beab5bdef5fa2a00a59371e6137f769586b7404 )
Co-authored-by: Brandt Bucher <brandtbucher@microsoft.com>
Miss Islington (bot) [Fri, 16 Jun 2023 17:17:33 +0000 (10:17 -0700)]
[3.12] bpo-44530: Document the change in MAKE_FUNCTION behavior (GH-93189) (#105841)
bpo-44530: Document the change in MAKE_FUNCTION behavior (GH-93189)
* bpo-44530: Document the change in MAKE_FUNCTION behavior
Fixes dis module documentation for MAKE_FUNCTION due to https://github.com/python/cpython/commit/
2f180ce2cb6e6a7e3c517495e0f4873d6aaf5f2f (bpo-44530, released as part of 3.11) removes the qualified name at TOS
(cherry picked from commit
486b52a3158e0f64fc54efdfa34ed5437b3619f2 )
Co-authored-by: Alex Doe <alexdoesh@gmail.com>
Miss Islington (bot) [Fri, 16 Jun 2023 16:59:25 +0000 (09:59 -0700)]
[3.12] gh-104799: PEP 695 backward compatibility for ast.unparse (GH-105846) (#105862)
(cherry picked from commit
957a974d4fc1575787e4a29a399a47520d6df6d3 )
Co-authored-by: Jelle Zijlstra <jelle.zijlstra@gmail.com>
Miss Islington (bot) [Fri, 16 Jun 2023 16:20:19 +0000 (09:20 -0700)]
[3.12] gh-105834: Add tests for calling `issubclass()` between two protocols (GH-105835) (#105859)
Some parts of the implementation of `typing.Protocol` had poor test coverage
(cherry picked from commit
70c075c194d3739ae10ce76265f05fa82ed46487 )
Co-authored-by: Alex Waygood <Alex.Waygood@Gmail.com>
Miss Islington (bot) [Fri, 16 Jun 2023 11:30:36 +0000 (04:30 -0700)]
[3.12] CI: Remove docs build from Azure Pipelines (GH-105823) (#105854)
Co-authored-by: Hugo van Kemenade <hugovk@users.noreply.github.com>
Miss Islington (bot) [Fri, 16 Jun 2023 08:56:32 +0000 (01:56 -0700)]
[3.12] gh-105844: Consistently use 'minor version' for X.Y versions (GH-105851) (#105853)
(cherry picked from commit
0bffe1acd78069ea21f6b1347bec9cc9747342cb )
Co-authored-by: Erlend E. Aasland <erlend.aasland@protonmail.com>
Miss Islington (bot) [Fri, 16 Jun 2023 07:56:40 +0000 (00:56 -0700)]
[3.12] Fix inaccuracies in "Assorted Topics" section of "Defining Extension Types" tutorial (GH-104969) (#105850)
Fix inaccuracies in "Assorted Topics" section of "Defining Extension Types" tutorial (GH-104969)
(cherry picked from commit
0d0963737a0f4b7cadedfae7e8fd33ed18269289 )
Co-authored-by: chgnrdv <52372310+chgnrdv@users.noreply.github.com>
Miss Islington (bot) [Fri, 16 Jun 2023 05:43:19 +0000 (22:43 -0700)]
[3.12] tarfile: Fix positional-only syntax in docs (GH-105770) (#105773)
The syntax used in the current docs (a / before any args) is invalid.
I think the right approach is for the arguments to arbitrary
filter functions to be treated as positional-only, meaning that users
can supply filter functions with any names for the argument. tarfile.py
only calls the filter function with positional arguments.
(cherry picked from commit
5cdd5ba49db10f05e204e7a49ce184222a93dce8 )
Co-authored-by: Jelle Zijlstra <jelle.zijlstra@gmail.com>
Miss Islington (bot) [Fri, 16 Jun 2023 01:26:45 +0000 (18:26 -0700)]
[3.12] gh-105433: Add `pickle` tests for PEP695 (GH-105443) (#105845)
(cherry picked from commit
1af8251d9ec2f18e131c19ccf776fb9ec132c7a8 )
Co-authored-by: Nikita Sobolev <mail@sobolevn.me>
Miss Islington (bot) [Thu, 15 Jun 2023 23:12:01 +0000 (16:12 -0700)]
[3.12] GH-105588: Add missing error checks to some obj2ast_* converters (GH-105838)
GH-105588: Add missing error checks to some obj2ast_* converters (GH-105589)
(cherry picked from commit
a4056c8f9c2d9970d39e3cb6bffb255cd4b8a42c )
Co-authored-by: Brandt Bucher <brandtbucher@microsoft.com>
Miss Islington (bot) [Thu, 15 Jun 2023 17:21:58 +0000 (10:21 -0700)]
[3.12] gh-105820: Fix tok_mode expression buffer in file & readline tokenizer (GH-105828) (#105832)
(cherry picked from commit
d382ad49157b3802fc5619f68d96810def517869 )
Co-authored-by: Lysandros Nikolaou <lisandrosnik@gmail.com>
Miss Islington (bot) [Thu, 15 Jun 2023 14:56:04 +0000 (07:56 -0700)]
[3.12] gh-102541: Hide traceback in help prompt (gh-102614) (gh-105778)
gh-102541: Hide traceback in help prompt (gh-102614)
(cherry picked from commit
ba516e70c6d156dc59dede35b6fc3db0151780a5 )
Co-authored-by: Kirill Podoprigora <kirill.bast9@mail.ru>
Miss Islington (bot) [Thu, 15 Jun 2023 11:13:22 +0000 (04:13 -0700)]
[3.12] gh-105821: Use a raw f-string in test_httpservers.py (GH-105822) (#105824)
gh-105821: Use a raw f-string in test_httpservers.py (GH-105822)
Use a raw f-string in test_httpservers.py
(cherry picked from commit
09ce8c3b48f940eb8865330f029b8069854c3106 )
Co-authored-by: Pablo Galindo Salgado <Pablogsal@gmail.com>
Miss Islington (bot) [Thu, 15 Jun 2023 06:12:42 +0000 (23:12 -0700)]
[3.12] More reorganisation of the typing docs (GH-105787) (#105810)
More reorganisation of the typing docs (GH-105787)
(cherry picked from commit
da911a6b226ca47cc15088d800b575e19a731f1c )
Co-authored-by: Alex Waygood <Alex.Waygood@Gmail.com>
Miss Islington (bot) [Thu, 15 Jun 2023 06:12:26 +0000 (23:12 -0700)]
[3.12] Improve docs for `typing.dataclass_transform` (GH-105792) (#105809)
Improve docs for `typing.dataclass_transform` (GH-105792)
(cherry picked from commit
006a4532058f1fadba93283c0f45b0d82735b364 )
Co-authored-by: Alex Waygood <Alex.Waygood@Gmail.com>
Miss Islington (bot) [Thu, 15 Jun 2023 03:30:00 +0000 (20:30 -0700)]
[3.12] gh-105196: Fix indentations of section headings in C API docs (GH-105672) (#105782)
gh-105196: Fix indentations of section headings in C API docs (GH-105672)
(cherry picked from commit
d32e8d6070057eb7ad0eb2f9d9f1efab38b2cff4 )
Co-authored-by: TATHAGATA ROY <royzen9495@gmail.com>
Miss Islington (bot) [Thu, 15 Jun 2023 00:36:40 +0000 (17:36 -0700)]
[3.12] gh-105800: Issue SyntaxWarning in f-strings for invalid escape sequences (GH-105801) (#105806)
Co-authored-by: Pablo Galindo Salgado <Pablogsal@gmail.com>
Alex Waygood [Wed, 14 Jun 2023 15:03:30 +0000 (16:03 +0100)]
[3.12] Typing docs: move the deprecated stuff below the non-deprecated stuff (#105781) (#105783)
Miss Islington (bot) [Wed, 14 Jun 2023 12:26:33 +0000 (05:26 -0700)]
[3.12] gh-105745: Fix open method of webbrowser.Konqueror (GH-105746) (#105777)
gh-105745: Fix open method of webbrowser.Konqueror (GH-105746)
(cherry picked from commit
e5d45b7444733861153d6e8959c34323fd361322 )
Co-authored-by: Nikita Sobolev <mail@sobolevn.me>
Miss Islington (bot) [Wed, 14 Jun 2023 05:04:22 +0000 (22:04 -0700)]
[3.12] gh-105587: Remove assertion from `_PyStaticObject_CheckRefcnt` (GH-105638) (#105769)
gh-105587: Remove assertion from `_PyStaticObject_CheckRefcnt` (GH-105638)
(cherry picked from commit
6199fe3b3236748033a7ce2559aeddb5a91bbbd9 )
Co-authored-by: Eddie Elizondo <eduardo.elizondorueda@gmail.com>
Miss Islington (bot) [Wed, 14 Jun 2023 01:34:26 +0000 (18:34 -0700)]
[3.12] gh-105699: Use a Thread-Local Variable for PKGCONTEXT (gh-105740) (gh-105765)
This fixes a race during import. The existing _PyRuntimeState.imports.pkgcontext is shared between interpreters, and occasionally this would cause a crash when multiple interpreters were importing extensions modules at the same time. To solve this we add a thread-local variable for the value. We also leave the existing state (and infrequent race) in place for platforms that do not support thread-local variables.
(cherry picked from commit
b87d2882754a7c273e2695c33384383eba380d7d )
Co-authored-by: Eric Snow <ericsnowcurrently@gmail.com>
Miss Islington (bot) [Wed, 14 Jun 2023 01:05:01 +0000 (18:05 -0700)]
[3.12] gh-105387: Limited C API implements Py_INCREF() as func (GH-105388) (#105763)
gh-105387: Limited C API implements Py_INCREF() as func (GH-105388)
In the limited C API version 3.12, Py_INCREF() and Py_DECREF()
functions are now implemented as opaque function calls to hide
implementation details.
(cherry picked from commit
b542972dc133973a7f0517aa1b61779271789111 )
Co-authored-by: Victor Stinner <vstinner@python.org>
Eric Snow [Wed, 14 Jun 2023 00:50:08 +0000 (18:50 -0600)]
[3.12] gh-104812: Run Pending Calls in any Thread (gh-104813) (gh-105752)
For a while now, pending calls only run in the main thread (in the main interpreter). This PR changes things to allow any thread run a pending call, unless the pending call was explicitly added for the main thread to run.
(cherry picked from commit
757b402 )
Miss Islington (bot) [Tue, 13 Jun 2023 23:41:07 +0000 (16:41 -0700)]
[3.12] gh-105436: Ignore unrelated errors when checking empty env (GH-105742) (#105756)
gh-105436: Ignore unrelated errors when checking empty env (GH-105742)
(cherry picked from commit
4cefe3cf10f498c0927ae4fdba4880d5a64826e4 )
Co-authored-by: Steve Dower <steve.dower@python.org>
Miss Islington (bot) [Tue, 13 Jun 2023 22:59:02 +0000 (15:59 -0700)]
[3.12] gh-98040: Fix importbench: use types.ModuleType() (GH-105743) (#105754)
gh-98040: Fix importbench: use types.ModuleType() (GH-105743)
Replace removed imp.new_module(name) with types.ModuleType(name).
(cherry picked from commit
457a459c7804950d4c27a243b176eb933ec87a06 )
Co-authored-by: Victor Stinner <vstinner@python.org>
Miss Islington (bot) [Tue, 13 Jun 2023 21:21:04 +0000 (14:21 -0700)]
[3.12] gh-102613: Bump recursion limit to fix running test_pathlib under Coverage (GH-105744) (#105749)
gh-102613: Bump recursion limit to fix running test_pathlib under Coverage (GH-105744)
(cherry picked from commit
4e80082723b768df124f77d2b73b3ba6b584a735 )
Co-authored-by: Łukasz Langa <lukasz@langa.pl>
Miss Islington (bot) [Tue, 13 Jun 2023 17:42:56 +0000 (10:42 -0700)]
[3.12] gh-105603: Change the PyInterpreterConfig.own gil Field (gh-105620) (gh-105731)
We are changing it to be more flexible that a strict bool can be for possible future expanded used cases.
(cherry picked from commit
b97e14a806477af4225777d215ac38c0d9b845f0 )
Co-authored-by: Eric Snow <ericsnowcurrently@gmail.com>
Miss Islington (bot) [Tue, 13 Jun 2023 15:53:51 +0000 (08:53 -0700)]
[3.12] gh-105718: Fix buffer allocation in tokenizer with readline (GH-105728) (#105729)
Co-authored-by: Lysandros Nikolaou <lisandrosnik@gmail.com>
Miro Hrončok [Tue, 13 Jun 2023 10:54:11 +0000 (12:54 +0200)]
[3.12] gh-105084: Tests: Use setuptools+wheel from sysconfig.get_config_var('WHEEL_PKG_DIR') if set (#105056) (#105424)
Includes part of the changes from
afa759fb800be416f69e3e9c9b3efe68006316f5 ,
to make this apply.
Co-Authored-By: Lysandros Nikolaou <lisandrosnik@gmail.com>
(cherry picked from commit
bd98b65e974b7a1e086a51e7b55131582f7a0491 )
Miss Islington (bot) [Tue, 13 Jun 2023 10:48:43 +0000 (03:48 -0700)]
[3.12] gh-105713: Document that tokenize raises when mixing tabs/spaces (GH-105723) (#105725)
* gh-105713: Document that tokenize raises when mixing tabs/spaces
* Update Doc/whatsnew/3.12.rst
(cherry picked from commit
ed8217b493e19cea0f3f539e55b592c09ceb9323 )
Co-authored-by: Lysandros Nikolaou <lisandrosnik@gmail.com>
Co-authored-by: Alex Waygood <Alex.Waygood@Gmail.com>
Erlend E. Aasland [Tue, 13 Jun 2023 09:15:19 +0000 (11:15 +0200)]
[3.12] gh-105375: Improve error handling in _Unpickler_SetInputStream() (#105667) (#105720)
Prevent exceptions from possibly being overwritten in case of multiple
failures.
(cherry picked from commit
217589d4f3246d67c6ef0eb0be2b1c33987cf260 )
Miss Islington (bot) [Mon, 12 Jun 2023 22:12:17 +0000 (15:12 -0700)]
[3.12] gh-105375: Explicitly initialise all {Pickler,Unpickler}Object fields (GH-105686) (#105710)
All fields must be explicitly initialised to prevent manipulation of
uninitialised fields in dealloc.
Align initialisation order with the layout of the object structs.
(cherry picked from commit
ca3cc4b95d66f7527ebe0ba4cdb1907082d9bfc8 )
Co-authored-by: Erlend E. Aasland <erlend.aasland@protonmail.com>
Miss Islington (bot) [Mon, 12 Jun 2023 16:50:58 +0000 (09:50 -0700)]
[3.12] gh-105436: The environment block should end with two null wchar_t values (GH-105495) (#105700)
gh-105436: The environment block should end with two null wchar_t values (GH-105495)
(cherry picked from commit
4f7d3b602d47d61137e82145f601dccfe6f6cd3c )
Co-authored-by: Dora203 <66343334+sku2000@users.noreply.github.com>
Miss Islington (bot) [Mon, 12 Jun 2023 16:24:21 +0000 (09:24 -0700)]
[3.12] gh-103968: PyType_FromMetaclass: Allow metaclasses with tp_new=NULL (GH-105386) (GH-105697)
gh-103968: PyType_FromMetaclass: Allow metaclasses with tp_new=NULL (GH-105386)
(cherry picked from commit
2b90796be6959d5ef46b38c434a514fce25be971 )
Co-authored-by: Petr Viktorin <encukou@gmail.com>
Miss Islington (bot) [Mon, 12 Jun 2023 16:02:30 +0000 (09:02 -0700)]
[3.12] ARM64 clamping bug also exists in MSVC 14.35 (GH-105679) (#105695)
ARM64 clamping bug also exists in MSVC 14.35 (GH-105679)
(cherry picked from commit
58f0bda34126ed790000451874b96140737f40ed )
Co-authored-by: Steve Dower <steve.dower@python.org>