]> git.ipfire.org Git - thirdparty/Python/cpython.git/log
thirdparty/Python/cpython.git
4 years agobpo-45234: Fix FileNotFound exception raised instead of IsADirectoryError in shutil...
Miss Islington (bot) [Tue, 21 Sep 2021 22:21:10 +0000 (15:21 -0700)] 
bpo-45234: Fix FileNotFound exception raised instead of IsADirectoryError in shutil.copyfile() (GH-28421) (GH-28507)

This was a regression from fixing BPO-43219.
(cherry picked from commit b7eac52b466f697d3e89f47508e0df0196a98970)

Co-authored-by: andrei kulakov <andrei.avk@gmail.com>
4 years agobpo-45216: Remove extraneous method docs from `difflib` (GH-28445) (GH-28506)
Miss Islington (bot) [Tue, 21 Sep 2021 21:57:49 +0000 (14:57 -0700)] 
bpo-45216: Remove extraneous method docs from `difflib` (GH-28445) (GH-28506)

(cherry picked from commit 06e1773c8d8fe375423bb7fcf5922b49bc737b75)

Co-authored-by: Nikita Sobolev <mail@sobolevn.me>
4 years agobpo-45209: fix `UserWarning: resource_tracker` in test_multiprocessing (GH-28377...
Miss Islington (bot) [Tue, 21 Sep 2021 18:37:04 +0000 (11:37 -0700)] 
bpo-45209: fix `UserWarning: resource_tracker` in test_multiprocessing (GH-28377) (GH-28500)

(cherry picked from commit f604cf1c377a7648e0686044e6e49900bfc9feef)

Co-authored-by: Nikita Sobolev <mail@sobolevn.me>
4 years agobpo-45246: Document that sorted() only uses "<" comparisons (GH-28494)
Miss Islington (bot) [Tue, 21 Sep 2021 17:53:26 +0000 (10:53 -0700)] 
bpo-45246: Document that sorted() only uses "<" comparisons (GH-28494)

(cherry picked from commit 9a0dcc5b2e04d9c51350107734f12a1cbc0284a7)

Co-authored-by: Raymond Hettinger <rhettinger@users.noreply.github.com>
4 years ago[3.9] bpo-45021: Fix a hang in forked children (GH-28007) (GH-28481)
Miss Islington (bot) [Mon, 20 Sep 2021 18:54:24 +0000 (11:54 -0700)] 
[3.9] bpo-45021: Fix a hang in forked children (GH-28007) (GH-28481)

_global_shutdown_lock should be reinitialized in forked children
(cherry picked from commit 0bfa1106acfcddc03590e1f5d6789dbad3affe70)

Co-authored-by: nullptr <3621629+0x0L@users.noreply.github.com>
Automerge-Triggered-By: GH:gpshead
4 years agobpo-45229: Make pickle tests discoverable (GH-28467) (GH-28479)
Miss Islington (bot) [Mon, 20 Sep 2021 16:19:49 +0000 (09:19 -0700)] 
bpo-45229: Make pickle tests discoverable (GH-28467) (GH-28479)

(cherry picked from commit e6ba992288fdbe71aa808cfb6955f6f99da7e349)

Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
4 years agobpo-40413: test_embed tests calling Py_RunMain() multiple times (GH-28466) (GH-28471)
Miss Islington (bot) [Mon, 20 Sep 2021 15:51:32 +0000 (08:51 -0700)] 
bpo-40413: test_embed tests calling Py_RunMain() multiple times (GH-28466) (GH-28471)

Calling Py_InitializeFromConfig()+Py_RunMain() multiple times must
not crash.

Cleanup also test_get_argc_argv().
(cherry picked from commit 5e2c32e08ed77081cabd9d51f0589f81c1572732)

Co-authored-by: Victor Stinner <vstinner@python.org>
4 years agobpo-45055: Add retry when downloading externals on Windows (GH-28399)
Miss Islington (bot) [Mon, 20 Sep 2021 14:59:15 +0000 (07:59 -0700)] 
bpo-45055: Add retry when downloading externals on Windows (GH-28399)

Co-authored-by: Łukasz Langa <lukasz@langa.pl>
(cherry picked from commit ef9e22b253253615098d22cb49141a2a1024ee3c)

Co-authored-by: Steve Dower <steve.dower@python.org>
4 years ago[3.9] bpo-45229: Remove test_main in many tests (GH-28405) (GH-28456)
Serhiy Storchaka [Mon, 20 Sep 2021 06:34:52 +0000 (09:34 +0300)] 
[3.9] bpo-45229: Remove test_main in many tests (GH-28405) (GH-28456)

Instead of explicitly enumerate test classes for run_unittest()
use the unittest ability to discover tests. This also makes these
tests discoverable and runnable with unittest.

load_tests() can be used for dynamic generating tests and adding
doctests. setUpModule(), tearDownModule() and addModuleCleanup()
can be used for running code before and after all module tests..
(cherry picked from commit 40348acc180580371d25f75f46b27048e35f2435)

4 years agobpo-30637: Improve the docs of ast.parse regarding differences with compile() (GH...
Miss Islington (bot) [Sun, 19 Sep 2021 23:13:56 +0000 (16:13 -0700)] 
bpo-30637: Improve the docs of ast.parse regarding differences with compile() (GH-28459)

(cherry picked from commit e6d05a4092b4176a30d1d1596585df13c2ab676d)

Co-authored-by: Pablo Galindo Salgado <Pablogsal@gmail.com>
4 years agobpo-36674: Honour the skipping decorators in TestCase.debug() (GH-28446)
Miss Islington (bot) [Sat, 18 Sep 2021 13:22:40 +0000 (06:22 -0700)] 
bpo-36674: Honour the skipping decorators in TestCase.debug() (GH-28446)

unittest.TestCase.debug() raises now a SkipTest if the class or
the test method are decorated with the skipping decorator.

Previously it only raised a SkipTest if the test method was decorated
with other decorator in addition to the skipping decorator, or
if SkipTest was explicitly raised in the test or setup methods.
(cherry picked from commit dea59cf88adf5d20812edda330e085a4695baba4)

Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
4 years agobpo-45235: Fix argparse overrides namespace with subparser defaults (GH-28420) (GH...
Miss Islington (bot) [Sat, 18 Sep 2021 06:47:41 +0000 (23:47 -0700)] 
bpo-45235: Fix argparse overrides namespace with subparser defaults (GH-28420) (GH-28443)

4 years ago[3.9] Fix minor typo in Doc/c-api/type.rst (GH-28432) (GH-28441)
Miss Islington (bot) [Sat, 18 Sep 2021 02:12:25 +0000 (19:12 -0700)] 
[3.9] Fix minor typo in Doc/c-api/type.rst (GH-28432) (GH-28441)

retreived-> retrieved
(cherry picked from commit af08f1ba40505bf1380c08b57ba4e0b8969a8358)

Co-authored-by: Konstantin Popov <konst.hardy@gmail.com>
Automerge-Triggered-By: GH:Fidget-Spinner
4 years ago[doc] Clarify exception in `multiprocessing.cpu_count` (GH-23660) (GH-28434)
Miss Islington (bot) [Fri, 17 Sep 2021 23:23:38 +0000 (16:23 -0700)] 
[doc] Clarify exception in `multiprocessing.cpu_count` (GH-23660) (GH-28434)

Previous wording didn't explain the slightly unintuitive behavior.

Co-authored-by: kj <28750310+Fidget-Spinner@users.noreply.github.com>
(cherry picked from commit 24dbe30f8df80740704db3743d071b3218d1276e)

Co-authored-by: Emmanuel Arias <eamanu@yaerobi.com>
4 years agobpo-42038: fix description of returned list of lines (GH-27529) (GH-28429)
Miss Islington (bot) [Fri, 17 Sep 2021 22:56:26 +0000 (15:56 -0700)] 
bpo-42038: fix description of returned list of lines (GH-27529) (GH-28429)

Co-authored-by: andrei kulakov <andrei.avk@gmail.com>
4 years agoFix missing space with help for `-m compileall -o` (GH-27591) (GH-28431)
Miss Islington (bot) [Fri, 17 Sep 2021 22:55:37 +0000 (15:55 -0700)] 
Fix missing space with help for `-m compileall -o` (GH-27591) (GH-28431)

(cherry picked from commit 74cc2453ae690be940cddfae8caf8216d8628c4a)

Co-authored-by: Daniel Hahler <git@thequod.de>
4 years ago[doc] Add a missing apostrophe in a code example in venv.rst (GH-28391) (GH-28426)
Miss Islington (bot) [Fri, 17 Sep 2021 22:18:19 +0000 (15:18 -0700)] 
[doc] Add a missing apostrophe in a code example in venv.rst (GH-28391) (GH-28426)

(cherry picked from commit d22a700091af35ce52db0b1fbb02115bb6efbb1f)

Co-authored-by: Arkaprabha Chakraborty <chakrabortyarkaprabha998@gmail.com>
4 years agobpo-45187: Fix dangling threads in test_socket.CreateServerFunctionalTest (GH-28422...
Miss Islington (bot) [Fri, 17 Sep 2021 19:40:33 +0000 (12:40 -0700)] 
bpo-45187: Fix dangling threads in test_socket.CreateServerFunctionalTest (GH-28422) (GH-28424)

(cherry picked from commit 51ebb7f4f5e9bdcf8279a1d91be9569706f6bead)

Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
4 years ago[3.9] bpo-45187: Collect test_socket tests using unittest (GH-28317) (GH-28413)
Łukasz Langa [Fri, 17 Sep 2021 11:48:54 +0000 (13:48 +0200)] 
[3.9] bpo-45187: Collect test_socket tests using unittest (GH-28317) (GH-28413)

Previously, test classes ISOTPTest, J1939Test, BasicUDPLITETest and
UDPLITETimeoutTest were not included in the list of tests and
were not run by regrtest..
(cherry picked from commit 0361335b80b435ca3694981b41f8269e390eb892)

Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
4 years agobpo-45217: adds note that `allow_no_value` in `configparser` is optional (GH-28396...
Miss Islington (bot) [Fri, 17 Sep 2021 11:41:25 +0000 (04:41 -0700)] 
bpo-45217: adds note that `allow_no_value` in `configparser` is optional (GH-28396) (GH-28416)

Co-authored-by: Łukasz Langa <lukasz@langa.pl>
(cherry picked from commit cb07838ab756564988b1ffd23871f1222a832446)

Co-authored-by: Nikita Sobolev <mail@sobolevn.me>
4 years ago[3.9] docs: correct references to __isub__ etc (GH-28297). (GH-28415)
Serhiy Storchaka [Fri, 17 Sep 2021 11:14:27 +0000 (14:14 +0300)] 
[3.9] docs: correct references to __isub__ etc (GH-28297). (GH-28415)

(cherry picked from commit 800bd01b6d365156403c3dde61765dc5fdbf64be)

Co-authored-by: David Hewitt <1939362+davidhewitt@users.noreply.github.com>
4 years ago[3.9] bpo-45212: Fix dangling threads in skipped tests in test_socket (GH-28361)...
Serhiy Storchaka [Fri, 17 Sep 2021 10:11:50 +0000 (13:11 +0300)] 
[3.9] bpo-45212: Fix dangling threads in skipped tests in test_socket (GH-28361) (GH-28408)

tearDown() is not called if setUp() raises an exception
(including SkipTest). addCleanup() should be used for guaranteed
execution of the cleanup code.
(cherry picked from commit 7dacb70485a0910eb298c24b4d051720ca56fb91)

4 years agobpo-45228: Fix stack buffer overflow in parsing J1939 address (GH-28404)
Miss Islington (bot) [Fri, 17 Sep 2021 09:10:55 +0000 (02:10 -0700)] 
bpo-45228: Fix stack buffer overflow in parsing J1939 address (GH-28404)

(cherry picked from commit 773319545ba60577bc140aa46eac83b360240b7a)

Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
4 years agobpo-45220: Avoid automatically selecting the Windows 11 SDK preview when building...
Miss Islington (bot) [Thu, 16 Sep 2021 18:54:25 +0000 (11:54 -0700)] 
bpo-45220: Avoid automatically selecting the Windows 11 SDK preview when building (GH-28393)

(cherry picked from commit f4b94b1f57827083990272b5f282aa1493ae2bf4)

Co-authored-by: Steve Dower <steve.dower@python.org>
4 years agobpo-45208: Make test_pdb.test_checkline_is_not_executable() quiet (GH-28354) (GH...
Victor Stinner [Thu, 16 Sep 2021 07:53:02 +0000 (09:53 +0200)] 
bpo-45208: Make test_pdb.test_checkline_is_not_executable() quiet (GH-28354) (GH-28381)

test_pdb.test_checkline_is_not_executable() no longer writes output
to stdout.

Remove also unused variables 'f'.

(cherry picked from commit e08e491a6ceea8ca105612df10147418c4e105b8)

4 years agobpo-45205: Make test_compileall quiet (GH-28356) (GH-28364)
Miss Islington (bot) [Wed, 15 Sep 2021 19:33:52 +0000 (12:33 -0700)] 
bpo-45205: Make test_compileall quiet (GH-28356) (GH-28364)

Make test_compileall quiet: test_year_2038_mtime_compilation() and
test_larger_than_32_bit_times() of test_compileall no longer log
"Compiling ..." messages to stdout.
(cherry picked from commit cc057ff5227b3a4ded637caa7ba51b67b06abaaa)

Co-authored-by: Victor Stinner <vstinner@python.org>
4 years agobpo-45167: Fix deepcopying of GenericAlias (GH-28324) (GH-28368)
Miss Islington (bot) [Wed, 15 Sep 2021 19:31:14 +0000 (12:31 -0700)] 
bpo-45167: Fix deepcopying of GenericAlias (GH-28324) (GH-28368)

(cherry picked from commit 5dce51a8875d9639786741e962b3cb208596b096)

Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
4 years agobpo-45207: Make test_gdb.test_pycfunction() quiet (GH-28355) (GH-28366)
Miss Islington (bot) [Wed, 15 Sep 2021 19:11:21 +0000 (12:11 -0700)] 
bpo-45207: Make test_gdb.test_pycfunction() quiet (GH-28355) (GH-28366)

test_gdb.test_pycfunction() now ignores gdb stderr, it no longer logs
messages like:

    Function "meth_varargs" not defined.
(cherry picked from commit 84a6061e29e9dc13909bdf6f541f48c2a4f1d410)

Co-authored-by: Victor Stinner <vstinner@python.org>
4 years agobpo-45089: Improve sqlite3 trace callback docs (GH-28238) (GH-28372)
Miss Islington (bot) [Wed, 15 Sep 2021 19:09:27 +0000 (12:09 -0700)] 
bpo-45089: Improve sqlite3 trace callback docs (GH-28238) (GH-28372)

- Add link to str object and sqlite3 transaction control
- Mention that exceptions are not propagated
(cherry picked from commit 51056b40e711d84692d099ac8970077b33c7fafd)

Co-authored-by: Erlend Egeberg Aasland <erlend.aasland@innova.no>
4 years agobpo-45195: Fix test_readline.test_nonascii() (GH-28329) (GH-28334)
Miss Islington (bot) [Wed, 15 Sep 2021 12:38:57 +0000 (05:38 -0700)] 
bpo-45195: Fix test_readline.test_nonascii() (GH-28329) (GH-28334)

Fix test_readline.test_nonascii(): sometimes, the newline character
is not written at the end, so don't expect it in the output.
(cherry picked from commit 797c8eb9ef511f0c25f10a453b35c4d2fe383c30)

Co-authored-by: Victor Stinner <vstinner@python.org>
4 years agobpo-45020: Don't test IDLE with frozen module. (GH-28344)
Miss Islington (bot) [Wed, 15 Sep 2021 07:34:19 +0000 (00:34 -0700)] 
bpo-45020: Don't test IDLE with frozen module. (GH-28344)

Otherwise, test would need special import.
(cherry picked from commit 369bf949ccbb689cd4638b29b4c0c12db79b927c)

Co-authored-by: Terry Jan Reedy <tjreedy@udel.edu>
4 years agobpo-45196: prevent unittest crash on address sanitizer builds (GH-28331)
Miss Islington (bot) [Tue, 14 Sep 2021 18:54:27 +0000 (11:54 -0700)] 
bpo-45196: prevent unittest crash on address sanitizer builds (GH-28331)

(cherry picked from commit b668cdfa09e9bdfcfddaadd23dbd455d5f667383)

Co-authored-by: junyixie <xiejunyi.arch@bytedance.com>
4 years agobpo-45156: Fixes inifite loop on unittest.mock.seal() (GH-28300)
Miss Islington (bot) [Tue, 14 Sep 2021 10:50:28 +0000 (03:50 -0700)] 
bpo-45156: Fixes inifite loop on unittest.mock.seal() (GH-28300)

Fixes infinite loop on unittest.mock.seal() of mocks created by
unittest.create_autospec().

Co-authored-by: Dong-hee Na <donghee.na92@gmail.com>
(cherry picked from commit 7f60c9e1c6e22cc0e846a872c318570926cd3094)

Co-authored-by: Nikita Sobolev <mail@sobolevn.me>
4 years agobpo-35474: Fix mimetypes.guess_all_extensions() potentially mutating list (GH-28286...
Miss Islington (bot) [Mon, 13 Sep 2021 17:24:08 +0000 (10:24 -0700)] 
bpo-35474: Fix mimetypes.guess_all_extensions() potentially mutating list (GH-28286) (GH-28290)

* Calling guess_all_extensions() with strict=False potentially
  mutated types_map_inv.
* Mutating the result of guess_all_extensions() mutated types_map_inv.
(cherry picked from commit 97ea18ecede8bfd33d5ab2dd0e7e2aada2051111)

Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
4 years agobpo-45182: Fix incorrect use of requires_zlib in test_bdist_rpm (GH-28305)
Miss Islington (bot) [Mon, 13 Sep 2021 17:08:35 +0000 (10:08 -0700)] 
bpo-45182: Fix incorrect use of requires_zlib in test_bdist_rpm (GH-28305)

It is a decorator factory and should be always followed by "()".
(cherry picked from commit 9260e6739865c966c3ec6c5c289e0b96f848403e)

Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
4 years ago[3.10] bpo-45126: Fix ref. leak in `sqlite3.Connection.__init__` (GH-28231). (GH...
Miss Islington (bot) [Mon, 13 Sep 2021 04:07:32 +0000 (21:07 -0700)] 
[3.10] bpo-45126: Fix ref. leak in `sqlite3.Connection.__init__` (GH-28231). (GH-28298)

(cherry picked from commit aa6dd54d43dffbdf883c083e361f6ccf8642d66e)

Co-authored-by: Erlend Egeberg Aasland <erlend.aasland@innova.no>
4 years agoIDLE: adjust Python version in doc url for 3.10+ (GH-28228) (GH-28282)
Miss Islington (bot) [Fri, 10 Sep 2021 22:22:54 +0000 (15:22 -0700)] 
IDLE: adjust Python version in doc url for 3.10+ (GH-28228) (GH-28282)

Expression 'python_version()[:3]' truncated '3.10.0' to '3.1' instead of '3.10'.

Co-authored-by: Terry Jan Reedy <tjreedy@udel.edu>
(cherry picked from commit b74c819fab86bedc9b962ea42cfb9b5893fd2dda)

Co-authored-by: giovanniwijaya <16949408+giovanniwijaya@users.noreply.github.com>
4 years agobpo-9811: [doc] strftime handling of unsupported format specifiers is platform depend...
Miss Islington (bot) [Fri, 10 Sep 2021 19:53:34 +0000 (12:53 -0700)] 
bpo-9811: [doc] strftime handling of unsupported format specifiers is platform dependent (GH-28264) (GH-28278)

(cherry picked from commit e86bcfa58080f152f242c756f625f4015671f168)

Co-authored-by: Irit Katriel <1055913+iritkatriel@users.noreply.github.com>
4 years agobpo-44219: Mention GH-28250 is a deadlock bugfix (GH-28261) (GH-28275)
Miss Islington (bot) [Fri, 10 Sep 2021 16:22:24 +0000 (09:22 -0700)] 
bpo-44219: Mention GH-28250 is a deadlock bugfix (GH-28261) (GH-28275)

(cherry picked from commit 296b7100705ef52aece3378b0ae42c33a58526e1)

Co-authored-by: Łukasz Langa <lukasz@langa.pl>
4 years ago[3.9] Fix typos in pep384_macrocheck.py (GH-28220) (GH-28273)
Miss Islington (bot) [Fri, 10 Sep 2021 15:11:46 +0000 (08:11 -0700)] 
[3.9] Fix typos in pep384_macrocheck.py (GH-28220) (GH-28273)

Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
Co-authored-by: Ken Jin <28750310+Fidget-Spinner@users.noreply.github.com>
(cherry picked from commit 4338aeeb9e07607f17bbada8ebfd97e7cc7a203c)

Co-authored-by: Ikko Ashimine <eltociear@gmail.com>
Automerge-Triggered-By: GH:Fidget-Spinner
4 years agobpo-44219: Release the GIL during isatty syscalls (GH-28250)
Miss Islington (bot) [Thu, 9 Sep 2021 13:40:42 +0000 (06:40 -0700)] 
bpo-44219: Release the GIL during isatty syscalls (GH-28250)

Release the GIL while performing isatty() system calls on arbitrary
file descriptors. In particular, this affects os.isatty(),
os.device_encoding() and io.TextIOWrapper. By extension,
io.open() in text mode is also affected.
(cherry picked from commit 06148b1870fceb1a21738761b8e1ac3bf654319b)

Co-authored-by: Vincent Michel <vxgmichel@gmail.com>
4 years ago[3.9] bpo-41082: Add note on errors that may be raised by home() and expanduser(...
andrei kulakov [Wed, 8 Sep 2021 17:24:09 +0000 (13:24 -0400)] 
[3.9] bpo-41082: Add note on errors that may be raised by home() and expanduser() (GH-28186)

Co-authored-by: Łukasz Langa <lukasz@langa.pl>
4 years ago[3.9] bpo-38820: Test with OpenSSL 3.0.0 final (GH-28205) (GH-28217)
Łukasz Langa [Wed, 8 Sep 2021 17:01:25 +0000 (19:01 +0200)] 
[3.9] bpo-38820: Test with OpenSSL 3.0.0 final (GH-28205) (GH-28217)

Signed-off-by: Christian Heimes <christian@python.org>.
(cherry picked from commit cc7c6801945c6a7373553b78bd899ce09681ec0a)

Co-authored-by: Christian Heimes <christian@python.org>
4 years ago[3.9] bpo-45097: Fix deprecation warnings in test_asyncio (GH-28236)
Serhiy Storchaka [Wed, 8 Sep 2021 15:59:40 +0000 (18:59 +0300)] 
[3.9] bpo-45097: Fix deprecation warnings in test_asyncio (GH-28236)

4 years ago[3.9] bpo-45121: Fix RecursionError when calling Protocol.__init__ from a subclass...
Ken Jin [Wed, 8 Sep 2021 15:01:51 +0000 (23:01 +0800)] 
[3.9] bpo-45121: Fix RecursionError when calling Protocol.__init__ from a subclass' __init__ (GH-28206) (GH-28233)

Co-authored-by: Yurii Karabas <1998uriyyo@gmail.com>
4 years agoRemove documentation for non-existing socket class attributes (GH-28029) (GH-28221)
Miss Islington (bot) [Tue, 7 Sep 2021 18:45:57 +0000 (11:45 -0700)] 
Remove documentation for non-existing socket class attributes (GH-28029) (GH-28221)

The functions in question are available on the module-level only.
(cherry picked from commit 34d82ce7cb82a8f5e2e83417d66d9aa319f3bb69)

Co-authored-by: Matti Picus <matti.picus@gmail.com>
4 years agobpo-24888: Clarify subprocess.check_call propagates exceptions if unable to start...
Miss Islington (bot) [Tue, 7 Sep 2021 18:43:42 +0000 (11:43 -0700)] 
bpo-24888: Clarify subprocess.check_call propagates exceptions if unable to start process (GH-28018) (GH-28223)

(cherry picked from commit 19a304ba990481f0381a5316096b6b3cf2dff381)

Co-authored-by: DonnaDia <37962843+DonnaDia@users.noreply.github.com>
4 years agoCheck that 'configure' is generated by GNU Autoconf 2.69 (GH-28156)
Pablo Galindo Salgado [Tue, 7 Sep 2021 17:30:48 +0000 (18:30 +0100)] 
Check that 'configure' is generated by GNU Autoconf 2.69 (GH-28156)

4 years agobpo-45118: Fix regrtest second summary for re-run tests (GH-28183) (GH-28215)
Miss Islington (bot) [Tue, 7 Sep 2021 17:21:19 +0000 (10:21 -0700)] 
bpo-45118: Fix regrtest second summary for re-run tests (GH-28183) (GH-28215)

Fix regrtest second summary when using -w/--verbose2 command line
option: lists re-run tests in the second test summary.
(cherry picked from commit c4ea45d7d2c02674db2fdb96c7eee89324d2dc64)

Co-authored-by: Victor Stinner <vstinner@python.org>
4 years agobpo-45104: Clarify when __init__ is called (GH-28210) (GH-28212)
Miss Islington (bot) [Tue, 7 Sep 2021 16:27:28 +0000 (09:27 -0700)] 
bpo-45104: Clarify when __init__ is called (GH-28210) (GH-28212)

(cherry picked from commit fa15df77f02ba4a66ba0b71989381a426038be01)

Co-authored-by: Raymond Hettinger <rhettinger@users.noreply.github.com>
4 years ago[3.8] Update idlelib/help.html to include idle.rst spelling fix (GH-28191) (GH-28193)
Miss Islington (bot) [Tue, 7 Sep 2021 05:29:06 +0000 (22:29 -0700)] 
[3.8] Update idlelib/help.html to include idle.rst spelling fix (GH-28191) (GH-28193)

The idle.rst fix was GH-27903 two weeks ago.
(cherry picked from commit f05ad9202896f21ca9717f5c9f4b933b7f5b6550)

Co-authored-by: Terry Jan Reedy <tjreedy@udel.edu>
Co-authored-by: Terry Jan Reedy <tjreedy@udel.edu>
4 years agobpo-45102: unittest: add tests for skipping and errors in cleanup (GH-28166)
Miss Islington (bot) [Sun, 5 Sep 2021 07:56:24 +0000 (00:56 -0700)] 
bpo-45102: unittest: add tests for skipping and errors in cleanup (GH-28166)

(cherry picked from commit 28264269de9ff88d9ee7110fc56ac2d2db275bec)

Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
4 years ago[3.9] bpo-45042: Now test classes decorated with `requires_hashdigest` are not skippe...
Serhiy Storchaka [Sun, 5 Sep 2021 06:41:33 +0000 (09:41 +0300)] 
[3.9] bpo-45042: Now test classes decorated with `requires_hashdigest` are not skipped (GH-28060) (GH-28169)

Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>.
(cherry picked from commit dd7b816ac87e468e2fa65ce83c2a03fe1da8503e)

Co-authored-by: Nikita Sobolev <mail@sobolevn.me>
4 years agobpo-45030: Fix integer overflow in __reduce__ of the range iterator (GH-28000)
Miss Islington (bot) [Sat, 4 Sep 2021 20:39:47 +0000 (13:39 -0700)] 
bpo-45030: Fix integer overflow in __reduce__ of the range iterator (GH-28000)

It happened with fast range iterator  when the calculated stop = start + step * len
was out of the C long range.
(cherry picked from commit 936f6a16b9ef85bd56b18a247b962801e954c30e)

Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
4 years ago[3.9] bpo-45097: Remove incorrect deprecation warnings in asyncio. (GH-28153)
Serhiy Storchaka [Sat, 4 Sep 2021 17:54:50 +0000 (20:54 +0300)] 
[3.9] bpo-45097: Remove incorrect deprecation warnings in asyncio. (GH-28153)

Deprecation warnings about the loop argument were incorrectly emitted
in cases when the loop argument was used inside the asyncio library,
not from user code.

4 years agobpo-42255: Update webbrowser doc for macOS (GH-28145)
Dong-hee Na [Fri, 3 Sep 2021 17:22:01 +0000 (17:22 +0000)] 
bpo-42255: Update webbrowser doc for macOS (GH-28145)

4 years ago[3.9] bpo-45083: Include the exception class qualname when formatting an exception...
Miss Islington (bot) [Fri, 3 Sep 2021 16:56:05 +0000 (09:56 -0700)] 
[3.9] bpo-45083: Include the exception class qualname when formatting an exception (GH-28119) (GH-28135)

* bpo-45083: Include the exception class qualname when formatting an exception (GH-28119)

Co-authored-by: Erlend Egeberg Aasland <erlend.aasland@innova.no>
(cherry picked from commit b4b6342848ec0459182a992151099252434cc619)

Co-authored-by: Irit Katriel <1055913+iritkatriel@users.noreply.github.com>
Co-authored-by: Łukasz Langa <lukasz@langa.pl>
4 years agobpo-45081: Fix __init__ method generation when inheriting from Protocol (GH-28121...
Miss Islington (bot) [Thu, 2 Sep 2021 17:01:32 +0000 (10:01 -0700)] 
bpo-45081: Fix __init__ method generation when inheriting from Protocol (GH-28121) (GH-28132)

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

Co-authored-by: Yurii Karabas <1998uriyyo@gmail.com>
4 years ago[doc] Link to deprecation policy PEP from the DeprecationWarning documentation (GH...
Miss Islington (bot) [Thu, 2 Sep 2021 15:14:11 +0000 (08:14 -0700)] 
[doc] Link to deprecation policy PEP from the DeprecationWarning documentation (GH-28123) (GH-28124)

(cherry picked from commit a7ef15aae8608560bffeeaba412c10e52cab07dd)

Co-authored-by: Łukasz Langa <lukasz@langa.pl>
4 years ago[3.9] bpo-45060: Get rid of few uses of the equality operators with None (GH-28087...
Serhiy Storchaka [Wed, 1 Sep 2021 06:51:01 +0000 (09:51 +0300)] 
[3.9] bpo-45060: Get rid of few uses of the equality operators with None (GH-28087). (GH-28093)

(cherry picked from commit 3c65457156d87e55010507d616b4eecb7a02883d)

Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
4 years ago[3.9] bpo-45057: Simplify RegressionTestResult (GH-28081) (GH-28103)
Serhiy Storchaka [Wed, 1 Sep 2021 06:45:09 +0000 (09:45 +0300)] 
[3.9] bpo-45057: Simplify RegressionTestResult (GH-28081) (GH-28103)

Remove code which duplicates the functionality of TextTestResult.
(cherry picked from commit 2b76a5322fdf71d62b531fd765085f96f981c244)

4 years agobpo-45059: Add module cleanup to IDLE test_macosx (GH-28102)
Miss Islington (bot) [Tue, 31 Aug 2021 19:24:48 +0000 (12:24 -0700)] 
bpo-45059: Add module cleanup to IDLE test_macosx (GH-28102)

(cherry picked from commit 22fe0eb13c3441b71b60aaea0e7fe289a29783da)

Co-authored-by: Terry Jan Reedy <tjreedy@udel.edu>
4 years agobpo-45059: Fix IDLE test typo: using "==" instead of "=" (GH-28086)
Miss Islington (bot) [Tue, 31 Aug 2021 17:53:42 +0000 (10:53 -0700)] 
bpo-45059: Fix IDLE test typo: using "==" instead of "=" (GH-28086)

(cherry picked from commit 54f100514b02f6628450043e21ccfe39350d7ac7)

Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
4 years agobpo-44135: Refine explanation of how passing tuples to issubclass() behaves (GH-26193...
Łukasz Langa [Tue, 31 Aug 2021 16:00:16 +0000 (18:00 +0200)] 
bpo-44135: Refine explanation of how passing tuples to issubclass() behaves (GH-26193) (GH-28094)

This is a quasi-backport to 3.9 since the wording in this branch is different.

Co-authored-by: Zachary Kneupper zachary.kneupper@gmail.com
4 years agoPost 3.9.7
Łukasz Langa [Mon, 30 Aug 2021 21:55:37 +0000 (23:55 +0200)] 
Post 3.9.7

4 years agobpo-44756: Remove misleading NEWS entries of a change that was reverted before releas...
Łukasz Langa [Mon, 30 Aug 2021 21:08:20 +0000 (23:08 +0200)] 
bpo-44756: Remove misleading NEWS entries of a change that was reverted before release (GH-28075)

They are misleading because the first one is in Tools/Demos and the other one
is in Documentation so it's not easy to tell the revert happened.

4 years agoPython 3.9.7 v3.9.7
Łukasz Langa [Mon, 30 Aug 2021 19:02:15 +0000 (21:02 +0200)] 
Python 3.9.7

4 years ago[3.9] bpo-43913: Fix bugs in cleaning up classes and modules in unittest. (GH-28006...
Serhiy Storchaka [Mon, 30 Aug 2021 17:22:21 +0000 (20:22 +0300)] 
[3.9] bpo-43913: Fix bugs in cleaning up classes and modules in unittest. (GH-28006) (GH-28071)

* Functions registered with addModuleCleanup() were not called unless
  the user defines tearDownModule() in their test module.
* Functions registered with addClassCleanup() were not called if
  tearDownClass is set to None.
* Buffering in TestResult did not work with functions registered
  with addClassCleanup() and addModuleCleanup().
* Errors in functions registered with addClassCleanup() and
  addModuleCleanup() were not handled correctly in buffered and
  debug modes.
* Errors in setUpModule() and functions registered with
  addModuleCleanup() were reported in wrong order.
* And several lesser bugs..
(cherry picked from commit 08d9e597c8ef5a2b26375ac954fdf224f5d82c3c)

Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
4 years agobpo-44449: faulthandler don't modify frame refcnt (GH-27850)
Miss Islington (bot) [Mon, 30 Aug 2021 13:56:03 +0000 (06:56 -0700)] 
bpo-44449: faulthandler don't modify frame refcnt (GH-27850)

Fix a crash in the signal handler of the faulthandler module: no
longer modify the reference count of frame objects.
(cherry picked from commit fe997e1a67835a929705c8c305d41c4d7dd326e3)

Co-authored-by: Victor Stinner <vstinner@python.org>
4 years agobpo-41620: TestCase.run() now always return a TestResult instance (GH-28030) (GH...
Miss Islington (bot) [Mon, 30 Aug 2021 13:42:34 +0000 (06:42 -0700)] 
bpo-41620: TestCase.run() now always return a TestResult instance (GH-28030) (GH-28065)

Previously it returned None if the test class or method was
decorated with a skipping decorator.

Co-authored-by: Iman Tabrizian <iman.tabrizian@gmail.com>
(cherry picked from commit 7e246a3a7b43762480ee4fe0cfb859e8e997a8c8)

Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
4 years ago[3.9] bpo-45007: Update multissl to openssl 1.1.1l as well (GH-28044) (GH-28062)
Christian Heimes [Mon, 30 Aug 2021 13:07:55 +0000 (15:07 +0200)] 
[3.9] bpo-45007: Update multissl to openssl 1.1.1l as well (GH-28044) (GH-28062)

This was missed while upgrading CI..
(cherry picked from commit d6cb5dd9e19210f5963ff8beadde7ca2fda71574)

Co-authored-by: Łukasz Langa <lukasz@langa.pl>
4 years agobpo-44689: ctypes.util.find_library() now finds macOS 11+ system libraries when built...
Miss Islington (bot) [Mon, 30 Aug 2021 09:08:16 +0000 (02:08 -0700)] 
bpo-44689: ctypes.util.find_library() now finds macOS 11+ system libraries when built on older macOS systems (GH-27251) (GH-28053)

Previously, when built on older macOS systems, `find_library` was not able to find macOS system libraries when running on Big Sur due to changes in how system libraries are stored.
(cherry picked from commit 71853a73024a98aa38a3c0444fe364dbd9709134)

Co-authored-by: Tobias Bergkvist <tobias@bergkv.ist>
4 years agobpo 45007: Update macOS installer builds to use OpenSSL 1.1.1l. (GH-28051)
Miss Islington (bot) [Mon, 30 Aug 2021 07:36:02 +0000 (00:36 -0700)] 
bpo 45007: Update macOS installer builds to use OpenSSL 1.1.1l. (GH-28051)

(cherry picked from commit 94b2639fad50d7ff8acd12c11e5fe5f9a6e1da5c)

Co-authored-by: Ned Deily <nad@python.org>
4 years ago[3.9] bpo-45007: Update to OpenSSL 1.1.1l in Windows build and CI (GH-28009) (GH... 28048/head
Łukasz Langa [Sun, 29 Aug 2021 15:07:45 +0000 (17:07 +0200)] 
[3.9] bpo-45007: Update to OpenSSL 1.1.1l in Windows build and CI (GH-28009) (GH-28040)

(cherry picked from commit d3bdbbf9a4352a24fc2bfc7a63a024b244b61aba)

Co-authored-by: Steve Dower <steve.dower@python.org>
4 years agobpo-43124: Fix smtplib multiple CRLF injection (GH-25987) (GH-28035)
Miss Islington (bot) [Sun, 29 Aug 2021 14:45:25 +0000 (07:45 -0700)] 
bpo-43124: Fix smtplib multiple CRLF injection (GH-25987) (GH-28035)

Co-authored-by: Łukasz Langa <lukasz@langa.pl>
(cherry picked from commit 0897253f426068ea6a6fbe0ada01689af9ef1019)

Co-authored-by: Miguel Brito <5544985+miguendes@users.noreply.github.com>
4 years agobpo-44394: Update libexpat copy to 2.4.1 (GH-26945) (GH-28032)
Miss Islington (bot) [Sun, 29 Aug 2021 14:36:36 +0000 (07:36 -0700)] 
bpo-44394: Update libexpat copy to 2.4.1 (GH-26945) (GH-28032)

Update the vendored copy of libexpat to 2.4.1 (from 2.2.8) to get the
fix for the CVE-2013-0340 "Billion Laughs" vulnerability. This copy
is most used on Windows and macOS.

Co-authored-by: Łukasz Langa <lukasz@langa.pl>
(cherry picked from commit 3fc5d84046ddbd66abac5b598956ea34605a4e5d)

Co-authored-by: Victor Stinner <vstinner@python.org>
4 years agobpo-42278: Use tempfile.TemporaryDirectory rather than tempfile.mktemp in pydoc ...
Miss Islington (bot) [Sun, 29 Aug 2021 12:56:45 +0000 (05:56 -0700)] 
bpo-42278: Use tempfile.TemporaryDirectory rather than tempfile.mktemp in pydoc (GH-23200) (GH-28025)

Co-authored-by: Łukasz Langa <lukasz@langa.pl>
(cherry picked from commit c9227df5a9d8e958a2324cf0deba8524d1ded26a)

Co-authored-by: E-Paine <63801254+E-Paine@users.noreply.github.com>
4 years ago[3.9] bpo-25130: Add calls of gc.collect() in tests to support PyPy (GH-28005). ...
Serhiy Storchaka [Sun, 29 Aug 2021 12:08:32 +0000 (15:08 +0300)] 
[3.9] bpo-25130: Add calls of gc.collect() in tests to support PyPy (GH-28005). (GH-28028)

(cherry picked from commit 2a8127cafe1d196f858a3ecabf5f1df3eebf9a12)

4 years ago[3.9] bpo-25130: Make SQLite tests more compatible with PyPy (GH-28021) (GH-28023)
Serhiy Storchaka [Sun, 29 Aug 2021 11:03:11 +0000 (14:03 +0300)] 
[3.9] bpo-25130: Make SQLite tests more compatible with PyPy (GH-28021) (GH-28023)

(cherry picked from commit 07d3d54)

4 years ago[3.9] bpo-25130: Make unit-test about restricting the maximum number of nested blocks...
Serhiy Storchaka [Sat, 28 Aug 2021 19:24:39 +0000 (22:24 +0300)] 
[3.9] bpo-25130: Make unit-test about restricting the maximum number of nested blocks cpython-only (GH-28002) (GH-28017)

PyPy and potentially other implementations have different or no
contraints on the number of blocks that can be statically nested. move
the test that checks for this behaviour into a unit test and mark it as
CPython-only..
(cherry picked from commit eb263f9a356f5c5f21b8d5ce20bac92f31c40cad)

Co-authored-by: Carl Friedrich Bolz-Tereick <cfbolz@gmx.de>
4 years agobpo-44962: Fix a race in WeakKeyDict, WeakValueDict and WeakSet when two threads...
Miss Islington (bot) [Sat, 28 Aug 2021 18:54:48 +0000 (11:54 -0700)] 
bpo-44962: Fix a race in WeakKeyDict, WeakValueDict and WeakSet when two threads attempt to commit the last pending removal (GH-27921) (GH-28014)

Fixes:
Traceback (most recent call last):
  File "/home/graingert/projects/asyncio-demo/demo.py", line 36, in <module>
    sys.exit(main())
  File "/home/graingert/projects/asyncio-demo/demo.py", line 30, in main
    test_all_tasks_threading()
  File "/home/graingert/projects/asyncio-demo/demo.py", line 24, in test_all_tasks_threading
    results.append(f.result())
  File "/usr/lib/python3.10/concurrent/futures/_base.py", line 438, in result
    return self.__get_result()
  File "/usr/lib/python3.10/concurrent/futures/_base.py", line 390, in __get_result
    raise self._exception
  File "/usr/lib/python3.10/concurrent/futures/thread.py", line 52, in run
    result = self.fn(*self.args, **self.kwargs)
  File "/usr/lib/python3.10/asyncio/runners.py", line 47, in run
    _cancel_all_tasks(loop)
  File "/usr/lib/python3.10/asyncio/runners.py", line 56, in _cancel_all_tasks
    to_cancel = tasks.all_tasks(loop)
  File "/usr/lib/python3.10/asyncio/tasks.py", line 53, in all_tasks
    tasks = list(_all_tasks)
  File "/usr/lib/python3.10/_weakrefset.py", line 60, in __iter__
    with _IterationGuard(self):
  File "/usr/lib/python3.10/_weakrefset.py", line 33, in __exit__
    w._commit_removals()
  File "/usr/lib/python3.10/_weakrefset.py", line 57, in _commit_removals
    discard(l.pop())
IndexError: pop from empty list

Also fixes:
Exception ignored in: weakref callback <function WeakKeyDictionary.__init__.<locals>.remove at 0x00007fe82245d2e0>
Traceback (most recent call last):
  File "/usr/lib/pypy3/lib-python/3/weakref.py", line 390, in remove
    del self.data[k]
KeyError: <weakref at 0x00007fe76e8d8180; dead>
Exception ignored in: weakref callback <function WeakKeyDictionary.__init__.<locals>.remove at 0x00007fe82245d2e0>
Traceback (most recent call last):
  File "/usr/lib/pypy3/lib-python/3/weakref.py", line 390, in remove
    del self.data[k]
KeyError: <weakref at 0x00007fe76e8d81a0; dead>
Exception ignored in: weakref callback <function WeakKeyDictionary.__init__.<locals>.remove at 0x00007fe82245d2e0>
Traceback (most recent call last):
  File "/usr/lib/pypy3/lib-python/3/weakref.py", line 390, in remove
    del self.data[k]
KeyError: <weakref at 0x000056548f1e24a0; dead>

See: https://github.com/agronholm/anyio/issues/362GH-issuecomment-904424310
See also: https://bugs.python.org/issue29519

Co-authored-by: Łukasz Langa <lukasz@langa.pl>
(cherry picked from commit 206b21ed9f64fedff67bfea7cf73e423e3e32393)

Co-authored-by: Thomas Grainger <tagrain@gmail.com>
4 years agobpo-45022: Pin current libffi build to fixed version in preparation for upcoming...
Miss Islington (bot) [Fri, 27 Aug 2021 16:28:30 +0000 (09:28 -0700)] 
bpo-45022: Pin current libffi build to fixed version in preparation for upcoming update (GH-27982)

Also improve the build script for libffi, which is not used as part of the regular build.
(cherry picked from commit 969ae7f7356584e30667b4e490ffa2ffa1810429)

Co-authored-by: Steve Dower <steve.dower@python.org>
4 years agoFix typo in a comment in Modules/_ssl.c: s/validata/validate/ (GH-27993) (GH-27998)
Miss Islington (bot) [Fri, 27 Aug 2021 11:59:23 +0000 (04:59 -0700)] 
Fix typo in a comment in Modules/_ssl.c: s/validata/validate/ (GH-27993) (GH-27998)

(cherry picked from commit 28db1f61f20352c02e4ae1518e5aeb6505df3045)

Co-authored-by: Adam Dangoor <adamdangoor@gmail.com>
4 years agobpo-44997: macOS does not support loadable SQLite extensions (GH-27979) (GH-27995)
Miss Islington (bot) [Fri, 27 Aug 2021 11:36:17 +0000 (04:36 -0700)] 
bpo-44997: macOS does not support loadable SQLite extensions (GH-27979) (GH-27995)

Authored-by: Ronald Oussoren <ronaldoussoren@mac.com>
(cherry picked from commit 2ec9428e3516b6e7c6583687aa3b39fb96925577)

Co-authored-by: Erlend Egeberg Aasland <erlend.aasland@innova.no>
4 years agobpo-45018: Fix rangeiter_reduce in rangeobject.c (GH-27938) (GH-27991)
Miss Islington (bot) [Fri, 27 Aug 2021 10:52:07 +0000 (03:52 -0700)] 
bpo-45018: Fix rangeiter_reduce in rangeobject.c (GH-27938) (GH-27991)

Co-authored-by: Łukasz Langa <lukasz@langa.pl>
(cherry picked from commit 94a3d2a6329ab7941e93ad2f5bcbb8af2b8b80d2)

Co-authored-by: chilaxan <chilaxan@gmail.com>
4 years agobpo-40635: Fix getfqdn() docstring and docs (GH-27971)
Miss Islington (bot) [Thu, 26 Aug 2021 19:55:22 +0000 (12:55 -0700)] 
bpo-40635: Fix getfqdn() docstring and docs (GH-27971)

Co-authored-by: Łukasz Langa <lukasz@langa.pl>
(cherry picked from commit fdcb675eed47b1f6054fae381af4388b16a6fff4)

Co-authored-by: andrei kulakov <andrei.avk@gmail.com>
4 years ago[3.9] bpo-45011: Fix test_asyncio without C module _asyncio (GH-27968) (GH-27970)
Miss Islington (bot) [Thu, 26 Aug 2021 17:56:50 +0000 (10:56 -0700)] 
[3.9] bpo-45011: Fix test_asyncio without C module _asyncio (GH-27968) (GH-27970)

Co-authored-by: Łukasz Langa <lukasz@langa.pl>
(cherry picked from commit 7dc505b8655b3e48b93a4274dfd26e5856d9c64f)

Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
4 years agobpo-45001: Make email date parsing more robust against malformed input (GH-27946...
Miss Islington (bot) [Thu, 26 Aug 2021 15:48:20 +0000 (08:48 -0700)] 
bpo-45001: Make email date parsing more robust against malformed input (GH-27946) (GH-27973)

Various date parsing utilities in the email module, such as
email.utils.parsedate(), are supposed to gracefully handle invalid
input, typically by raising an appropriate exception or by returning
None.

The internal email._parseaddr._parsedate_tz() helper used by some of
these date parsing routines tries to be robust against malformed input,
but unfortunately it can still crash ungracefully when a non-empty but
whitespace-only input is passed. This manifests as an unexpected
IndexError.

In practice, this can happen when parsing an email with only a newline
inside a ‘Date:’ header, which unfortunately happens occasionally in the
real world.

Here's a minimal example:

    $ python
    Python 3.9.6 (default, Jun 30 2021, 10:22:16)
    [GCC 11.1.0] on linux
    Type "help", "copyright", "credits" or "license" for more information.
    >>> import email.utils
    >>> email.utils.parsedate('foo')
    >>> email.utils.parsedate(' ')
    Traceback (most recent call last):
      File "<stdin>", line 1, in <module>
      File "/usr/lib/python3.9/email/_parseaddr.py", line 176, in parsedate
        t = parsedate_tz(data)
      File "/usr/lib/python3.9/email/_parseaddr.py", line 50, in parsedate_tz
        res = _parsedate_tz(data)
      File "/usr/lib/python3.9/email/_parseaddr.py", line 72, in _parsedate_tz
        if data[0].endswith(',') or data[0].lower() in _daynames:
    IndexError: list index out of range

The fix is rather straight-forward: guard against empty lists, after
splitting on whitespace, but before accessing the first element.
(cherry picked from commit 989f6a3800f06b2bd31cfef7c3269a443ad94fac)

Co-authored-by: wouter bolsterlee <wouter@bolsterl.ee>
4 years agobpo-45003: Change __div__ to __truediv__ in py3 language reference. (GH-27951) (GH...
Miss Islington (bot) [Thu, 26 Aug 2021 07:03:18 +0000 (00:03 -0700)] 
bpo-45003: Change __div__ to __truediv__ in py3 language reference. (GH-27951) (GH-27962)

(cherry picked from commit 806e25fd3173a80021e6df87b81263b5f6056f38)

Co-authored-by: Objectivitix <79152594+Objectivitix@users.noreply.github.com>
4 years ago[3.9] bpo-43853: Amend NEWS entry for latest changes in sqlite3 (GH-27922) (GH-27952)
Erlend Egeberg Aasland [Wed, 25 Aug 2021 19:26:28 +0000 (21:26 +0200)] 
[3.9] bpo-43853: Amend NEWS entry for latest changes in sqlite3 (GH-27922) (GH-27952)

(cherry picked from commit 7903a1096343d8018e889029f025d39bdd077170)

Co-authored-by: Erlend Egeberg Aasland <erlend.aasland@innova.no>
4 years ago[3.9] bpo-27334: roll back transaction if sqlite3 context manager fails to commit...
Erlend Egeberg Aasland [Wed, 25 Aug 2021 19:02:25 +0000 (21:02 +0200)] 
[3.9] bpo-27334: roll back transaction if sqlite3 context manager fails to commit (GH-26202) (GH-27944)

4 years ago[3.9] bpo-34990: Treat the pyc header's mtime in compileall as an unsigned int (GH...
Miss Islington (bot) [Tue, 24 Aug 2021 15:07:31 +0000 (08:07 -0700)] 
[3.9] bpo-34990: Treat the pyc header's mtime in compileall as an unsigned int (GH-19708)

(cherry picked from commit bb21e28fd08f894ceff2405544a2f257d42b1354)

Co-authored-by: Ammar Askar <ammar@ammaraskar.com>
Co-authored-by: Stéphane Wirtel <stephane@wirtel.be>
4 years ago[doc] Fix typo c-api/exceptions.rst (GH-27847) (GH-27919)
Miss Islington (bot) [Mon, 23 Aug 2021 20:09:52 +0000 (13:09 -0700)] 
[doc] Fix typo c-api/exceptions.rst (GH-27847) (GH-27919)

Co-authored-by: Tianqing Peng <pengtianqing@yimian.com.cn>
(cherry picked from commit dcbf7ff6a700b63e637a0445d68866670a398024)

Co-authored-by: Sunny Bean <ptq008@gmail.com>
4 years ago[doc] Added mailing list link for comp.lang.python (GH-27852) (GH-27916)
Miss Islington (bot) [Mon, 23 Aug 2021 19:24:12 +0000 (12:24 -0700)] 
[doc] Added mailing list link for comp.lang.python (GH-27852) (GH-27916)

(cherry picked from commit 7b550dfce64bd134c5604fd1f2d4c43ae2b669e4)

Co-authored-by: Mike Smith <mikesmith@screamingjoypad.com>
4 years agobpo-44980: fix test_constructor to return None value (GH-27898) (GH-27914)
Miss Islington (bot) [Mon, 23 Aug 2021 19:20:29 +0000 (12:20 -0700)] 
bpo-44980: fix test_constructor to return None value (GH-27898) (GH-27914)

(cherry picked from commit 27b761a11a14521617a01257eb3767150bec3a74)

Co-authored-by: andrei kulakov <andrei.avk@gmail.com>
4 years ago[3.9] bpo-44984: Rewrite test_null_strings in _testcapi (GH-27904) (GH-27910)
Łukasz Langa [Mon, 23 Aug 2021 18:48:04 +0000 (20:48 +0200)] 
[3.9] bpo-44984: Rewrite test_null_strings in _testcapi (GH-27904) (GH-27910)

Test also PyObject_Repr(NULL) and PyObject_Bytes(NULL)..
(cherry picked from commit 4d689173861257c69adc6dc1dca4171946ddb57f)

Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
4 years ago[doc] Fix typo in idle.rst (GH-27903)
Miss Islington (bot) [Mon, 23 Aug 2021 17:57:05 +0000 (10:57 -0700)] 
[doc] Fix typo in idle.rst (GH-27903)

intially -> initially
(cherry picked from commit 0e8695ece0d3569eeb1b89c91a1b0aa3d34f228e)

Co-authored-by: Ikko Ashimine <eltociear@gmail.com>
4 years ago[3.9] bpo-4442: Document use of __new__ for subclasses of immutable types (GH-27866...
Łukasz Langa [Sun, 22 Aug 2021 20:14:25 +0000 (22:14 +0200)] 
[3.9] bpo-4442:  Document use of __new__ for subclasses of immutable types (GH-27866) (GH-27900)

(cherry picked from commit eec340ea3af27887fcaac4029ebdee99f3713bff)

Co-authored-by: Raymond Hettinger <rhettinger@users.noreply.github.com>
4 years ago[3.9] bpo-42560: rework external references in Tkinter docs (GH-27838) (GH-27896)
Łukasz Langa [Sun, 22 Aug 2021 19:06:06 +0000 (21:06 +0200)] 
[3.9] bpo-42560: rework external references in Tkinter docs (GH-27838) (GH-27896)

- reorganized from two sections (tkinter vs. tcl/tk) into three (tkinter, tcl/tk, and books)
- main (recommended) tkinter docs have one tutorial (tkdocs) and one reference (shipman), added better descriptions
- dropped link to Tkinter page on wiki (suggestion by E. Paine; outdated, most material already linked to from python.org)
- replaced Tcl/Tk recent man pages and core dev home with single link to main Tcl/Tk page (which holds both of these)
- updated Modern Tkinter link to book page on TkDocs site (was Amazon link to old version), dropped description
- replaced Grayson book by Moore book (newer, covers ttk)
- changed Ousterhout ref to second edition, covers ttk
- dropped link to Welch book (old).
(cherry picked from commit d1049d1d6b43296d4db1aa8668aa4ca807bf7adb)

Co-authored-by: Mark Roseman <mark@markroseman.com>
4 years agobpo-42560: reorganize Tkinter docs modules section for clarity (GH-27840) (GH-27895)
Miss Islington (bot) [Sun, 22 Aug 2021 19:05:46 +0000 (12:05 -0700)] 
bpo-42560: reorganize Tkinter docs modules section for clarity (GH-27840) (GH-27895)

- move description of internal modules (_tkinter and tkinter.constants) from section intro to list of additional modules at end of section, as not most important info
- added missing ttk and tix here
- emphasized up front that most apps will need tkinter and ttk
(cherry picked from commit d5dbe8bca792350f4997c027535e0ca498abd1bb)

Co-authored-by: Mark Roseman <mark@markroseman.com>