]>
git.ipfire.org Git - thirdparty/Python/cpython.git/log
Hugo van Kemenade [Wed, 23 Mar 2022 20:13:08 +0000 (22:13 +0200)]
[3.9] bpo-47061: document module deprecations due to PEP 594 (GH-31984) (GH-32082)
Also removed asynchat, asyncore, and smtpd from their respective toctree entries so they are only in the superceded subtree.
(cherry picked from commit
9ac2de922a0f783bd43b8e026e4fb70fd1888572 )
Co-authored-by: Brett Cannon <brett@python.org>
Automerge-Triggered-By: GH:brettcannon
Jelle Zijlstra [Wed, 23 Mar 2022 18:19:23 +0000 (11:19 -0700)]
[3.9] bpo-46769: Improve documentation for `typing.TypeVar` (GH-31712) (GH-31941) (GH-32067)
* [3.9] [3.10] bpo-46769: Improve documentation for `typing.TypeVar` (GH-31712) (GH-31941)
* [3.10] bpo-46769: Improve documentation for `typing.TypeVar` (GH-31712)
Co-authored-by: Jelle Zijlstra <jelle.zijlstra@gmail.com>
(cherry picked from commit
81b425d4dc43b60dd11a3e9abc5c84a4b8b384db )
* Remove references to `reveal_type`, add new section on `self` types.
(cherry picked from commit
d5ed8a8258eaf7a241978b1b0aeb971108d0f7e0 )
Co-authored-by: Alex Waygood <Alex.Waygood@Gmail.com>
* remove unused susp allowlist
Co-authored-by: Alex Waygood <Alex.Waygood@Gmail.com>
Miss Islington (bot) [Wed, 23 Mar 2022 09:01:24 +0000 (02:01 -0700)]
[doc] configparser: avoid inline comments. (GH-31247)
People are testing those blocs with the default
inline_comment_prefixes of None, leading to a:
configparser.InterpolationSyntaxError: '$' must be followed by '$' or '{', found: '$ sign ($ is the only character that needs to be escaped)'
(cherry picked from commit
3ac4e783e077ffd7b51c6acc1591002974644051 )
Co-authored-by: Julien Palard <julien@palard.fr>
Miss Islington (bot) [Wed, 23 Mar 2022 03:16:18 +0000 (20:16 -0700)]
Fix typo in Path.iterdir docs (GH-31822)
(cherry picked from commit
795b365e8a6dfbeaa75780ed7807f8116f4537ca )
Co-authored-by: Matt Williams <matt@milliams.com>
Miss Islington (bot) [Tue, 22 Mar 2022 21:27:26 +0000 (14:27 -0700)]
bpo-2604: Make doctest.DocTestCase reset globs in teardown (GH-31932)
Co-authored-by: Piet Delport
Co-authored-by: Hugo Lopes Tavares
Co-authored-by: Jelle Zijlstra <jelle.zijlstra@gmail.com>
(cherry picked from commit
7ba7eae50803b11766421cb8aae1780058a57e2b )
Co-authored-by: Daniël van Noord <13665637+DanielNoord@users.noreply.github.com>
Hugo van Kemenade [Tue, 22 Mar 2022 18:12:39 +0000 (20:12 +0200)]
[3.9] bpo-47022: Document asynchat, asyncore and smtpd removals in 3.12 (GH-31891) (#31998)
Document the deprecation of asyncore, asynchat, and smtpd with a slated removal in Python 3.12 thanks to PEP 594..
(cherry picked from commit
77473846439b8a3eae66de1a1cfe931619f38513 )
Co-authored-by: Hugo van Kemenade <hugovk@users.noreply.github.com>
Jeremy Kloth [Tue, 22 Mar 2022 17:21:35 +0000 (11:21 -0600)]
bpo-44336: Prevent tests hanging on child process handles on Windows (GH-26578)
Replace the child process `typeperf.exe` with a daemon thread that reads the performance counters directly. This prevents the issues that arise from inherited handles in grandchild processes (see issue37531 for discussion).
We only use the load tracker when running tests in multiprocess mode. This prevents inadvertent interactions with tests expecting a single threaded environment. Displaying load is really only helpful for buildbots running in multiprocess mode anyway..
Co-authored-by: Jeremy Kloth <jeremy.kloth@gmail.com>
Andrew Svetlov [Tue, 22 Mar 2022 15:16:27 +0000 (17:16 +0200)]
[3.9] bpo-45997: Fix asyncio.Semaphore re-acquiring order (GH-31910) (GH-32049)
Co-authored-by: Kumar Aditya <59607654+kumaraditya303@users.noreply.github.com>.
(cherry picked from commit
32e77154ddfc514a3144d5912bffdd957246fd6c )
Co-authored-by: Andrew Svetlov <andrew.svetlov@gmail.com>
Irit Katriel [Mon, 21 Mar 2022 21:27:53 +0000 (21:27 +0000)]
bpo-12029: [doc] clarify that except does not match virtual subclasses of the specified exception type (GH-32027) (GH-32035)
(cherry picked from commit
45833b50f0ccf2abb01304c900afee05b6d01b9e )
Miss Islington (bot) [Mon, 21 Mar 2022 11:28:31 +0000 (04:28 -0700)]
bpo-23691: Protect the re.finditer() iterator from re-entering (GH-32012)
(cherry picked from commit
08eb754d840696914928355014c2d424131f8835 )
Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
Gregory P. Smith [Mon, 21 Mar 2022 06:34:45 +0000 (23:34 -0700)]
bpo-38256: Fix binascii.crc32 large input. (GH-32000) (GH-32013) (GH-32015)
Inputs >= 4GiB to `binascii.crc32(...)` when compiled to use the zlib
crc32 implementation (the norm on POSIX) no longer return the wrong
result.
(cherry picked from commit
4c989e19c84ec224655bbbde9422e16d4a838a80 )
Miss Islington (bot) [Sun, 20 Mar 2022 14:54:19 +0000 (07:54 -0700)]
bpo-42369: Fix thread safety of zipfile._SharedFile.tell (GH-26974)
The `_SharedFile` tracks its own virtual position into the file as
`self._pos` and updates it after reading or seeking. `tell()` should
return this position instead of calling into the underlying file object,
since if multiple `_SharedFile` instances are being used concurrently on
the same file, another one may have moved the real file position.
Additionally, calling into the underlying `tell` may expose thread
safety issues in the underlying file object because it was called
without taking the lock.
(cherry picked from commit
e730ae7effe4f13b24f1b5fb1fca005709c86acb )
Co-authored-by: Kevin Mehall <km@kevinmehall.net>
Miss Islington (bot) [Sun, 20 Mar 2022 12:18:02 +0000 (05:18 -0700)]
bpo-46013: Fix confusing kerning on period in docs (GH-29989) (GH-32006)
(cherry picked from commit
3af68fc77c528d4e7749046cf6e41fd79902e6e6 )
Co-authored-by: jmcb <joel.mcbride1@live.com>
Co-authored-by: jmcb <joel.mcbride1@live.com>
Miss Islington (bot) [Sun, 20 Mar 2022 07:21:34 +0000 (00:21 -0700)]
[3.10] bpo-47040: improve document of checksum functions (GH-31955) (GH-32002)
Clarifies a versionchanged note on crc32 & adler32 docs that the workaround is only needed for Python 2 and earlier.
Also cleans up an unnecessary intermediate variable in the implementation.
Authored-By: Ma Lin / animalize
Co-authored-by: Gregory P. Smith <greg@krypto.org>
(cherry picked from commit
6d290d5862375799e997f1192ef56abca4e9182e )
Co-authored-by: Ma Lin <animalize@users.noreply.github.com>
Miss Islington (bot) [Sat, 19 Mar 2022 15:12:48 +0000 (08:12 -0700)]
[3.9] bpo-40296: Fix supporting generic aliases in pydoc (GH-30253). (GH-31976) (GH-31981)
(cherry picked from commit
cd44afc573e2e2de8d7e5a9119c347373066cd10 )
(cherry picked from commit
a5b7678a67ac99edd50822827b772e7d9afc8e64 )
Miss Islington (bot) [Sat, 19 Mar 2022 14:09:59 +0000 (07:09 -0700)]
bpo-39394: Improve warning message in the re module (GH-31988)
A warning about inline flags not at the start of the regular
expression now contains the position of the flag.
(cherry picked from commit
4142961b9f5ad3bf93976a6a7162f8049e354018 )
Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
Miss Islington (bot) [Sat, 19 Mar 2022 12:54:07 +0000 (05:54 -0700)]
bpo-44544: add textwrap placeholder arg (GH-27671)
(cherry picked from commit
cb7874f49d3d55df73a3c529773af14e2e344fb7 )
Co-authored-by: andrei kulakov <andrei.avk@gmail.com>
Serhiy Storchaka [Fri, 18 Mar 2022 15:02:44 +0000 (17:02 +0200)]
[3.9] bpo-14156: Make argparse.FileType work correctly for binary file modes when argument is '-' (GH-13165) (GH-31979)
Also made modes containing 'a' or 'x' act the same as a mode containing 'w' when argument is '-'
(so 'a'/'x' return sys.stdout like 'w', and 'ab'/'xb' return sys.stdout.buffer like 'wb').
(cherry picked from commit
eafec26ae5327bb23b6dace2650b074c3327dfa0 )
Co-authored-by: MojoVampire <shadowranger+github@gmail.com>
Pablo Galindo Salgado [Fri, 18 Mar 2022 13:33:03 +0000 (13:33 +0000)]
[3.9] bpo-46968: Check for 'sys/auxv.h' in the configure script (GH-31961). (GH-31975)
(cherry picked from commit
8e3fde728f547f1d32bde8adf62b4c50bb877b9d )
Co-authored-by: Pablo Galindo Salgado <Pablogsal@gmail.com>
Miss Islington (bot) [Fri, 18 Mar 2022 03:24:59 +0000 (20:24 -0700)]
[3.9] bpo-46421: Fix unittest filename evaluation when called as a module (GH-30654) (GH-31970)
(cherry picked from commit
a0db11b10fca0fee6bb2b8d6277e266bad8c0fdb )
Co-authored-by: Bader Zaidan <bader@zaidan.pw>
Jelle Zijlstra [Fri, 18 Mar 2022 02:45:40 +0000 (19:45 -0700)]
[3.9] bpo-42782: fix broken shutil test (GH-31971)
We were using os_helper, which doesn't exist on 3.9. This wasn't
caught because the test is only run as root. I confirmed that when
run as root, the test previously failed and now passes.
Miss Islington (bot) [Thu, 17 Mar 2022 07:29:37 +0000 (00:29 -0700)]
bpo-45979: Fix Tkinter tests with old Tk (>= 8.5.12) (GH-31938)
(cherry picked from commit
dbbe4d2d0075fa0e95b069fb4780d79aae3514c7 )
Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
Miss Islington (bot) [Thu, 17 Mar 2022 01:19:18 +0000 (18:19 -0700)]
bpo-47038: Increase a test timeout for slow CI machines (GH-31951)
(cherry picked from commit
a7c54148322781cb0f332d440a3454d550ef6414 )
Co-authored-by: Andrew Svetlov <andrew.svetlov@gmail.com>
Miss Islington (bot) [Wed, 16 Mar 2022 23:44:22 +0000 (16:44 -0700)]
bpo-47038: Rewrite missed asyncio.wait_for test to use IsolatedAnsyncioTestCase (GH-31946)
(cherry picked from commit
3dd9bfac04d3dcdbfd3f8011a6c9d4b9ac8c116a )
Co-authored-by: Andrew Svetlov <andrew.svetlov@gmail.com>
Andrew Svetlov [Wed, 16 Mar 2022 20:45:39 +0000 (22:45 +0200)]
[3.9] bpo-47038: Rewrite asyncio.wait_for test to use IsolatedAsyncioTestCase (GH-31942). (GH-31944)
(cherry picked from commit
dd0082c627713634c7fd88ad33d18b5cc9f4a7b8 )
Co-authored-by: Andrew Svetlov <andrew.svetlov@gmail.com>
Łukasz Langa [Wed, 16 Mar 2022 15:05:47 +0000 (16:05 +0100)]
Post 3.9.11, take two
Łukasz Langa [Wed, 16 Mar 2022 12:12:59 +0000 (13:12 +0100)]
Python 3.9.11, take two
Miss Islington (bot) [Wed, 16 Mar 2022 10:13:55 +0000 (03:13 -0700)]
[3.10] bpo-45382: test.pythoninfo logs more Windows versions (GH-30891) (GH-30894)
Add the following info to test.pythoninfo:
* windows.ver: output of the shell "ver" command
* windows.version and windows.version_caption: output of the
"wmic os get Caption,Version /value" command.
(cherry picked from commit
b0898f4aa90d9397e23aef98a2d6b82445ee7455 )
* bpo-45382: test.pythoninfo: set wmic.exe encoding to OEM (GH-30890)
(cherry picked from commit
cef0a5458f254c2f8536b928dee25862ca90ffa6 )
(cherry picked from commit
4a57fa296b92125e41220ecd201eb2e432b79fb0 )
Co-authored-by: Victor Stinner <vstinner@python.org>
Steve Dower [Wed, 16 Mar 2022 02:11:59 +0000 (02:11 +0000)]
[3.9] bpo-47032: Ensure Windows install builds fail correctly with a non-zero exit code when part of the build fails (GH-31921) (GH-31927)
Automerge-Triggered-By: GH:zooba
Miss Islington (bot) [Wed, 16 Mar 2022 01:30:11 +0000 (18:30 -0700)]
bpo-46948: Fix launcher installer build failure due to first part of fix (GH-31920)
(cherry picked from commit
708812085355c92f32e547d1f1d1f29aefbbc27e )
Co-authored-by: Steve Dower <steve.dower@python.org>
Łukasz Langa [Tue, 15 Mar 2022 22:43:30 +0000 (23:43 +0100)]
Post 3.9.11
Łukasz Langa [Tue, 15 Mar 2022 20:47:24 +0000 (21:47 +0100)]
Python 3.9.11
Christian Heimes [Tue, 15 Mar 2022 20:34:49 +0000 (22:34 +0200)]
[3.9] bpo-47024: Update OpenSSL to 1.1.1n (GH-31895) (#31917)
Co-authored-by: Zachary Ware <zachary.ware@gmail.com>.
Co-authored-by: Christian Heimes <christian@python.org>.
Co-authored-by: Christian Heimes <christian@python.org>
Miss Islington (bot) [Tue, 15 Mar 2022 15:50:01 +0000 (08:50 -0700)]
bpo-20392: Fix inconsistency with uppercase file extensions in mimetypes.guess_type (GH-30229)
(cherry picked from commit
5dd7ec52b83e7f239774cf7478106fcc7b0a36f3 )
Co-authored-by: Kumar Aditya <59607654+kumaraditya303@users.noreply.github.com>
Miss Islington (bot) [Tue, 15 Mar 2022 15:23:47 +0000 (08:23 -0700)]
bpo-43253: Don't call shutdown() for invalid socket handles (GH-31892)
(cherry picked from commit
70155412f1543f100d4aa309b8691cbcabd3e0e1 )
Co-authored-by: Maximilian Hils <git@maximilianhils.com>
Miss Islington (bot) [Tue, 15 Mar 2022 08:56:13 +0000 (01:56 -0700)]
But Add missing newline to NEWS entry (GH-31893)
(cherry picked from commit
16995ed0f2b697ca1ff966741288e787e1701ca9 )
Co-authored-by: Hugo van Kemenade <hugovk@users.noreply.github.com>
Miss Islington (bot) [Mon, 14 Mar 2022 23:55:12 +0000 (16:55 -0700)]
bpo-43721: Fix docstrings for property.getter/setter/deleter (GH-31046)
(cherry picked from commit
e3d348a5252549708fd19338b675a2c23b60d677 )
Co-authored-by: Irit Katriel <1055913+iritkatriel@users.noreply.github.com>
Miss Islington (bot) [Mon, 14 Mar 2022 21:30:15 +0000 (14:30 -0700)]
bpo-31415: importtime was made by Inada Naoki (GH-31875)
(cherry picked from commit
29624e769c5c3c1e59c6acc8b69383ead53e8a9f )
Co-authored-by: Victor Stinner <vstinner@python.org>
Ned Deily [Mon, 14 Mar 2022 21:10:20 +0000 (17:10 -0400)]
Revert "bpo-46986: Upgrade bundled setuptools to 60.9.3 (GH-31820)" (GH-31881)
This reverts commit
bda64b3c0c4e45de4c82ba1b8722f56db5ac88ba
as it breaks test_bdb and test_distutils with installed Pythons.
Miss Islington (bot) [Mon, 14 Mar 2022 20:52:07 +0000 (13:52 -0700)]
[3.9] bpo-30677: [doc] mention that os.mkdir() can raise FileNotFoundError (GH-31548) (GH-31878)
(cherry picked from commit
879fbd9472753149b627f32add3ddca90ac47ab7 )
Co-authored-by: slateny <46876382+slateny@users.noreply.github.com>
Automerge-Triggered-By: GH:iritkatriel
Illia Volochii [Mon, 14 Mar 2022 13:15:49 +0000 (15:15 +0200)]
[3.9] bpo-43215: Document Happy Eyeballs args of asyncio.open_connection (GH-24525) (GH-31868)
Co-authored-by: Andrew Svetlov <andrew.svetlov@gmail.com>.
(cherry picked from commit
3543ddb4c4ebc26fb2d6c67a97e66f5267876f72 )
Co-authored-by: Illia Volochii <illia.volochii@gmail.com>
Jason R. Coombs [Sun, 13 Mar 2022 21:30:07 +0000 (17:30 -0400)]
[3.9] bpo-47004: Sync with importlib_metadata 4.11.3. (GH-31854). (GH-31859)
(cherry picked from commit
b1e286860742e7ba6fadc75e3ddb6c2899a56919 )
Co-authored-by: Jason R. Coombs <jaraco@jaraco.com>
Ned Deily [Sun, 13 Mar 2022 20:02:10 +0000 (16:02 -0400)]
bpo-46986: Upgrade bundled setuptools to 60.9.3 (GH-31820) (GH-31855)
(cherry picked from commit
c99ac3c364ee21be72263791b71ee8b55f64de08 )
Co-authored-by: Pradyun Gedam <pgedam@bloomberg.net>
Miss Islington (bot) [Sun, 13 Mar 2022 18:55:32 +0000 (11:55 -0700)]
[3.9] bpo-46985: Upgrade bundled pip to 22.0.4 (GH-31819) (GH-31850)
(cherry picked from commit
d87f1b787ed38dfd307d82452f2efe9dc5b93942 )
Co-authored-by: Pradyun Gedam <pgedam@bloomberg.net>
Automerge-Triggered-By: GH:ned-deily
Charlie Zhao [Sat, 12 Mar 2022 01:14:23 +0000 (09:14 +0800)]
[3.9] bpo-46677: Add examples of inheritance and attributes to `TypedDict` docs. (GH-31349) (GH-31808)
* bpo-46677: Add examples of inheritance and attributes to `TypedDict` docs (GH-31349)
Co-authored-by: Jelle Zijlstra <jelle.zijlstra@gmail.com>
(cherry picked from commit
8a207e0321db75f3342692905e342f1d5e1add54 )
Jelle Zijlstra [Sat, 12 Mar 2022 01:10:39 +0000 (17:10 -0800)]
[3.9] sqlite3: normalise pre-acronym determiners (GH-31772) (GH-31807)
For consistency, replace "a SQL" with "an SQL"..
(cherry picked from commit
2d5835a019a46573d5b1b614c8ef88d6b564d8d4 )
Co-authored-by: Erlend Egeberg Aasland <erlend.aasland@innova.no>
Victor Stinner [Fri, 11 Mar 2022 23:37:16 +0000 (00:37 +0100)]
bpo-46968: Fix faulthandler for Sapphire Rapids Xeon (GH-31789) (GH-31831)
In Linux kernel 5.14 one can dynamically request size of altstacksize
based on hardware capabilities with getauxval(AT_MINSIGSTKSZ).
This changes allows for Python extension's request to Linux kernel
to use AMX_TILE instruction set on Sapphire Rapids Xeon processor
to succeed, unblocking use of the ISA in frameworks.
Introduced HAVE_LINUX_AUXVEC_H in configure.ac and pyconfig.h.in
Used cpython_autoconf:269 docker container to generate configure.
(cherry picked from commit
3b128c054885fe881c3b57a5978de3ea89c81a9c )
Co-authored-by: Oleksandr Pavlyk <oleksandr.pavlyk@intel.com>
Miss Islington (bot) [Fri, 11 Mar 2022 19:28:19 +0000 (11:28 -0800)]
bpo-31327: Update time documentation to reflect possible errors (GH-31460)
As per the comments, this mirrors the [datetime documentation](https://docs.python.org/3/library/datetime.htmlGH-datetime.datetime.fromtimestamp).
```
>>> import time
>>> time.localtime(
999999999999999999999 )
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
OverflowError: timestamp out of range for platform time_t
>>> time.localtime(-3600)
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
OSError: [Errno 22] Invalid argument
```
(cherry picked from commit
c83fc9c02c9846ec3a2d0123999c98e02f00b3f5 )
Co-authored-by: slateny <46876382+slateny@users.noreply.github.com>
Jelle Zijlstra [Thu, 10 Mar 2022 21:18:27 +0000 (13:18 -0800)]
[3.9] bpo-46198: rename duplicate tests and remove unused code (GH-30297) (GH-31797)
(cherry picked from commit
6c83c8e6b56b57a8a794e7b6c07837be4ce3bb97 )
Co-authored-by: Nikita Sobolev <mail@sobolevn.me>
Jelle Zijlstra [Wed, 9 Mar 2022 18:19:53 +0000 (10:19 -0800)]
[3.9] Docstring: replace pysqlite with sqlite3 (GH-31758) (GH-31778)
Replace two instances of "pysqlite" with "sqlite3" in sqlite3
docstrings. Also reword "is a no-op" to "does nothing" for clarity..
(cherry picked from commit
b33a1ae703338e09dc0af5fbfd8ffa01d3ff75da )
Co-authored-by: Erlend Egeberg Aasland <erlend.aasland@innova.no>
Irit Katriel [Tue, 8 Mar 2022 23:00:45 +0000 (23:00 +0000)]
bpo-24959: fix unittest.assertRaises bug where traceback entries are dropped from chained exceptions (GH-23688) (GH-31776)
(cherry picked from commit
88b7d86a73da9388aa65c96401c2984c8c16f8db )
Miss Islington (bot) [Tue, 8 Mar 2022 21:32:46 +0000 (13:32 -0800)]
bpo-46955: Expose asyncio.base_events.Server as asyncio.Server (GH-31760)
This change aligns the documentation at https://docs.python.org/3/library/asyncio-eventloop.htmlGH-asyncio.Server
with the actual implementation
Co-authored-by: Andrew Svetlov <andrew.svetlov@gmail.com>
(cherry picked from commit
da80d6b2f3beff519cb1457d5e055168c89f7224 )
Co-authored-by: Stefan Zabka <zabkaste@informatik.hu-berlin.de>
Miss Islington (bot) [Tue, 8 Mar 2022 16:08:24 +0000 (08:08 -0800)]
Removed confusing reference to sys (GH-31638)
(cherry picked from commit
28f84c72b6cee145f9c00e9b999656e9a2517e49 )
Co-authored-by: David Gilbertson <gilbertson.david@gmail.com>
Erlend Egeberg Aasland [Tue, 8 Mar 2022 15:31:06 +0000 (16:31 +0100)]
[3.9] bpo-46878: Purge 'non-standard' from sqlite3 docstrings (GH-31612) (GH-31754)
(cherry picked from commit
4d95fa1ac5d31ff450fb2f31b55ce1eb99d6efcb )
Miss Islington (bot) [Tue, 8 Mar 2022 10:04:54 +0000 (02:04 -0800)]
bpo-44439: _ZipWriteFile.write() handle buffer protocol correctly (GH-29468)
Co-authored-by: Marco Ribeiro <marcoffee@users.noreply.github.com>
(cherry picked from commit
36dd7396fcd26d8bf9919d536d05d7000becbe5b )
Co-authored-by: Ma Lin <animalize@users.noreply.github.com>
Miss Islington (bot) [Tue, 8 Mar 2022 04:40:16 +0000 (20:40 -0800)]
Removed ambiguity in __init_subclass__ docs (GH-31540)
(cherry picked from commit
ab014978aef303ac60465c9010505d798dc34df8 )
Co-authored-by: David Gilbertson <gilbertson.david@gmail.com>
Miss Islington (bot) [Tue, 8 Mar 2022 04:35:54 +0000 (20:35 -0800)]
docs: Don't use code formatting for emphasis (GH-30519)
(cherry picked from commit
badb637c8ce91625122d5f4d71276bfe1a8ed5e9 )
Co-authored-by: William Andrea <william.j.andrea@gmail.com>
Miss Islington (bot) [Tue, 8 Mar 2022 04:29:09 +0000 (20:29 -0800)]
bpo-46494: Mention the typing_extensions pkg in typing docs (GH-31260)
(cherry picked from commit
8debeed3075bf4d7e568e65da16bec63cf276f4f )
Co-authored-by: Meer Suri <46469858+meersuri@users.noreply.github.com>
Miss Islington (bot) [Tue, 8 Mar 2022 04:15:55 +0000 (20:15 -0800)]
bpo-45680: Improve docs on subscriptions w.r.t. `GenericAlias` objects (GH-29479)
(cherry picked from commit
50731297a9b6d57eec3b3f89522785b23f7b3e71 )
Co-authored-by: Alex Waygood <Alex.Waygood@Gmail.com>
Miss Islington (bot) [Mon, 7 Mar 2022 22:18:24 +0000 (14:18 -0800)]
bpo-46932: Update bundled libexpat to 2.4.7 (GH-31736)
(cherry picked from commit
176835c3d5c70f4c1b152cc2062b549144e37094 )
Co-authored-by: Steve Dower <steve.dower@python.org>
Steve Dower [Mon, 7 Mar 2022 20:11:25 +0000 (20:11 +0000)]
bpo-44549: Update bzip2 to 1.0.8 in Windows builds to mitigate CVE-2016-3189 and CVE-2019-12900 (GH-31732)
Steve Dower [Mon, 7 Mar 2022 17:23:31 +0000 (17:23 +0000)]
bpo-46948: Fix CVE-2022-26488 by ensuring the Windows Installer correctly uses the install path during repair (GH-31728)
Miss Islington (bot) [Mon, 7 Mar 2022 11:48:53 +0000 (03:48 -0800)]
[3.9] bpo-43292: Fix file leak in `ET.iterparse()` when not exhausted (GH-31696) (GH-31720)
Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
(cherry picked from commit
496c428de3318c9c5770937491b71dc3d3f18a6a )
Co-authored-by: Jacob Walls <jacobtylerwalls@gmail.com>
Miss Islington (bot) [Sat, 5 Mar 2022 03:21:51 +0000 (19:21 -0800)]
Lib/typing.py copy edits originating from GH-31061 (GH-31684)
(cherry picked from commit
2031149b9a7dfab5f5bad63f417e19f4fc2b9661 )
Co-authored-by: Matt Bogosian <eb3f73+github+com@yaymail.com>
Miss Islington (bot) [Fri, 4 Mar 2022 18:34:14 +0000 (10:34 -0800)]
bpo-25415: Remove confusing sentence from IOBase docstrings (PR-31631)
(cherry picked from commit
cedd2473a9bebe07f3ced4f341cf58a2fef07b03 )
Co-authored-by: slateny <46876382+slateny@users.noreply.github.com>
Victor Stinner [Fri, 4 Mar 2022 00:31:54 +0000 (01:31 +0100)]
bpo-46913: Fix test_ctypes, test_hashlib, test_faulthandler on UBSan (GH-31675) (GH-31676)
* bpo-46913: Fix test_faulthandler.test_sigfpe() on UBSAN (GH-31662)
Disable undefined behavior sanitizer (UBSAN) on
faulthandler_sigfpe().
(cherry picked from commit
4173d677a1d7c72bb32d292fbff1b4cf073d615c )
* bpo-46913: Fix test_faulthandler.test_read_null() on UBSan (GH31672)
Disable undefined behavior sanitizer (UBSan) on
faulthandler._read_null().
(cherry picked from commit
65b92ccdec2ee4a99e54aaf7ae2d9bbc2ebfe549 )
* bpo-46913: test_hashlib skips _sha3 tests on UBSan (GH-31673)
If Python is built with UBSan, test_hashlib skips tests on the _sha3
extension which currently has undefined behaviors.
This change allows to run test_hashlib to check for new UBSan regression,
but the known _sha3 undefined behavior must be fixed.
(cherry picked from commit
6d0d7d2b8c1e04fd51c6cb29cc09a41b60b97b7b )
* bpo-46913: Skip test_ctypes.test_shorts() on UBSan (GH-31674)
If Python is built with UBSan, test_ctypes now skips test_shorts().
This change allows to run test_ctypes to check for new UBSan regression,
but the known test_shorts() undefined behavior must be fixed.
(cherry picked from commit
ad1b04451d3aca2c6fa6dbe2891676a4e0baac49 )
(cherry picked from commit
7b5b429adab4fe0fe81858fe3831f06adc2e2141 )
Miss Islington (bot) [Thu, 3 Mar 2022 15:16:23 +0000 (07:16 -0800)]
bpo-6634: [doc] clarify that sys.exit() does not always exit the interpreter (GH-31639) (GH-31661)
(cherry picked from commit
10117f1d8cb49ce95493555c06050faf636ccee7 )
Co-authored-by: vidhya <96202776+Vidhyavinu@users.noreply.github.com>
Co-authored-by: vidhya <96202776+Vidhyavinu@users.noreply.github.com>
Miss Islington (bot) [Thu, 3 Mar 2022 05:59:57 +0000 (21:59 -0800)]
bpo-46831: Update __build_class__ comment (GH-31522)
Co-authored-by: Jelle Zijlstra <jelle.zijlstra@gmail.com>
(cherry picked from commit
81d968b7c30d5b41f3f28b297b7ee5345d569509 )
Co-authored-by: Shantanu <12621235+hauntsaninja@users.noreply.github.com>
Miss Islington (bot) [Thu, 3 Mar 2022 01:45:36 +0000 (17:45 -0800)]
bpo-21910: Clarify docs for codecs writelines method (GH-31245)
Co-authored-by: Jelle Zijlstra <jelle.zijlstra@gmail.com>
(cherry picked from commit
a8c87a239ee1414d6dd0b062fe9ec3e5b0c50cb8 )
Co-authored-by: slateny <46876382+slateny@users.noreply.github.com>
Victor Stinner [Wed, 2 Mar 2022 17:12:26 +0000 (18:12 +0100)]
[3.10] bpo-46633: Skip tests on ASAN and/or MSAN builds (GH-31632) (GH-31634) (GH-31644)
* Refactor sanitiser skip tests into test.support (GH-30889)
* Refactor sanitizer skip tests into test.support
(cherry picked from commit
b1cb8430504931f7854eac5d32cba74770078a4e )
* Add skips to crashing tests under sanitizers instead of manually skipping them (GH-30897)
(cherry picked from commit
a27505345e34d462139f5f8b6b5e7c9a59955150 )
* bpo-46633: Skip tests on ASAN and/or MSAN builds (GH-31632)
Skip tests on ASAN and/or MSAN builds:
* multiprocessing tests
* test___all__
* test_concurrent_futures
* test_decimal
* test_peg_generator
* test_tools
(cherry picked from commit
9204bb72a2da5885facc747e63d2bd2d654606fe )
Co-authored-by: Pablo Galindo Salgado <Pablogsal@gmail.com>
(cherry picked from commit
93264452d952d9ba604bacf2947c2df5dd477931 )
Erlend Egeberg Aasland [Wed, 2 Mar 2022 04:46:16 +0000 (05:46 +0100)]
[3.9] bpo-43853: Expand test suite for SQLite UDF's (GH-27642) (GH-31030) (GH-31586)
(cherry picked from commit
3eb3b4f270757f66c7fb6dcf5afa416ee1582a4b )
Jelle Zijlstra [Wed, 2 Mar 2022 04:45:54 +0000 (20:45 -0800)]
[3.9] Minor fixes to C API docs (GH-31501) (GH-31526)
* C API docs: move PyErr_SetImportErrorSubclass docs
It was in the section about warnings, but it makes more sense to
put it with PyErr_SetImportError.
* C API docs: document closeit argument to PyRun_AnyFileExFlags
It was already documented for PyRun_SimpleFileExFlags.
* textual fixes to unicode docs
* Move paragraph about tp_dealloc into tp_dealloc section
* __aiter__ returns an async iterator, not an awaitable.
(cherry picked from commit
43cf44ddcce6b225f959ea2a53e4817244ca6054 )
Miss Islington (bot) [Fri, 25 Feb 2022 17:07:05 +0000 (09:07 -0800)]
bpo-26897: Clarify Popen stdin, stdout, stderr file object docs (GH-30231)
(cherry picked from commit
dd69f734218ac5d3a551227069ac53ee09b0cd3e )
Co-authored-by: Kumar Aditya <59607654+kumaraditya303@users.noreply.github.com>
Victor Stinner [Fri, 25 Feb 2022 15:13:34 +0000 (16:13 +0100)]
bpo-46852: Rename float.__set_format__() to float.__setformat__() (GH-31558) (GH-31581)
Rename the private undocumented float.__set_format__() method to
float.__setformat__() to fix a typo introduced in Python 3.7. The
method is only used by test_float.
The change enables again test_float tests on the float format which
were previously skipped because of the typo.
The typo was introduced in Python 3.7 by bpo-20185
in commit
b5c51d3dd95bbfde533655fb86ac0f96f771ba7b .
(cherry picked from commit
7d03c8be5af2f1559dbc35b775b3116dfd63cfb6 )
Miss Islington (bot) [Fri, 25 Feb 2022 11:56:16 +0000 (03:56 -0800)]
bpo-46756: Fix authorization check in urllib.request (GH-31353)
Fix a bug in urllib.request.HTTPPasswordMgr.find_user_password() and
urllib.request.HTTPPasswordMgrWithPriorAuth.is_authenticated() which
allowed to bypass authorization. For example, access to URI "example.org/foobar"
was allowed if the user was authorized for URI "example.org/foo".
(cherry picked from commit
e2e72567a1c94c548868f6ee5329363e6036057a )
Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
Miss Islington (bot) [Fri, 25 Feb 2022 11:34:15 +0000 (03:34 -0800)]
bpo-34429: Noted TemporaryFile behavior on non-Posix/non-Cygwin systems (GH-31547)
(cherry picked from commit
53ecf9e08d35801807daf74492c090a325f995b7 )
Co-authored-by: slateny <46876382+slateny@users.noreply.github.com>
Miss Islington (bot) [Wed, 23 Feb 2022 19:15:57 +0000 (11:15 -0800)]
bpo-40421: Fix PyFrame_GetCode() documentation (GH-31535)
Fix PyFrame_GetBack() and PyFrame_GetCode() return type in
the documentation.
(cherry picked from commit
78859e58e4e016286e648d1dc155e0f6cebfa6ff )
Co-authored-by: Victor Stinner <vstinner@python.org>
Miss Islington (bot) [Wed, 23 Feb 2022 02:50:57 +0000 (18:50 -0800)]
bpo-46794: Bump up the libexpat version into 2.4.6 (GH-31487)
(cherry picked from commit
1935e1cc284942bec8006287c939e295e1a7bf13 )
Co-authored-by: Dong-hee Na <donghee.na@python.org>
Miss Islington (bot) [Wed, 23 Feb 2022 00:08:43 +0000 (16:08 -0800)]
Inherit asyncio proactor datagram transport from asyncio.DatagramTransport (GH-31512)
(cherry picked from commit
cff4d5c5d29528299ec1ac5b3b3a6f7735577c01 )
Co-authored-by: Andrew Svetlov <andrew.svetlov@gmail.com>
Miss Islington (bot) [Tue, 22 Feb 2022 21:10:04 +0000 (13:10 -0800)]
bpo-46827: pass sock.type to getaddrinfo in sock_connect (GH-31499)
Co-authored-by: Thomas Grainger <tagrain@gmail.com>
Co-authored-by: blurb-it[bot] <43283697+blurb-it[bot]@users.noreply.github.com>
Co-authored-by: Andrew Svetlov <andrew.svetlov@gmail.com>
(cherry picked from commit
8fb94893e4a870ed3533e80c4bc2f1ebf1cfa9e7 )
Co-authored-by: Thomas Grainger <tagrain@gmail.com>
Miss Islington (bot) [Tue, 22 Feb 2022 18:43:55 +0000 (10:43 -0800)]
[3.9] bpo-20923 : [doc] Explain ConfigParser 'valid section name' and .SECTCRE (GH-31413) (GH-31507)
(cherry picked from commit
bba8008f99d615a02984422a3825082bb5621f5a )
Co-authored-by: vidhya <96202776+Vidhyavinu@users.noreply.github.com>
Automerge-Triggered-By: GH:iritkatriel
Miss Islington (bot) [Tue, 22 Feb 2022 18:03:30 +0000 (10:03 -0800)]
bpo-36557: Updated wording for using/windows (GH-31457)
(cherry picked from commit
9a0d941df4c3e1efb8b3017cd2c2de17e582fd5c )
Co-authored-by: slateny <46876382+slateny@users.noreply.github.com>
Miss Islington (bot) [Mon, 21 Feb 2022 17:18:55 +0000 (09:18 -0800)]
[3.9] bpo-46732: fix __bool__ docstring (GH-31301) (GH-31474)
(cherry picked from commit
0a222db2bca63070f429c0e613707da1bdfaf0e0 )
Co-authored-by: Jelle Zijlstra <jelle.zijlstra@gmail.com>
Miss Islington (bot) [Mon, 21 Feb 2022 16:16:23 +0000 (08:16 -0800)]
bpo-46811: Make test suite support Expat >=2.4.5 (GH-31453) (GH-31469)
Curly brackets were never allowed in namespace URIs
according to RFC 3986, and so-called namespace-validating
XML parsers have the right to reject them a invalid URIs.
libexpat >=2.4.5 has become strcter in that regard due to
related security issues; with ET.XML instantiating a
namespace-aware parser under the hood, this test has no
future in CPython.
References:
- https://datatracker.ietf.org/doc/html/rfc3968
- https://www.w3.org/TR/xml-names/
Also, test_minidom.py: Support Expat >=2.4.5
(cherry picked from commit
2cae93832f46b245847bdc252456ddf7742ef45e )
Co-authored-by: Sebastian Pipping <sebastian@pipping.org>
Co-authored-by: Sebastian Pipping <sebastian@pipping.org>
Miss Islington (bot) [Mon, 21 Feb 2022 08:07:54 +0000 (00:07 -0800)]
bpo-39327: Close file descriptors as soon as possible in shutil.rmtree (GH-31384)
It fixes the "Text File Busy" OSError when using 'rmtree' on a
windows-managed filesystem in via the VirtualBox shared folder
(and possible other scenarios like a windows-managed network file
system).
(cherry picked from commit
b77158b4da449ec5b8f682816a79d004fd65ed07 )
Co-authored-by: Lital Natan <litaln@gmail.com>
Miss Islington (bot) [Mon, 21 Feb 2022 00:10:35 +0000 (16:10 -0800)]
replace `self` param with more appropriate `cls` in classmethods (GH-31402) (#31445)
(cherry picked from commit
a3fcca4af1cb418dc802feb75100ecc1a286afaa )
Co-authored-by: Josh Smith <cmyuiosu@gmail.com>
Co-authored-by: Josh Smith <cmyuiosu@gmail.com>
Miss Islington (bot) [Sun, 20 Feb 2022 13:37:00 +0000 (05:37 -0800)]
Improve discussion about how __getattr__ is invoked. (GH-31435) (GH-31438)
Andrew Svetlov [Sun, 20 Feb 2022 12:49:27 +0000 (14:49 +0200)]
[3.9] Raise TypeError if SSLSocket is passed to asyncio transport-based methods (GH-31442) (GH-31444)
(cherry picked from commit
1f9d4c93af380d00bf2e24bc5f5ce662d41504aa )
Co-authored-by: Andrew Svetlov <andrew.svetlov@gmail.com>
Andrew Svetlov [Sun, 20 Feb 2022 12:39:21 +0000 (14:39 +0200)]
[3.9] bpo-46672: fix `NameError` in `asyncio.gather` if type check fails (GH-31187) (GH-31441)
Co-authored-by: Nikita Sobolev <mail@sobolevn.me>
Miss Islington (bot) [Sat, 19 Feb 2022 02:49:48 +0000 (18:49 -0800)]
Counter doc mentions three methods, but lists four (GH-30706)
Was probably caused by the addition of the `total()` method
(cherry picked from commit
99331fcf175b03b6b82451ac9aa953b476ab48e0 )
Co-authored-by: Charles Brunet <charles.brunet@optelgroup.com>
Miss Islington (bot) [Sat, 19 Feb 2022 02:13:33 +0000 (18:13 -0800)]
[docs] Correct typos in SSLContext.sni_callback (GH-30623)
Co-authored-by: Jörn Heissler <nosuchaddress@joern-heissler.de>
(cherry picked from commit
f80a97b492f41afd3c42bb2bd6da7b2828dca215 )
Co-authored-by: Jörn Heissler <joernheissler@users.noreply.github.com>
Miss Islington (bot) [Fri, 18 Feb 2022 23:13:16 +0000 (15:13 -0800)]
bpo-46784: Add newly exported expat symbols to the namespace. (GH-31397)
The libexpat 2.4.1 upgrade from introduced the following new exported symbols:
* `testingAccountingGetCountBytesDirect`
* `testingAccountingGetCountBytesIndirect`
* `unsignedCharToPrintable`
* `XML_SetBillionLaughsAttackProtectionActivationThreshold`
* `XML_SetBillionLaughsAttackProtectionMaximumAmplification`
We need to adjust [Modules/expat/pyexpatns.h](https://github.com/python/cpython/blob/master/Modules/expat/pyexpatns.h)
(The newer libexpat upgrade has no new symbols).
Automerge-Triggered-By: GH:gpshead
(cherry picked from commit
6312c1052c0186b4596fc45c42fd3ade9f8f5911 )
Co-authored-by: Yilei "Dolee" Yang <yileiyang@google.com>
Miss Islington (bot) [Fri, 18 Feb 2022 02:08:28 +0000 (18:08 -0800)]
Fix mistake in barry_as_FLUFL test (GH-31392)
Use assertEqual(), not assertTrue(lineno, 2)
(cherry picked from commit
5f1c205dcec0adf68b76ba78247a0ec1fa9a7b66 )
Co-authored-by: Patrick Reader <_@pxeger.com>
Miss Islington (bot) [Thu, 17 Feb 2022 21:58:26 +0000 (13:58 -0800)]
bpo-46400: Update libexpat from 2.4.1 to 2.4.4 (GH-31022) (GH-31295)
Miss Islington (bot) [Thu, 17 Feb 2022 12:46:25 +0000 (04:46 -0800)]
Update html.parser.rst (GH-30678)
This PR for the documentation of the [html.parser](https://docs.python.org/3/library/html.parser.html) module will
- fix a terminology mistake (‘start of a tag’ -> ‘start tag of an element’);
- mention the parameter names of the `HTMLParser.handle_*` methods where missing.
(cherry picked from commit
2945f5a7c51200bfc5c493ccb626fc414e1385b1 )
Co-authored-by: Géry Ogam <gery.ogam@gmail.com>
Miss Islington (bot) [Thu, 17 Feb 2022 04:06:25 +0000 (20:06 -0800)]
[3.9] Become a CODEOWNER for typing (GH-31374) (GH-31381)
(cherry picked from commit
6f1efd19a70839d480e4b1fcd9fecd3a8725824b )
Co-authored-by: Jelle Zijlstra <jelle.zijlstra@gmail.com>
Automerge-Triggered-By: GH:JelleZijlstra
Miss Islington (bot) [Thu, 17 Feb 2022 03:53:31 +0000 (19:53 -0800)]
bpo-46333: Honor `module` parameter in ForwardRef (GH-30536)
The `module` parameter carries semantic information about the forward ref.
Forward refs are different if they refer to different module even if they
have the same name. This affects the `__eq__`, `__repr__` and `__hash__` methods.
Co-authored-by: Andreas Hangauer <andreas.hangauer@siemens.com>
Co-authored-by: Alex Waygood <Alex.Waygood@Gmail.com>
Co-authored-by: Ken Jin <28750310+Fidget-Spinner@users.noreply.github.com>
(cherry picked from commit
6e7b813195f9bd6a2a15c1f00ef2c0180f6c751a )
Co-authored-by: aha79 <34090357+aha79@users.noreply.github.com>
Miss Islington (bot) [Wed, 16 Feb 2022 11:18:16 +0000 (03:18 -0800)]
bpo-46762: Fix an assert failure in f-strings where > or < is the last character if the f-string is missing a trailing right brace. (GH-31365)
(cherry picked from commit
ffd9f8ff84ed53c956b16d027f7d2926ea631051 )
Co-authored-by: Eric V. Smith <ericvsmith@users.noreply.github.com>
Miss Islington (bot) [Tue, 15 Feb 2022 17:08:24 +0000 (09:08 -0800)]
bpo-46741: Update `asyncio.protocols.BufferedProtocol` docstring (31327)
The docstring for `BufferedProtocol` states that the class is still an "experimental API", but it has been considered stable since 3.8.
(cherry picked from commit
1d81fdc4c004511c25f74db0e04ddbbb8a04ce6d )
Co-authored-by: Alex Waygood <Alex.Waygood@Gmail.com>
DongGeon Lee [Tue, 15 Feb 2022 12:22:01 +0000 (21:22 +0900)]
[3.9] bpo-46728: fix docstring of combinations_with_replacement for consistency (GH-31293). (GH-31356)