]> git.ipfire.org Git - thirdparty/Python/cpython.git/log
thirdparty/Python/cpython.git
4 years agobpo-44022: Improve the regression test. (GH-26503)
Miss Islington (bot) [Thu, 3 Jun 2021 04:04:20 +0000 (21:04 -0700)] 
bpo-44022: Improve the regression test. (GH-26503)

It wasn't actually detecting the regression due to the
assertion being too lenient.
(cherry picked from commit e60ab843cbb016fb6ff8b4f418641ac05a9b2fcc)

Co-authored-by: Gregory P. Smith <greg@krypto.org>
4 years agobpo-44282: Fix occasional test_incremental_editing failures on buildbots (GH-26491...
Miss Islington (bot) [Thu, 3 Jun 2021 00:14:41 +0000 (17:14 -0700)] 
bpo-44282: Fix occasional test_incremental_editing failures on buildbots (GH-26491) (GH-26499)

Signed-off-by: Tal Einat <532281+taleinat@users.noreply.github.com>
(cherry picked from commit adef445dc34685648bd0ea1c125df2ef143912ed)

Co-authored-by: Tal Einat <532281+taleinat@users.noreply.github.com>
4 years agobpo-44285: getpath.c: Assert that env_file is NULL during an error check (GH-26486)
Miss Islington (bot) [Wed, 2 Jun 2021 23:50:38 +0000 (16:50 -0700)] 
bpo-44285: getpath.c: Assert that env_file is NULL during an error check (GH-26486)

This was flagged by a static analyzer, but the logic of why this is NULL on error is hard to follow for humans as well.
(cherry picked from commit bdb56902a3bfe12b10f85a941d5dd0eae739f1a8)

Co-authored-by: stratakis <cstratak@redhat.com>
4 years agobpo-43921: Fix test_ssl.test_pha_required_nocert() (GH-26489)
Miss Islington (bot) [Wed, 2 Jun 2021 23:48:40 +0000 (16:48 -0700)] 
bpo-43921: Fix test_ssl.test_pha_required_nocert() (GH-26489)

Fix test_pha_required_nocert() of test_ssl: catch two more EOF cases
(when the recv() method returns an empty string).
(cherry picked from commit 320eaa7f42b413cd5e5436ec92d4dc5ba150395f)

Co-authored-by: Victor Stinner <vstinner@python.org>
4 years ago[3.10] bpo-44279: [doc] reword contextlib.suppress documentation (GH-26428) (GH-26480)
Irit Katriel [Tue, 1 Jun 2021 21:58:06 +0000 (22:58 +0100)] 
[3.10] bpo-44279: [doc] reword contextlib.suppress documentation (GH-26428) (GH-26480)

(cherry picked from commit 87272b70f157af76cb14ff90d73dfc5d9bfb945a)

Co-authored-by: MapleCCC <littlelittlemaple@gmail.com>
4 years agobpo-44246: Remove note about access by index now that a compatibility shim is offered...
Miss Islington (bot) [Mon, 31 May 2021 22:29:08 +0000 (15:29 -0700)] 
bpo-44246: Remove note about access by index now that a compatibility shim is offered. (GH-26472) (#26473)

(cherry picked from commit 78d9a9b1904f0e1d9db1e941c19782f4f5a881d4)

Co-authored-by: Jason R. Coombs <jaraco@jaraco.com>
Co-authored-by: Jason R. Coombs <jaraco@jaraco.com>
4 years ago[3.10] bpo-44246: Restore compatibility in entry_points (GH-26468) (GH-26471)
Miss Islington (bot) [Mon, 31 May 2021 16:41:55 +0000 (09:41 -0700)] 
[3.10] bpo-44246: Restore compatibility in entry_points (GH-26468) (GH-26471)

* [bpo-44246](): Entry points performance improvements.

From importlib_metadata 4.3.1.

* [bpo-44246](): Sync with importlib_metadata 4.4
(cherry picked from commit c34ed08d975fb7daa7b329f7c631647782290393)

Co-authored-by: Jason R. Coombs <jaraco@jaraco.com>
Automerge-Triggered-By: GH:jaraco
4 years agobpo-44246: Entry points performance improvements. (GH-26467)
Miss Islington (bot) [Mon, 31 May 2021 16:12:32 +0000 (09:12 -0700)] 
bpo-44246: Entry points performance improvements. (GH-26467)

From importlib_metadata 4.3.1.
(cherry picked from commit 410b70d39d9d77384f8b8597560f6731530149ca)

Co-authored-by: Jason R. Coombs <jaraco@jaraco.com>
4 years agoPost 3.10.0b2
Pablo Galindo [Mon, 31 May 2021 11:58:35 +0000 (12:58 +0100)] 
Post 3.10.0b2

4 years agoPython 3.10.0b2 v3.10.0b2
Pablo Galindo [Mon, 31 May 2021 11:29:21 +0000 (12:29 +0100)] 
Python 3.10.0b2

4 years agobpo-44263: Fix _decimal and _testcapi GC protocol (GH-26464) (GH-26465)
Miss Islington (bot) [Mon, 31 May 2021 11:25:47 +0000 (04:25 -0700)] 
bpo-44263: Fix _decimal and _testcapi GC protocol (GH-26464) (GH-26465)

* _testcapi.heapgctype: implement a traverse function since the type
  is defined with Py_TPFLAGS_HAVE_GC.
* _decimal: PyDecSignalDictMixin_Type is no longer defined with
  Py_TPFLAGS_HAVE_GC since it has no traverse function.
(cherry picked from commit 142e5c5445c019542246d93fe2f9e195d3131686)

Co-authored-by: Victor Stinner <vstinner@python.org>
Co-authored-by: Victor Stinner <vstinner@python.org>
4 years agobpo-42972: Fully implement GC protocol for xxlimited (GH-26451) (GH-26460)
Miss Islington (bot) [Mon, 31 May 2021 11:23:13 +0000 (04:23 -0700)] 
bpo-42972: Fully implement GC protocol for xxlimited (GH-26451) (GH-26460)

(cherry picked from commit 4b20f2574d412f4c4a5b1ab799d8e71a5dd3b766)

Co-authored-by: Hai Shi <shihai1992@gmail.com>
Co-authored-by: Hai Shi <shihai1992@gmail.com>
4 years agobpo-42972: Fix sqlite3 traverse/clear functions (GH-26452) (GH-26461)
Miss Islington (bot) [Mon, 31 May 2021 09:12:27 +0000 (02:12 -0700)] 
bpo-42972: Fix sqlite3 traverse/clear functions (GH-26452) (GH-26461)

(cherry picked from commit d1124b09e8251061dc040cbd396f35ae57783f4a)

Co-authored-by: Erlend Egeberg Aasland <erlend.aasland@innova.no>
4 years agobpo-42085: [docs] Add versionadded for am_send in type object documentation (GH-25465...
Miss Islington (bot) [Sat, 29 May 2021 20:38:00 +0000 (13:38 -0700)] 
bpo-42085: [docs] Add versionadded for am_send in type object documentation (GH-25465) (GH-26453)

(cherry picked from commit 0b11c429c7f1721d9ffb9ae19e3e8e2e7bd6444d)

Co-authored-by: Martmists <mail@martmists.com>
4 years agobpo-44263: Mention PyType_Ready in the gc protocol warning (GH-26445) (#26446)
Miss Islington (bot) [Sat, 29 May 2021 17:49:16 +0000 (10:49 -0700)] 
bpo-44263: Mention PyType_Ready in the gc protocol warning (GH-26445) (#26446)

(cherry picked from commit 43cf7c864a2941b3f8f823e5928721dd286b7778)

Co-authored-by: Pablo Galindo <Pablogsal@gmail.com>
Co-authored-by: Pablo Galindo <Pablogsal@gmail.com>
4 years agobpo-44254: On Mac, remove disfunctional colors from turtledemo buttons (GH-26448)
Miss Islington (bot) [Sat, 29 May 2021 07:34:57 +0000 (00:34 -0700)] 
bpo-44254: On Mac, remove disfunctional colors from turtledemo buttons (GH-26448)

On macOS, tk defers to system setting for button background when in normal state.
Give turtledemo button text a color that works on either light or dark background.
(cherry picked from commit af5a324843de395cecc562cb0c757b3768f2077f)

Co-authored-by: Terry Jan Reedy <tjreedy@udel.edu>
4 years agobpo-44263: Better explain the GC contract for PyType_FromSpecWithBases (GH-26442...
Miss Islington (bot) [Sat, 29 May 2021 03:21:26 +0000 (20:21 -0700)] 
bpo-44263: Better explain the GC contract for PyType_FromSpecWithBases (GH-26442) (GH-26443)

(cherry picked from commit 8b55bc3f93a655bc803bff79725d5fe3f124e2f0)

Co-authored-by: Pablo Galindo <Pablogsal@gmail.com>
Co-authored-by: Pablo Galindo <Pablogsal@gmail.com>
4 years agoFix dataclass comment typo _eq__ -> __eq__ (GH-26433) (GH-26436)
Miss Islington (bot) [Sat, 29 May 2021 01:07:27 +0000 (18:07 -0700)] 
Fix dataclass comment typo _eq__ -> __eq__ (GH-26433) (GH-26436)

(cherry picked from commit 7e6f2375698036d62464c238059ef2073755fdaf)

Co-authored-by: Sean Grady <vedicmonk@gmail.com>
Co-authored-by: Sean Grady <vedicmonk@gmail.com>
4 years agobpo-44252: Correctly implement gc support for SSLError objects (GH-26439) (GH-26441)
Miss Islington (bot) [Fri, 28 May 2021 23:47:36 +0000 (16:47 -0700)] 
bpo-44252: Correctly implement gc support for SSLError objects (GH-26439) (GH-26441)

(cherry picked from commit 8b4312b909abff3100c1f18fb3efa5c25617fee3)

Co-authored-by: Pablo Galindo <Pablogsal@gmail.com>
4 years agobpo-44249: Fix 3 README.rst typos (GH-26385)
Miss Islington (bot) [Fri, 28 May 2021 20:03:10 +0000 (13:03 -0700)] 
bpo-44249: Fix 3 README.rst typos (GH-26385)

(cherry picked from commit acac6c71ff370413374c6aca1df808c426e8a30c)

Co-authored-by: Ayush Parikh <ayushparikh332@gmail.com>
4 years ago[3.10] bpo-42972: Fully support GC for _winapi.Overlapped (GH-26381) (#26430)
Ken Jin [Fri, 28 May 2021 17:47:15 +0000 (01:47 +0800)] 
[3.10] bpo-42972: Fully support GC for _winapi.Overlapped (GH-26381)  (#26430)

* bpo-42972: Fully support GC for _winapi.Overlapped (GH-26381)

* untrack earlier

4 years agobpo-42972: Fully implement GC protocol for functools LRU cache (GH-26423)
Miss Islington (bot) [Fri, 28 May 2021 14:26:07 +0000 (07:26 -0700)] 
bpo-42972: Fully implement GC protocol for functools LRU cache (GH-26423)

(cherry picked from commit 3f8d33252722750e6c019d3df7ce0fabf7bdd45e)

Co-authored-by: Erlend Egeberg Aasland <erlend.aasland@innova.no>
4 years agobpo-42972: Fully implement GC protocol for functools keywrapper and partial types...
Miss Islington (bot) [Fri, 28 May 2021 09:08:01 +0000 (02:08 -0700)] 
bpo-42972: Fully implement GC protocol for functools keywrapper and partial types (GH-26363) (GH-26424)

(cherry picked from commit 8994e9c2cd775ddf7b0723824da53fe0d7c039ac)

Co-authored-by: Erlend Egeberg Aasland <erlend.aasland@innova.no>
4 years agobpo-44256: Do not expose _functools._list_elem_type (GH-26416)
Miss Islington (bot) [Fri, 28 May 2021 07:10:45 +0000 (00:10 -0700)] 
bpo-44256: Do not expose _functools._list_elem_type (GH-26416)

It is internal use only type.
(cherry picked from commit 28be3191a9db2769ed05e55c6bcbccdd029656dd)

Co-authored-by: Inada Naoki <songofacandy@gmail.com>
4 years agobpo-41611: IDLE: Catch TclError exceptions in AutoCompleteWindow.winconfig_event...
Miss Islington (bot) [Fri, 28 May 2021 06:39:36 +0000 (23:39 -0700)] 
bpo-41611: IDLE: Catch TclError exceptions in AutoCompleteWindow.winconfig_event() (GH-26404)

Since the <Configure> event may occur after the
completion window is gone, catch potential
TclError exceptions when accessing acw.

(cherry picked from commit 4e2e5c1c4f792b4011e4c78d011baea2aee39f1b)

4 years agobpo-42972: Fully implement GC protocol for re types (GH-26368) (GH-26414)
Miss Islington (bot) [Fri, 28 May 2021 00:23:37 +0000 (17:23 -0700)] 
bpo-42972: Fully implement GC protocol for re types (GH-26368) (GH-26414)

(cherry picked from commit fba42d11880f444bb94d9891e3949f082a57b9a9)

Co-authored-by: Erlend Egeberg Aasland <erlend.aasland@innova.no>
4 years ago[3.10] bpo-44246: Update What's New for importlib.metadata. (GH-26408) (GH-26415)
Miss Islington (bot) [Thu, 27 May 2021 23:57:04 +0000 (16:57 -0700)] 
[3.10] bpo-44246: Update What's New for importlib.metadata. (GH-26408) (GH-26415)

* [bpo-44246](): Update What's New for importlib.metadata.

Bump version of importlib_metadata included.
Add note about compatibility notice and fix link to entry_points documentation.
Add note about removal of access by index on Distribution.entry_points.

* Fix syntax mistake in issue reference.

Co-authored-by: Ken Jin <28750310+Fidget-Spinner@users.noreply.github.com>
* Fix broken reference in entry-points.

Co-authored-by: Ken Jin <28750310+Fidget-Spinner@users.noreply.github.com>
(cherry picked from commit 28f12c9f4f39d283d823d81e311d863526dfdb54)

Co-authored-by: Jason R. Coombs <jaraco@jaraco.com>
Automerge-Triggered-By: GH:jaraco
4 years agobpo-42972: Fully support GC protocol for _operator heap types (GH-26371) (GH-26413)
Miss Islington (bot) [Thu, 27 May 2021 21:49:43 +0000 (14:49 -0700)] 
bpo-42972: Fully support GC protocol for _operator heap types (GH-26371) (GH-26413)

(cherry picked from commit f4b70c22c8e37dd7a06702e30b121a6651683421)

Co-authored-by: Erlend Egeberg Aasland <erlend.aasland@innova.no>
4 years agobpo-43667: Add news fragment for Solaris changes (GH-26405) (GH-26409)
Miss Islington (bot) [Thu, 27 May 2021 17:23:43 +0000 (10:23 -0700)] 
bpo-43667: Add news fragment for Solaris changes (GH-26405) (GH-26409)

(cherry picked from commit 164a4f46d1606e21d82babc010e397a9116e6730)

Co-authored-by: Jakub Kulík <Kulikjak@gmail.com>
4 years agobpo-42972: Fully support GC for mmap heap types (GH-26373)
Miss Islington (bot) [Thu, 27 May 2021 16:43:56 +0000 (09:43 -0700)] 
bpo-42972: Fully support GC for mmap heap types (GH-26373)

(cherry picked from commit 318adeba780851c416505e48a3454cacca831419)

Co-authored-by: Erlend Egeberg Aasland <erlend.aasland@innova.no>
4 years agobpo-42972: Fully support GC protocol for _queue.SimpleQueue (GH-26372) (GH-26406)
Miss Islington (bot) [Thu, 27 May 2021 16:25:50 +0000 (09:25 -0700)] 
bpo-42972: Fully support GC protocol for _queue.SimpleQueue (GH-26372) (GH-26406)

(cherry picked from commit 4d7f8f9f7fb09ea8eb4e43409a16a91b0bf18571)

Co-authored-by: Erlend Egeberg Aasland <erlend.aasland@innova.no>
4 years agobpo-42972: Fully implement GC protocol for ssl heap types (GH-26370) (GH-26399)
Miss Islington (bot) [Thu, 27 May 2021 16:25:22 +0000 (09:25 -0700)] 
bpo-42972: Fully implement GC protocol for ssl heap types (GH-26370) (GH-26399)

(cherry picked from commit dcb8786a9848516e823e090bb36079678913d8d3)

Co-authored-by: Erlend Egeberg Aasland <erlend.aasland@innova.no>
4 years agobpo-42972: Fully support GC for pyexpat, unicodedata, and dbm/gdbm heap types (GH...
Miss Islington (bot) [Thu, 27 May 2021 15:26:15 +0000 (08:26 -0700)] 
bpo-42972: Fully support GC for pyexpat, unicodedata, and dbm/gdbm heap types (GH-26376)

* bpo-42972: pyexpat
* bpo-42972: unicodedata
* bpo-42972: dbm/gdbm
(cherry picked from commit 59af59c2dfa52dcd5605185263f266a49ced934c)

Co-authored-by: Erlend Egeberg Aasland <erlend.aasland@innova.no>
4 years agobpo-41611: IDLE: fix freezing on completion on macOS (GH-26400)
Miss Islington (bot) [Thu, 27 May 2021 14:53:53 +0000 (07:53 -0700)] 
bpo-41611: IDLE: fix freezing on completion on macOS (GH-26400)

(cherry picked from commit abc4bd5db91c86b6b74289241378a13bd3a0a5e2)

Co-authored-by: Tal Einat <532281+taleinat@users.noreply.github.com>
4 years ago[3.10] bpo-38908: [docs] Add changes to 3.10 whatsnew and fix some minor inaccuracies...
Miss Islington (bot) [Thu, 27 May 2021 13:50:58 +0000 (06:50 -0700)] 
[3.10] bpo-38908: [docs] Add changes to 3.10 whatsnew and fix some minor inaccuracies in news (GH-26096) (GH-26337)

The fix only applies to ``isinstance``. ``issubclass`` isn't affected (because it was always working to begin with). So I also fixed the news to reflect that.
(cherry picked from commit 8450e8a81f6d54f45e1fc5c13a03878c9978750d)

Co-authored-by: Ken Jin <28750310+Fidget-Spinner@users.noreply.github.com>
4 years ago[3.10] bpo-42972: Fully support GC for hashlib heap types (GH-26374) (GH-26398)
Miss Islington (bot) [Thu, 27 May 2021 08:10:39 +0000 (01:10 -0700)] 
[3.10] bpo-42972: Fully support GC for hashlib heap types (GH-26374) (GH-26398)

(cherry picked from commit 6ef5ba391d700bde7ec3ffd5fb7132a30dd309c4)

Co-authored-by: Erlend Egeberg Aasland <erlend.aasland@innova.no>
Automerge-Triggered-By: GH:tiran
4 years ago[3.10] bpo-44241: Incorporate changes from importlib_metadata 4.1. (GH-26382) (GH...
Miss Islington (bot) [Thu, 27 May 2021 01:22:25 +0000 (18:22 -0700)] 
[3.10] bpo-44241: Incorporate changes from importlib_metadata 4.1. (GH-26382) (GH-26395)

(cherry picked from commit 06ac3a4742228b0230981720060248a7425b2486)

Co-authored-by: Jason R. Coombs <jaraco@jaraco.com>
Automerge-Triggered-By: GH:jaraco
4 years agobpo-42161: mathmodule.c: move _PyLong_GetOne() loop invariant (GH-26391) (GH-26393)
Miss Islington (bot) [Wed, 26 May 2021 23:13:17 +0000 (16:13 -0700)] 
bpo-42161: mathmodule.c: move _PyLong_GetOne() loop invariant (GH-26391) (GH-26393)

Move _PyLong_GetZero() and _PyLong_GetOne() loop invariants outside
loops in functions:

* math.comb()
* math.gcd()
* math.lcm()
* math.perm()
(cherry picked from commit 3e7ee02327db13e4337374597cdc4458ecb9e3ad)

Co-authored-by: Victor Stinner <vstinner@python.org>
4 years ago[3.10] bpo-42392: [docs] Add deprecated-removed loop labels for asyncio (GH-26357...
Miss Islington (bot) [Wed, 26 May 2021 22:19:42 +0000 (15:19 -0700)] 
[3.10] bpo-42392: [docs] Add deprecated-removed loop labels for asyncio (GH-26357) (GH-26390)

* Add deprecated-removed loop labels for all reelvant functions/classes in asyncio
(cherry picked from commit d8fd8c8568cbc2f53c1abeda3596a89a46f0e3d7)

Co-authored-by: Ken Jin <28750310+Fidget-Spinner@users.noreply.github.com>
Automerge-Triggered-By: GH:gpshead
4 years agobpo-38693: Prefer f-strings in importlib.resources (importlib_resources 5.0.6). ...
Miss Islington (bot) [Wed, 26 May 2021 21:09:27 +0000 (14:09 -0700)] 
bpo-38693: Prefer f-strings in importlib.resources (importlib_resources 5.0.6). (GH-26387) (#26389)

Automerge-Triggered-By: GH:jaraco
(cherry picked from commit f6fbdb90ee450ad693f7a7809035d0dc968f98b7)

Co-authored-by: Jason R. Coombs <jaraco@jaraco.com>
Co-authored-by: Jason R. Coombs <jaraco@jaraco.com>
4 years agobpo-38693: importlib.metadata f-strings (GH-26383)
Miss Islington (bot) [Wed, 26 May 2021 19:11:41 +0000 (12:11 -0700)] 
bpo-38693: importlib.metadata f-strings (GH-26383)

Automerge-Triggered-By: GH:jaraco
(cherry picked from commit e6c815d2e34be5fdf6dbe773f0781691746d2289)

Co-authored-by: Jason R. Coombs <jaraco@jaraco.com>
4 years agobpo-41147: [doc] contextlib.redirect_stdout() provides the new stream as context...
Miss Islington (bot) [Wed, 26 May 2021 14:34:22 +0000 (07:34 -0700)] 
bpo-41147: [doc] contextlib.redirect_stdout() provides the new stream as context var (GH-21199) (GH-26379)

(cherry picked from commit 46db39d7bd67fb9fea133cd4f18cdf7eacb0f6d9)

Co-authored-by: Peter Law <PeterJCLaw@gmail.com>
4 years agobpo-44232: Fix type_new() error reporting (GH-26359) (GH-26365)
Miss Islington (bot) [Wed, 26 May 2021 09:30:55 +0000 (02:30 -0700)] 
bpo-44232: Fix type_new() error reporting (GH-26359) (GH-26365)

Fix a regression in type() when a metaclass raises an exception. The
C function type_new() must properly report the exception when a
metaclass constructor raises an exception and the winner class is not
the metaclass.
(cherry picked from commit bd199e72fb60a8ff001a023f23925092a290be91)

Co-authored-by: Victor Stinner <vstinner@python.org>
4 years agoPoint to recent link to PyFLTK (GH-26315) (GH-26366)
Miss Islington (bot) [Tue, 25 May 2021 21:04:26 +0000 (14:04 -0700)] 
Point to recent link to PyFLTK (GH-26315) (GH-26366)

(cherry picked from commit ee3d78ef730116f2c43afc248d207ca1d47eee08)

Co-authored-by: Mark <mark@qtrac.eu>
Co-authored-by: Mark <mark@qtrac.eu>
4 years agobpo-42972: Fully implement GC protocol for arraymodule types (GH-26114)
Miss Islington (bot) [Tue, 25 May 2021 18:49:19 +0000 (11:49 -0700)] 
bpo-42972: Fully implement GC protocol for arraymodule types (GH-26114)

(cherry picked from commit bd404ccac0d3e8358995ac0cbeec9373bb6c4d96)

Co-authored-by: Erlend Egeberg Aasland <erlend.aasland@innova.no>
4 years agobpo-42972: Fully implement GC protocol for sqlite3 heap types (GH-26104)
Miss Islington (bot) [Tue, 25 May 2021 18:08:39 +0000 (11:08 -0700)] 
bpo-42972: Fully implement GC protocol for sqlite3 heap types (GH-26104)

(cherry picked from commit d3c277a59c3d93fb92f7026f63678083d1d49fc5)

Co-authored-by: Erlend Egeberg Aasland <erlend.aasland@innova.no>
4 years agobpo-20408: Fix memoryview() signature in docs (GH-24431)
Miss Islington (bot) [Tue, 25 May 2021 14:30:00 +0000 (07:30 -0700)] 
bpo-20408: Fix memoryview() signature in docs (GH-24431)

(cherry picked from commit d18e5dae914b1db49b25ed7729c07a535d1f0c52)

Co-authored-by: Mariusz Felisiak <felisiak.mariusz@gmail.com>
4 years agobpo-43795: Remove Py_FrozenMain from the Limited API & Stable ABI (GH-26241) (GH...
Miss Islington (bot) [Tue, 25 May 2021 11:59:10 +0000 (04:59 -0700)] 
bpo-43795: Remove Py_FrozenMain from the Limited API & Stable ABI  (GH-26241) (GH-26353)

Py_FrozenMain was added to the Limited C API in [bpo-42591]() (3.10.0a4);
but to fix that issue it would be enough to add it to the regular C API.

The function is undocumented, tests were added very recently ([bpo-44131]()),
and most importantly, it is not present in all builds of Python, as
the linker sometimes omits it as unused.
It should be added back when these issues are fixed.

Note that this does not affect Python's regular C API.
(cherry picked from commit d16856960e33bc5f64fc5b842f132058becafa37)

Co-authored-by: Petr Viktorin <encukou@gmail.com>
Co-authored-by: Petr Viktorin <encukou@gmail.com>
4 years agobpo-43109: configure doc: LTO requires "ar" on macOS (GH-26349)
Miss Islington (bot) [Tue, 25 May 2021 10:56:37 +0000 (03:56 -0700)] 
bpo-43109: configure doc: LTO requires "ar" on macOS (GH-26349)

(cherry picked from commit 63f17c252ab1b9357c5f022296213c42d9629458)

Co-authored-by: Victor Stinner <vstinner@python.org>
4 years agobpo-44151: Various grammar, word order, and markup fixes (GH-26344) (GH-26345)
Miss Islington (bot) [Tue, 25 May 2021 06:23:10 +0000 (23:23 -0700)] 
bpo-44151: Various grammar, word order, and markup fixes (GH-26344) (GH-26345)

4 years agobpo-43109: Fix --with-lto configure option on macOS (GH-26341)
Miss Islington (bot) [Tue, 25 May 2021 04:18:53 +0000 (21:18 -0700)] 
bpo-43109: Fix --with-lto configure option on macOS (GH-26341)

Allow --with-lto configure option to work with Apple-supplied Xcode or
Command Line Tools which do not provide llvm-ar.
(cherry picked from commit 59acfd4a09df1c141dac7845eed008af8970fce7)

Co-authored-by: Ned Deily <nad@python.org>
4 years agobpo-44151: linear_regression() minor API improvements (GH-26199) (GH-26338)
Miss Islington (bot) [Tue, 25 May 2021 01:11:12 +0000 (18:11 -0700)] 
bpo-44151: linear_regression() minor API improvements (GH-26199) (GH-26338)

4 years agobpo-41282: Fix broken `make install` (GH-26329)
Miss Islington (bot) [Mon, 24 May 2021 23:13:19 +0000 (16:13 -0700)] 
bpo-41282: Fix broken `make install` (GH-26329)

A previous commit broke a check in sysconfig when building cpython itself.
This caused builds of the standard library modules to search a wrong
location (the installed location rather than the source directory) for
header files with the net effect that a ``make install``
incorrectly caused all extension modules to be rebuilt again and
with incorrect include file paths.

When building Python, we need two distinct "include" directories:
- source .h files
- install target for .h files

Note that this doesn't matter except when building Python from source.

Historically:
- source .h files were in the distutils scheme under 'include'
- the install directory was in the distutils.command.install scheme
    under 'headers'

GH-24549 merged these; sysconfig is now the single source of truth and
distutils is derived from it.

This commit introduces a "secret" scheme path, 'headers', which contains
the install target. It is only present when building Python.
The distutils code uses it if present, and falls back to 'include'.

Co-authored-by: Ned Deily <nad@python.org>
(cherry picked from commit 563bd5a4dcc6a26e47966cb66db64859902bce76)

Co-authored-by: Petr Viktorin <encukou@gmail.com>
4 years agobpo-44195: Use 'TraversableResources' in the docs to match the implementation. (GH...
Miss Islington (bot) [Mon, 24 May 2021 17:30:05 +0000 (10:30 -0700)] 
bpo-44195: Use 'TraversableResources' in the docs to match the implementation. (GH-26317)

(cherry picked from commit 7148293d96843ca868961313b00361504ec0c242)

Co-authored-by: Jason R. Coombs <jaraco@jaraco.com>
4 years agoFix typo in whatsnew/3.10.rst (GH-26310) (GH-26323)
Miss Islington (bot) [Sun, 23 May 2021 22:12:13 +0000 (15:12 -0700)] 
Fix typo in whatsnew/3.10.rst (GH-26310) (GH-26323)

(cherry picked from commit 3ad101b3175c102e252161a1b8b928e694de8c94)

Co-authored-by: Tushar Sadhwani <tushar.sadhwani000@gmail.com>
4 years agobpo-43207: InspectLoader.is_package is not an abstract method (GH-24517)
Miss Islington (bot) [Sun, 23 May 2021 19:37:16 +0000 (12:37 -0700)] 
bpo-43207: InspectLoader.is_package is not an abstract method (GH-24517)

Making the description of `InspectLoader.is_package` aligned with the current implementation.

Automerge-Triggered-By: GH:jaraco
(cherry picked from commit 8b9310d90281d4bd3643f4e0767b2d0390f0cb05)

Co-authored-by: Junnosuke Kuroda <Isa-rentacs@users.noreply.github.com>
4 years agobpo-44210: make importlib.metadata._meta.PackageMetadata public (GH-26299)
Miss Islington (bot) [Sun, 23 May 2021 19:29:17 +0000 (12:29 -0700)] 
bpo-44210: make importlib.metadata._meta.PackageMetadata public (GH-26299)

Signed-off-by: Filipe Laíns <lains@riseup.net>
Automerge-Triggered-By: GH:jaraco
(cherry picked from commit df7eeacd83f531dd67cec7bc483dec6dce17ddbd)

Co-authored-by: Filipe Laíns <lains@riseup.net>
4 years agobpo-44201: Avoid side effects of "invalid_*" rules in the REPL (GH-26298) (GH-26313)
Miss Islington (bot) [Sat, 22 May 2021 22:23:26 +0000 (15:23 -0700)] 
bpo-44201: Avoid side effects of "invalid_*" rules in the REPL (GH-26298) (GH-26313)

When the parser does a second pass to check for errors, these rules can
have some small side-effects as they may advance the parser more than
the point reached in the first pass. This can cause the tokenizer to ask
for extra tokens in interactive mode causing the tokenizer to show the
prompt instead of failing instantly.

To avoid this, add a new mode to the tokenizer that is activated in the
second pass and deactivates asking for new tokens when the interactive
line is finished. As the parsing should have reached the last line in
the first pass, the second pass should not need to ask for more tokens.

(cherry picked from commit bd7476dae337e905e7b1bbf33ddb96cc270fdc84)

Co-authored-by: Pablo Galindo <Pablogsal@gmail.com>
4 years agobpo-30757: Improve "How to make stand-alone binaries" FAQ (GH-26309) (GH-26311)
Miss Islington (bot) [Sat, 22 May 2021 22:23:03 +0000 (15:23 -0700)] 
bpo-30757: Improve "How to make stand-alone binaries" FAQ (GH-26309) (GH-26311)

Co-authored-by: denfromufa <denfromufa@users.noreply.github.com>
Co-authored-by: Ken Jin <28750310+Fidget-Spinner@users.noreply.github.com>
(cherry picked from commit 2a1e6698b10a7b58c6ac66429de0f51cb739da35)

Co-authored-by: Erlend Egeberg Aasland <erlend.aasland@innova.no>
Co-authored-by: Erlend Egeberg Aasland <erlend.aasland@innova.no>
4 years agoRemove duplicate words in docs. (GH-26167) (GH-26296)
Miss Islington (bot) [Sat, 22 May 2021 20:55:17 +0000 (13:55 -0700)] 
Remove duplicate words in docs. (GH-26167) (GH-26296)

(cherry picked from commit b06ed1d883cd79c920c514d8a1f4643cf93dc5e0)

Co-authored-by: Mariusz Felisiak <felisiak.mariusz@gmail.com>
4 years agobpo-44184: Fix subtype_dealloc() for freed type (GH-26274) (GH-26290)
Miss Islington (bot) [Fri, 21 May 2021 22:50:11 +0000 (15:50 -0700)] 
bpo-44184: Fix subtype_dealloc() for freed type (GH-26274) (GH-26290)

Fix a crash at Python exit when a deallocator function removes the
last strong reference to a heap type.

Don't read type memory after calling basedealloc() since
basedealloc() can deallocate the type and free its memory.

_PyMem_IsPtrFreed() argument is now constant.
(cherry picked from commit 615069eb08494d089bf24e43547fbc482ed699b8)

Co-authored-by: Victor Stinner <vstinner@python.org>
Co-authored-by: Victor Stinner <vstinner@python.org>
4 years agoSpecify Python Cookbook edition for reference (GH-26301) (#26302)
Miss Islington (bot) [Fri, 21 May 2021 22:48:56 +0000 (15:48 -0700)] 
Specify Python Cookbook edition for reference (GH-26301) (#26302)

(cherry picked from commit 604cd71e501b3bb1ede2b8abc797643fc2e9129c)

Co-authored-by: Terry Jan Reedy <tjreedy@udel.edu>
4 years agobpo-44180: Fix edge cases in invalid assigment rules in the parser (GH-26283)
Miss Islington (bot) [Fri, 21 May 2021 18:20:43 +0000 (11:20 -0700)] 
bpo-44180: Fix edge cases in invalid assigment rules in the parser (GH-26283)

The invalid assignment rules are very delicate since the parser can
easily raise an invalid assignment when a keyword argument is provided.
As they are very deep into the grammar tree, is very difficult to
specify in which contexts these rules can be used and in which don't.
For that, we need to use a different version of the rule that doesn't do
error checking in those situations where we don't want the rule to raise
(keyword arguments and generator expressions).

We also need to check if we are in left-recursive rule, as those can try
to eagerly advance the parser even if the parse will fail at the end of
the expression. Failing to do this allows the parser to start parsing a
call as a tuple and incorrectly identify a keyword argument as an
invalid assignment, before it realizes that it was not a tuple after all.
(cherry picked from commit c878a9796841c1f4726e6dd5ac49a478af4c8504)

Co-authored-by: Pablo Galindo <Pablogsal@gmail.com>
4 years agobpo-43927: Change 'IOError' to 'OSError' (GH-26289)
Miss Islington (bot) [Fri, 21 May 2021 18:15:36 +0000 (11:15 -0700)] 
bpo-43927: Change 'IOError' to 'OSError' (GH-26289)

This is the last remaining instance, at least for this chapter, in 3.10 & 3.11.
(cherry picked from commit 2f47d8dcc735234bf9c7f92fbdacd8c5a6ee7761)

Co-authored-by: Terry Jan Reedy <tjreedy@udel.edu>
4 years ago[3.10] bpo-43643: Sync with python/importlib_resources@c17a610aad. (GH-26284) (GH...
Miss Islington (bot) [Fri, 21 May 2021 17:52:24 +0000 (10:52 -0700)] 
[3.10] bpo-43643: Sync with python/importlib_resources@c17a610aad. (GH-26284) (GH-26286)

* [bpo-43643](): Sync with python/importlib_resources@c17a610aad.
* Sync with python/importlib_resources@89fd5e961a.
(cherry picked from commit 875b3d84b3072b2d3c352ad9f0ff52c441fbd12e)

Co-authored-by: Jason R. Coombs <jaraco@jaraco.com>
Automerge-Triggered-By: GH:jaraco
4 years ago[doc] Fix indentation in inspect documentation (GH-24846) (GH-26287)
Miss Islington (bot) [Fri, 21 May 2021 17:06:41 +0000 (10:06 -0700)] 
[doc] Fix indentation in inspect documentation (GH-24846) (GH-26287)

(cherry picked from commit 642fdfdc04e8e40c2cd3e65d67b09fac472bb345)

Co-authored-by: Numerlor <25886452+Numerlor@users.noreply.github.com>
4 years agobpo-44180: Report generic syntax errors in the furthest position reached in the first...
Miss Islington (bot) [Fri, 21 May 2021 15:29:58 +0000 (08:29 -0700)] 
bpo-44180: Report generic syntax errors in the furthest position reached in the first parser pass (GH-26253) (GH-26281)

(cherry picked from commit b51081c1a8cf01b92ba0692173e1b9274a57f455)

Co-authored-by: Pablo Galindo <Pablogsal@gmail.com>
4 years ago[3.10] bpo-43882 - Mention urllib.parse changes in Whats new section. (GH-26275)
Senthil Kumaran [Fri, 21 May 2021 12:29:24 +0000 (05:29 -0700)] 
[3.10] bpo-43882 - Mention urllib.parse changes in Whats new section. (GH-26275)

* [3.10] bpo-43882 - Mention urllib.parse changes in Whats new section.

* escape the \n chars, ReSTify :rfc:, urllib.parse is a :mod:

* minor formatting.

Co-authored-by: Gregory P. Smith <greg@krypto.org>
4 years ago[3.10] bpo-38671: Add test that `pathlib.Path.resolve()` returns an absolute path...
Barney Gale [Fri, 21 May 2021 11:54:56 +0000 (12:54 +0100)] 
[3.10] bpo-38671: Add test that `pathlib.Path.resolve()` returns an absolute path. (GH-26184) (GH-26270)

Issue should be fixed in [bpo-43757]()

Co-Authored-by: Tzu-ping Chung <uranusjr@gmail.com>
(cherry picked from commit 18f41c04ff4161531f4d08631059fd3ed37c0218)

Co-authored-by: Barney Gale <barney.gale@gmail.com>
Automerge-Triggered-By: GH:encukou
4 years agobpo-38820: Test with OpenSSL 3.0.0-alpha17 (GH-26266)
Miss Islington (bot) [Thu, 20 May 2021 15:10:52 +0000 (08:10 -0700)] 
bpo-38820: Test with OpenSSL 3.0.0-alpha17 (GH-26266)

(cherry picked from commit 7109624d45bcf28fbb46a53354785dc5ff953a16)

Co-authored-by: Christian Heimes <christian@python.org>
4 years agobpo-36160: Fix test_site so that it can run independently of other tests (GH-12131...
Miss Islington (bot) [Thu, 20 May 2021 10:42:00 +0000 (03:42 -0700)] 
bpo-36160: Fix test_site so that it can run independently of other tests (GH-12131) (GH-26262)

(cherry picked from commit 1270ad6ec8fe1f71e7d88086474f96f99670ac3a)

Co-authored-by: native-api <vano@mail.mipt.ru>
4 years agoUpdate link in SECURITY.md (GH-21320) (GH-26259)
Miss Islington (bot) [Thu, 20 May 2021 02:06:17 +0000 (19:06 -0700)] 
Update link in SECURITY.md (GH-21320) (GH-26259)

(cherry picked from commit 4d396e7d79bd1152f991147718dc5f094a3cc957)

Co-authored-by: Marcono1234 <Marcono1234@users.noreply.github.com>
4 years ago[doc] Fix typo in asyncio-eventloop documentation (GH-22311) (GH-26256)
Miss Islington (bot) [Wed, 19 May 2021 21:19:53 +0000 (14:19 -0700)] 
[doc] Fix typo in asyncio-eventloop documentation (GH-22311) (GH-26256)

(cherry picked from commit b66a03a49157076cb15a002aaf44a011cc79be3b)

Co-authored-by: Bruno <brunogeninatti@gmail.com>
4 years agobpo-40975: [doc] Identify AsyncExitStack.enter_async_context()/aclose() as coroutine...
Miss Islington (bot) [Wed, 19 May 2021 20:37:32 +0000 (13:37 -0700)] 
bpo-40975: [doc] Identify AsyncExitStack.enter_async_context()/aclose() as coroutine methods (GH-20870) (GH-26254)

(cherry picked from commit c054e8f78f53035e06d6dc58c423d76c8a5fa39a)

Co-authored-by: naglis <naglis@users.noreply.github.com>
4 years agoFix compiler warning for misleading guarding in the tkinter (GH-26244) (GH-26251)
Miss Islington (bot) [Wed, 19 May 2021 18:46:45 +0000 (11:46 -0700)] 
Fix compiler warning for misleading guarding in the tkinter (GH-26244) (GH-26251)

The newest gcc emmits this warning:

```
/Modules/_tkinter.c:272:9: warning: this ‘if’ clause does not guard... [-Wmisleading-indentation]
  272 |         if(tcl_lock)PyThread_acquire_lock(tcl_lock, 1); tcl_tstate = tstate; }
      |         ^~
/Modules/_tkinter.c:2869:5: note: in expansion of macro ‘LEAVE_PYTHON’
 2869 |     LEAVE_PYTHON
      |     ^~~~~~~~~~~~
/Modules/_tkinter.c:243:5: note: ...this statement, but the latter is misleadingly indented as if it were guarded by the ‘if’
  243 |     (*(PyThreadState**)Tcl_GetThreadData(&state_key, sizeof(PyThreadState*)))
      |     ^
/Modules/_tkinter.c:272:57: note: in expansion of macro ‘tcl_tstate’
  272 |         if(tcl_lock)PyThread_acquire_lock(tcl_lock, 1); tcl_tstate = tstate; }
      |                                                         ^~~~~~~~~~
/Modules/_tkinter.c:2869:5: note: in expansion of macro ‘LEAVE_PYTHON’
 2869 |     LEAVE_PYTHON

```

that's because the macro packs together two statements at the same level
as the "if". The warning is misleading but is very noisy so it makes
sense to fix it.
(cherry picked from commit 95d04710c5fb0df5393b5add2c5c2de2412673eb)

Co-authored-by: Pablo Galindo <Pablogsal@gmail.com>
Co-authored-by: Pablo Galindo <Pablogsal@gmail.com>
4 years agobpo-44168: Fix error message in the parser for keyword arguments for invalid expressi...
Miss Islington (bot) [Wed, 19 May 2021 18:28:31 +0000 (11:28 -0700)] 
bpo-44168: Fix error message in the parser for keyword arguments for invalid expressions (GH-26210) (GH-26247)

(cherry picked from commit 33c0c90dea06fda1df99482521559ebef7210bea)

Co-authored-by: Pablo Galindo <Pablogsal@gmail.com>
Co-authored-by: Pablo Galindo <Pablogsal@gmail.com>
4 years agoFix compiler warning in the xml module (GH-26245) (GH-26249)
Miss Islington (bot) [Wed, 19 May 2021 18:21:19 +0000 (11:21 -0700)] 
Fix compiler warning in the xml module (GH-26245) (GH-26249)

The newest version of gcc complains about passing un-initialized arrays
as constant pointers:

```
/Modules/expat/xmltok_ns.c: In function ‘findEncodingNS’:
/Modules/expat/xmltok.h:272:10: warning: ‘buf’ may be used uninitialized [-Wmaybe-uninitialized]
  272 |   (((enc)->utf8Convert)(enc, fromP, fromLim, toP, toLim))
      |   ~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/Modules/expat/xmltok_ns.c:95:3: note: in expansion of macro ‘XmlUtf8Convert’
   95 |   XmlUtf8Convert(enc, &ptr, end, &p, p + ENCODING_MAX - 1);
      |   ^~~~~~~~~~~~~~
/Modules/expat/xmltok.h:272:10: note: by argument 5 of type ‘const char *’ to ‘enum XML_Convert_Result(const ENCODING *, const char **, const char *, char **, const char *)’ {aka ‘enum XML_Convert_Result(const struct encoding *, const char **, const char *, char **, const char *)’}
  272 |   (((enc)->utf8Convert)(enc, fromP, fromLim, toP, toLim))
      |   ~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/Modules/expat/xmltok_ns.c:95:3: note: in expansion of macro ‘XmlUtf8Convert’
   95 |   XmlUtf8Convert(enc, &ptr, end, &p, p + ENCODING_MAX - 1);
      |   ^~~~~~~~~~~~~~
In file included from /Modules/expat/xmltok.c:1657:
/Modules/expat/xmltok_ns.c:92:8: note: ‘buf’ declared here
   92 |   char buf[ENCODING_MAX];

```
(cherry picked from commit be93f81e58ba3742589259ef84325a95b547e424)

Co-authored-by: Pablo Galindo <Pablogsal@gmail.com>
Co-authored-by: Pablo Galindo <Pablogsal@gmail.com>
4 years agobpo-44010: IDLE: colorize pattern-matching soft keywords (GH-25851)
Miss Islington (bot) [Wed, 19 May 2021 09:44:14 +0000 (02:44 -0700)] 
bpo-44010: IDLE: colorize pattern-matching soft keywords (GH-25851)

(cherry picked from commit 60d343a81679ea90ae0e08fadcd132c16906a51a)

Co-authored-by: Tal Einat <532281+taleinat@users.noreply.github.com>
4 years agobpo-35765: Clarify references to "object x" in the JSON tutorial (GH-22411) (GH-26218)
Miss Islington (bot) [Wed, 19 May 2021 08:59:23 +0000 (01:59 -0700)] 
bpo-35765: Clarify references to "object x" in the JSON tutorial (GH-22411) (GH-26218)

(cherry picked from commit 4fdcc39f711e1b586a94e2c5088fdd7e78fd9f58)

Co-authored-by: Zackery Spytz <zspytz@gmail.com>
4 years agobpo-44106: Purge unused sqlite3 doc includes (GH-26234)
Miss Islington (bot) [Wed, 19 May 2021 08:17:19 +0000 (01:17 -0700)] 
bpo-44106: Purge unused sqlite3 doc includes (GH-26234)

(cherry picked from commit d798acc8733b605f7fc9c3c1a85cd14ee2a56add)

Co-authored-by: Erlend Egeberg Aasland <erlend.aasland@innova.no>
4 years agobpo-44106: Improve sqlite3 example database contents (GH-26027)
Miss Islington (bot) [Wed, 19 May 2021 07:44:00 +0000 (00:44 -0700)] 
bpo-44106: Improve sqlite3 example database contents (GH-26027)

(cherry picked from commit 92d1064727d6b7f4136f9c09ab52ae15e3676afe)

Co-authored-by: Erlend Egeberg Aasland <erlend.aasland@innova.no>
4 years agobpo-30593: Doc'ed that executescript() disregards isolation level (GH-26220)
Miss Islington (bot) [Wed, 19 May 2021 07:37:33 +0000 (00:37 -0700)] 
bpo-30593: Doc'ed that executescript() disregards isolation level (GH-26220)

(cherry picked from commit 901443757333a66ff2b5c85eba30dc1c48eac321)

Co-authored-by: Erlend Egeberg Aasland <erlend.aasland@innova.no>
4 years ago[3.10] bpo-41963: document that ConfigParser strips off comments (GH-26197) (GH-26214)
Łukasz Langa [Tue, 18 May 2021 17:03:09 +0000 (19:03 +0200)] 
[3.10] bpo-41963: document that ConfigParser strips off comments (GH-26197) (GH-26214)

Co-authored-by: blurb-it[bot] <43283697+blurb-it[bot]@users.noreply.github.com>
Co-authored-by: Laura Gutierrez Funderburk <58710704+lgfunderburk@users.noreply.github.com>
Co-authored-by: Jürgen Gmach <juergen.gmach@googlemail.com>
(cherry picked from commit 02ee8191263848f8c8999f72286148946b83e5c9)

4 years ago[3.10] bpo-25872: Add unit tests for linecache and threading (GH-25913) (GH-26212)
Irit Katriel [Tue, 18 May 2021 13:53:57 +0000 (14:53 +0100)] 
[3.10] bpo-25872: Add unit tests for linecache and threading (GH-25913) (GH-26212)

(cherry picked from commit 115dea9e2602b96b63390f00cc880e90c433efa2)

Co-authored-by: uniocto <serit142sa33go@gmail.com>
4 years agobpo-33433 Fix private address checking for IPv4 mapped IPv6. (GH-26172)
Miss Islington (bot) [Mon, 17 May 2021 19:42:08 +0000 (12:42 -0700)] 
bpo-33433 Fix private address checking for IPv4 mapped IPv6. (GH-26172)

For IPv4 mapped IPv6 addresses, defer privacy check to the mapped IPv4 address. Solves bug where public mapped IPv4 addresses are considered private by the IPv6 check.

Automerge-Triggered-By: GH:gpshead
(cherry picked from commit 83f0f8d62f279f846a92fede2244beaa0149b9d8)

Co-authored-by: Pete Wicken <2273100+JamoBox@users.noreply.github.com>
4 years agobpo-43650: Fix MemoryError on zip.read in shutil._unpack_zipfile for large files...
Miss Islington (bot) [Mon, 17 May 2021 17:35:30 +0000 (10:35 -0700)] 
bpo-43650: Fix MemoryError on zip.read in shutil._unpack_zipfile for large files (GH-25058) (GH-26190)

`shutil.unpack_archive()` tries to read the whole file into memory, making no use of any kind of smaller buffer. Process crashes for really large files: I.e. archive: ~1.7G, unpacked: ~10G. Before the crash it can easily take away all available RAM on smaller systems. Had to pull the code form `zipfile.Zipfile.extractall()` to fix this

Automerge-Triggered-By: GH:gpshead
(cherry picked from commit f32c7950e0077b6d9a8e217c2796fc582f18ca08)

Co-authored-by: Igor Bolshakov <ibolsch@gmail.com>
4 years agobpo-44145: Release the GIL around HMAC_Update. (GH-26157)
Miss Islington (bot) [Mon, 17 May 2021 08:03:57 +0000 (01:03 -0700)] 
bpo-44145: Release the GIL around HMAC_Update. (GH-26157)

It was always meant to be released for parallelization.
This now matches the other similar code in the module.

Thanks michaelforney for noticing!
(cherry picked from commit c10392e7ddb3eafbd11e9ffe335c07648426715f)

Co-authored-by: Gregory P. Smith <greg@krypto.org>
4 years agoApply edits from Allen Downey's review of the linear_regression docs. (GH-26176)...
Miss Islington (bot) [Mon, 17 May 2021 02:47:57 +0000 (19:47 -0700)] 
Apply edits from Allen Downey's review of the linear_regression docs. (GH-26176) (GH-26185)

4 years ago[doc] Fix typo in os module (GH-24464)
Miss Islington (bot) [Sun, 16 May 2021 23:59:12 +0000 (16:59 -0700)] 
[doc] Fix typo in os module (GH-24464)

Automerge-Triggered-By: GH:iritkatriel
(cherry picked from commit fdc7e52f5f1853e350407c472ae031339ac7f60c)

Co-authored-by: Rafael Fontenelle <rffontenelle@users.noreply.github.com>
4 years agofix docstring typo in bdb.py (GH-22323) (#26179)
Miss Islington (bot) [Sun, 16 May 2021 23:42:56 +0000 (16:42 -0700)] 
fix docstring typo in bdb.py (GH-22323) (#26179)

(cherry picked from commit be54fb5ae73db507a0cdb1884d553aca5966f0e6)

Co-authored-by: flizzywine <1041958497@qq.com>
4 years agoFix a typo/error in a news entry (bidst_wheel -> bdist_wheel) (GH-24284) (#26181)
Miss Islington (bot) [Sun, 16 May 2021 23:41:05 +0000 (16:41 -0700)] 
Fix a typo/error in a news entry (bidst_wheel -> bdist_wheel) (GH-24284) (#26181)

Automerge-Triggered-By: GH:iritkatriel
(cherry picked from commit 56df20d7014bfe2df9cd46dece93271b516c50f6)

Co-authored-by: Zackery Spytz <zspytz@gmail.com>
4 years agobpo-39950: Fix deprecation warning in test for `pathlib.Path.link_to()` (GH-26155...
Miss Islington (bot) [Sun, 16 May 2021 22:35:44 +0000 (15:35 -0700)] 
bpo-39950: Fix deprecation warning in test for `pathlib.Path.link_to()` (GH-26155) (GH-26178)

(cherry picked from commit 1a08c5ac49b748d5e4e4b508d22d3804e3cd4dcc)

Co-authored-by: Barney Gale <barney.gale@gmail.com>
4 years ago[3.10] Fix typo in comment (GH-26162) (GH-26164)
Miss Islington (bot) [Sun, 16 May 2021 18:08:57 +0000 (11:08 -0700)] 
[3.10] Fix typo in comment (GH-26162) (GH-26164)

(cherry picked from commit de367378f67d7e90e4015100b19277685a3c9bb3)

Co-authored-by: Ashwin Ramaswami <aramaswamis@gmail.com>
Automerge-Triggered-By: GH:iritkatriel
4 years ago[3.10] Remove a redundant assignment in Tools/unittestgui/unittestgui.py (GH-21438...
Irit Katriel [Sun, 16 May 2021 16:56:15 +0000 (17:56 +0100)] 
[3.10] Remove a redundant assignment in Tools/unittestgui/unittestgui.py (GH-21438) (GH-26171)

(cherry picked from commit a42d98ed91cd1f08b2e9734ca6ca136dd10dff5d)

Co-authored-by: Serhii Hidenko <shidenko97@gmail.com>
4 years agobpo-44143: Fix crash in the parser when raising tokenizer errors with an exception...
Miss Islington (bot) [Sat, 15 May 2021 17:39:18 +0000 (10:39 -0700)] 
bpo-44143: Fix crash in the parser when raising tokenizer errors with an exception set (GH-26144) (GH-26148)

(cherry picked from commit 80b089179fa798c8ceaab2ff699c82499b2fcacd)

Co-authored-by: Pablo Galindo <Pablogsal@gmail.com>
4 years agobpo-32133: Improve numbers docs (GH-26124) (GH-26149)
Miss Islington (bot) [Sat, 15 May 2021 17:28:55 +0000 (10:28 -0700)] 
bpo-32133: Improve numbers docs (GH-26124) (GH-26149)

4 years agobpo-44139: Use a more descriptive syntax error comprehension case in the What's New...
Miss Islington (bot) [Sat, 15 May 2021 16:56:28 +0000 (09:56 -0700)] 
bpo-44139: Use a more descriptive syntax error comprehension case in the What's New for 3.10 (GH-26145) (GH-26146)

(cherry picked from commit c5b833046d9dbb2063f776703fc513b71664b859)

Co-authored-by: Pablo Galindo <Pablogsal@gmail.com>
4 years ago[3.10] bpo-37788: Fix reference leak when Thread is never joined (GH-26103) (GH-26138)
Miss Islington (bot) [Sat, 15 May 2021 09:24:44 +0000 (02:24 -0700)] 
[3.10] bpo-37788: Fix reference leak when Thread is never joined (GH-26103) (GH-26138)

When a Thread is not joined after it has stopped, its lock may remain in the _shutdown_locks set until interpreter shutdown.  If many threads are created this way, the _shutdown_locks set could therefore grow endlessly.  To avoid such a situation, purge expired locks each time a new one is added or removed.
(cherry picked from commit c10c2ec7a0e06975e8010c56c9c3270f8ea322ec)

Co-authored-by: Antoine Pitrou <antoine@python.org>
4 years agobpo-44072: fix Complex, Integral docs for `**` (GH-25986)
Miss Islington (bot) [Fri, 14 May 2021 22:22:45 +0000 (15:22 -0700)] 
bpo-44072: fix Complex, Integral docs for `**` (GH-25986)

In numbers module docstrings and docs.
(cherry picked from commit 4aa63d65a9971d14f1a2131b989dca0dab514a9d)

Co-authored-by: Rory Yorke <rory.yorke@gmail.com>
4 years agobpo-43729: Clarify comment in tutorial example (GH-25191) (#26136)
Miss Islington (bot) [Fri, 14 May 2021 20:06:09 +0000 (13:06 -0700)] 
bpo-43729: Clarify comment in tutorial example (GH-25191) (#26136)

(cherry picked from commit 07797121cc290ede0b3d3cf02068f3d993cddd15)

Co-authored-by: Erlend Egeberg Aasland <erlend.aasland@innova.no>
Co-authored-by: Erlend Egeberg Aasland <erlend.aasland@innova.no>