]> git.ipfire.org Git - thirdparty/Python/cpython.git/log
thirdparty/Python/cpython.git
4 years agobpo-10548: expectedFailure does not apply to fixtures (#23201)
Irit Katriel [Tue, 11 May 2021 21:48:20 +0000 (22:48 +0100)] 
bpo-10548: expectedFailure does not apply to fixtures (#23201)

4 years agobpo-23750: Document os-system, subprocess. Patch by Martin Panter. (GH-26016)
uniocto [Tue, 11 May 2021 20:47:05 +0000 (05:47 +0900)] 
bpo-23750: Document os-system, subprocess. Patch by Martin Panter. (GH-26016)

* Document os-system, subprocess Patch

* Update Doc/library/os.rst

Co-authored-by: Ken Jin <28750310+Fidget-Spinner@users.noreply.github.com>
Co-authored-by: Ken Jin <28750310+Fidget-Spinner@users.noreply.github.com>
4 years agobpo-25821: Fix inaccuracy in threading.enumerate/is_alive documentation (#23192)
Irit Katriel [Tue, 11 May 2021 17:55:24 +0000 (18:55 +0100)] 
bpo-25821: Fix inaccuracy in threading.enumerate/is_alive documentation (#23192)

4 years agobpo-43795: PEP 652 user documentation (GH-25668)
Petr Viktorin [Tue, 11 May 2021 14:04:33 +0000 (16:04 +0200)] 
bpo-43795: PEP 652 user documentation (GH-25668)

- Reformat the C API and ABI Versioning page (and extend/clarify a bit)
- Rewrite the stable ABI docs into a general text on C API Compatibility
- Add a list of Limited API contents, and notes for the individual items.
- Replace `Include/README.rst` with a link to a devguide page with the same info

4 years agoDoc: http.server: directory is not a class attribute, but an argument. (GH-26017)
Julien Palard [Tue, 11 May 2021 01:26:53 +0000 (03:26 +0200)] 
Doc: http.server: directory is not a class attribute, but an argument. (GH-26017)

* Doc: http.server: directory is not a class attribute, but an argument.

4 years agobpo-43743 add comment stating _USE_CP_SENDFILE should not be removed (#26024)
Giampaolo Rodola [Mon, 10 May 2021 20:45:06 +0000 (22:45 +0200)] 
bpo-43743 add comment stating _USE_CP_SENDFILE should not be removed (#26024)

4 years agobpo-44074: let patchcheck infer the base branch name (GH-25991)
Leonardo Lai [Mon, 10 May 2021 18:34:27 +0000 (20:34 +0200)] 
bpo-44074: let patchcheck infer the base branch name (GH-25991)

4 years agobpo-43558: Add note about base class initialization to dataclasses doc (GH-25967)
dhoekstra2000 [Mon, 10 May 2021 13:30:22 +0000 (15:30 +0200)] 
bpo-43558: Add note about base class initialization to dataclasses doc (GH-25967)

4 years agoPrevent access outside buffer (GH-26012)
Dennis Sweeney [Mon, 10 May 2021 09:10:22 +0000 (05:10 -0400)] 
Prevent access outside buffer (GH-26012)

4 years agoRevert test for Tix deprecation warning (GH-26005)
Zachary Ware [Sun, 9 May 2021 06:58:35 +0000 (01:58 -0500)] 
Revert test for Tix deprecation warning (GH-26005)

Added in bpo-41730 (GH-22186), the test apparently causes refleaks.  The
test isn't worth hunting them down, so it's simply reverted.

This partially reverts commit 4a2d98a1e98de25c5114d11fcb0f9fedbb057e51.

4 years agoFix a word in dataclasses docs. (GH-26003)
Eric V. Smith [Sun, 9 May 2021 02:20:04 +0000 (22:20 -0400)] 
Fix a word in dataclasses docs. (GH-26003)

4 years agobpo-43417: Better buffer handling for ast.unparse (GH-24772)
Batuhan Taskaya [Sat, 8 May 2021 23:32:04 +0000 (02:32 +0300)] 
bpo-43417: Better buffer handling for ast.unparse (GH-24772)

4 years agobpo-28307: Convert simple C-style formatting with literal format into f-string. ...
Serhiy Storchaka [Sat, 8 May 2021 19:33:10 +0000 (22:33 +0300)] 
bpo-28307: Convert simple C-style formatting with literal format into f-string. (GH-5012)

C-style formatting with literal format containing only format codes
%s, %r and %a (with optional width, precision and alignment)
will be converted to an equivalent f-string expression.

It can speed up formatting more than 2 times by eliminating
runtime parsing of the format string and creating temporary tuple.

4 years agobpo-43149: Correct the syntax error message for multiple exception types (GH-25996)
Pablo Galindo [Sat, 8 May 2021 18:24:41 +0000 (19:24 +0100)] 
bpo-43149: Correct the syntax error message for multiple exception types (GH-25996)

Automerge-Triggered-By: GH:pablogsal
4 years agoUpdate references to master to point to main in customsourcelink.html (GH-25993)
Pablo Galindo [Sat, 8 May 2021 16:13:24 +0000 (17:13 +0100)] 
Update references to master to point to main in customsourcelink.html (GH-25993)

4 years agobpo-42725: mention the changes on what's new (GH-25974)
Batuhan Taskaya [Sat, 8 May 2021 11:49:40 +0000 (14:49 +0300)] 
bpo-42725: mention the changes on what's new (GH-25974)

4 years agobpo-31904: Correct error string in test_file_not_exists() for VxWorks (GH-25965)
pxinwr [Sat, 8 May 2021 08:03:41 +0000 (16:03 +0800)] 
bpo-31904: Correct error string in test_file_not_exists() for VxWorks (GH-25965)

The error string on VxWorks is "no such file or directory" for FileNotFoundError. That is, the 1st letter of the error string has lower case.

4 years agoFix make libainstall. (GH-25980)
Senthil Kumaran [Sat, 8 May 2021 06:38:08 +0000 (23:38 -0700)] 
Fix make libainstall. (GH-25980)

Initial patch by Benno Leslie.

4 years agoFix the whatsnew/3.11.rst to link to the blurb-generated changelog. (GH-25979)
Ned Deily [Sat, 8 May 2021 03:25:37 +0000 (23:25 -0400)] 
Fix the whatsnew/3.11.rst to link to the blurb-generated changelog. (GH-25979)

4 years agoUpdate the SOURCE_URI in pyspecific.py to point to the new branch (GH-25977)
Pablo Galindo [Sat, 8 May 2021 02:43:23 +0000 (03:43 +0100)] 
Update the SOURCE_URI in pyspecific.py to point to the new branch (GH-25977)

4 years agoAdd the blurbify of the 3.10.0b1 changelog to the main branch (GH-25976)
Ned Deily [Sat, 8 May 2021 02:31:01 +0000 (22:31 -0400)] 
Add the blurbify of the 3.10.0b1 changelog to the main branch (GH-25976)

4 years agoDo not use Py_ssize_clean_t (GH-25940)
Inada Naoki [Sat, 8 May 2021 01:17:37 +0000 (10:17 +0900)] 
Do not use Py_ssize_clean_t (GH-25940)

4 years agobpo-44026: Idle - display interpreter's 'did you mean' hints (GH-25912)
E-Paine [Fri, 7 May 2021 23:52:01 +0000 (00:52 +0100)] 
bpo-44026: Idle - display interpreter's 'did you mean' hints (GH-25912)

A C function accessible by the default exception handler, but not by python code,
finds the existing name closest to the name causing a name or attribute error.  For
such errors, call the default handler after capturing stderr and retrieve its message line.

Co-authored-by: Terry Jan Reedy <tjreedy@udel.edu>
4 years agobpo-44063: set the missing end locations on the compiler (GH-25956)
Batuhan Taskaya [Fri, 7 May 2021 17:49:06 +0000 (20:49 +0300)] 
bpo-44063: set the missing end locations on the compiler (GH-25956)

4 years agobpo-41730: Show deprecation warnings for tkinter.tix (GH-22186)
wyz23x2 [Fri, 7 May 2021 15:53:23 +0000 (23:53 +0800)] 
bpo-41730: Show deprecation warnings for tkinter.tix (GH-22186)

Co-authored-by: E-Paine <63801254+E-Paine@users.noreply.github.com>
Co-authored-by: Zachary Ware <zach@python.org>
4 years agobpo-40222: "Zero cost" exception handling (GH-25729)
Mark Shannon [Fri, 7 May 2021 14:19:19 +0000 (15:19 +0100)] 
bpo-40222: "Zero cost" exception handling (GH-25729)

"Zero cost" exception handling.

* Uses a lookup table to determine how to handle exceptions.
* Removes SETUP_FINALLY and POP_TOP block instructions, eliminating (most of) the runtime overhead of try statements.
* Reduces the size of the frame object by about 60%.

4 years agoSimple Enhancement. Add missing return statements in ftplib documentation. (GH-25968)
Senthil Kumaran [Fri, 7 May 2021 14:08:47 +0000 (07:08 -0700)] 
Simple Enhancement. Add missing return statements in ftplib documentation. (GH-25968)

4 years agobpo-44047: Remove unused argument to _pysqlite_seterror (GH-25915)
Erlend Egeberg Aasland [Fri, 7 May 2021 13:15:01 +0000 (15:15 +0200)] 
bpo-44047: Remove unused argument to _pysqlite_seterror (GH-25915)

4 years agoDoc: What's new in Python 3.11 (GH-25963)
Julien Palard [Fri, 7 May 2021 08:06:45 +0000 (10:06 +0200)] 
Doc: What's new in Python 3.11 (GH-25963)

4 years agobpo-44029: Remove Py_UNICODE APIs (GH-25881)
Inada Naoki [Fri, 7 May 2021 06:58:29 +0000 (15:58 +0900)] 
bpo-44029: Remove Py_UNICODE APIs (GH-25881)

Remove deprecated `Py_UNICODE` APIs: `PyUnicode_Encode`,
`PyUnicode_EncodeUTF7`, `PyUnicode_EncodeUTF8`,
`PyUnicode_EncodeUTF16`, `PyUnicode_EncodeUTF32`,
`PyUnicode_EncodeLatin1`, `PyUnicode_EncodeMBCS`,
`PyUnicode_EncodeDecimal`, `PyUnicode_EncodeRawUnicodeEscape`,
`PyUnicode_EncodeCharmap`, `PyUnicode_EncodeUnicodeEscape`,
`PyUnicode_TransformDecimalToASCII`, `PyUnicode_TranslateCharmap`,
`PyUnicodeEncodeError_Create`, `PyUnicodeTranslateError_Create`.

See :pep:`393` and :pep:`624` for reference.

4 years agobpo-40943: Fix skipitem() didn't raise SystemError (GH-25937)
Inada Naoki [Fri, 7 May 2021 02:56:48 +0000 (11:56 +0900)] 
bpo-40943: Fix skipitem() didn't raise SystemError (GH-25937)

`convertitem()` raises `SystemError` when '#' is used without `PY_SSIZE_T_CLEAN`.
This commit makes `skipitem()` raise it too.

4 years agoFix minor grammar problems in dataclasses documentation (GH-25948)
Scott Noyes [Thu, 6 May 2021 21:52:46 +0000 (16:52 -0500)] 
Fix minor grammar problems in dataclasses documentation (GH-25948)

Some missing words; some odd word choices.

4 years agodocs: clearly document that ":#X" string formatting results in "0X..." (GH-25941)
Tal Einat [Thu, 6 May 2021 19:27:29 +0000 (22:27 +0300)] 
docs: clearly document that ":#X" string formatting results in "0X..." (GH-25941)

* clearly document that ":#X" string formatting results in "0X..."

* put back the "serial comma"

4 years agobpo-43972: Set content-length to 0 for http.server.SimpleHTTPRequestHandler 301s...
Stephen Rosen [Thu, 6 May 2021 19:25:52 +0000 (15:25 -0400)] 
bpo-43972: Set content-length to 0 for http.server.SimpleHTTPRequestHandler 301s (GH-25705)

* Set content-length for simple http server 301s

When http.server.SimpleHTTPRequestHandler sends a 301 (Moved
Permanently) due to a missing file, it does not set a Content-Length
of 0. Unfortunately, certain clients can be left waiting for the
connection to be closed in this circumstance, even though no body
will be sent. At time of writing, both curl and Firefox demonstrate
this behavior.

* Test Content-Length on simple http server redirect

When serving a redirect, the SimpleHTTPRequestHandler will now send
`Content-Length: 0`. Several tests for http.server already cover
various behaviors and checks including redirection. This change only
adds one check for the expected Content-Length on the simplest case
for a redirect.

* Add news entry for SimpleHTTPRequestHandler fix

* Clarify the specific kind of 301

Co-authored-by: Senthil Kumaran <skumaran@gatech.edu>
4 years agobpo-44059: Register the SerenityOS Browser in the webbrowser module (GH-25947)
Linus Groh [Thu, 6 May 2021 19:01:12 +0000 (20:01 +0100)] 
bpo-44059: Register the SerenityOS Browser in the webbrowser module (GH-25947)

Automerge-Triggered-By: GH:gpshead
4 years agoEliminate duplicated calculations and unnecessary work for linear regression (GH...
Raymond Hettinger [Thu, 6 May 2021 14:43:13 +0000 (07:43 -0700)] 
Eliminate duplicated calculations and unnecessary work for linear regression (GH-25922)

4 years agobpo-38820: Test with OpenSSL 3.0.0-alpha16 (GH-25942)
Christian Heimes [Thu, 6 May 2021 14:30:12 +0000 (16:30 +0200)] 
bpo-38820: Test with OpenSSL 3.0.0-alpha16 (GH-25942)

Also use new make target to install FIPS provider.

4 years agobpo-44017: Update test_contextlib_async not to emit DeprecationWarn (GH-25918)
Dong-hee Na [Thu, 6 May 2021 14:10:52 +0000 (23:10 +0900)] 
bpo-44017: Update test_contextlib_async not to emit DeprecationWarn (GH-25918)

4 years agobpo-43882 Remove the newline, and tab early. From query and fragments. (GH-25921)
Senthil Kumaran [Wed, 5 May 2021 22:50:05 +0000 (15:50 -0700)] 
bpo-43882 Remove the newline, and tab early. From query and fragments. (GH-25921)

4 years agobpo-44022: Fix http client infinite line reading (DoS) after a HTTP 100 Continue...
Gen Xu [Wed, 5 May 2021 22:42:41 +0000 (15:42 -0700)] 
bpo-44022: Fix http client infinite line reading (DoS) after a HTTP 100 Continue (GH-25916)

Fixes http.client potential denial of service where it could get stuck reading lines from a malicious server after a 100 Continue response.

Co-authored-by: Gregory P. Smith <greg@krypto.org>
4 years agobpo-36515: Disable unaligned memory access in _sha3 on ARM (GH-25927)
Gregory P. Smith [Wed, 5 May 2021 20:55:33 +0000 (13:55 -0700)] 
bpo-36515: Disable unaligned memory access in _sha3 on ARM (GH-25927)

Contributed-By: Matthias Klose
Automerge-Triggered-By: GH:tiran
4 years agobpo-35753: Fix crash in doctest with unwrap-able functions (#22981)
Alfred Perlstein [Wed, 5 May 2021 17:33:17 +0000 (10:33 -0700)] 
bpo-35753: Fix crash in doctest with unwrap-able functions (#22981)

Ignore objects that inspect.unwrap throws due to
too many wrappers.  This is a very rare case, however
it can easily be surfaced when a module under doctest
imports unitest.mock.call into its namespace.

We simply skip any object that throws this exception.
This should handle the majority of cases.

4 years agobpo-43795: Mark PyCodec_Unregister as a function, not data, in stable ABI (GH-25920)
Petr Viktorin [Wed, 5 May 2021 17:32:21 +0000 (19:32 +0200)] 
bpo-43795: Mark PyCodec_Unregister as a function, not data, in stable ABI (GH-25920)

4 years agotyping: format patch with make patchcheck (GH-25919)
Dong-hee Na [Wed, 5 May 2021 17:08:20 +0000 (02:08 +0900)] 
typing: format patch with make patchcheck (GH-25919)

4 years agobpo-44040: Update broken link in pathlib source (GH-25905)
Kevin Follstad [Wed, 5 May 2021 08:08:26 +0000 (01:08 -0700)] 
bpo-44040: Update broken link in pathlib source (GH-25905)

4 years agoEliminate duplicated assignment in _randommodule.c (GH-25904)
Brad Larsen [Wed, 5 May 2021 03:41:11 +0000 (23:41 -0400)] 
Eliminate duplicated assignment in _randommodule.c (GH-25904)

4 years agobpo-40521: Convert deque freelist from global vars to instance vars (GH-25906)
Raymond Hettinger [Wed, 5 May 2021 00:08:31 +0000 (17:08 -0700)] 
bpo-40521: Convert deque freelist from global vars to instance vars (GH-25906)

4 years agobpo-40297: Fix test_socket.CANTest.testSendFrame (GH-19548)
karl ding [Tue, 4 May 2021 20:37:13 +0000 (13:37 -0700)] 
bpo-40297: Fix test_socket.CANTest.testSendFrame (GH-19548)

The address tuple for CAN_RAW no longer returns the address family
after the introduction of CAN ISO-TP support in a30f6d45ac3. However,
updating test_socket.CANTest.testSendFrame was missed as part of the
change, so the test incorrectly attempts to index past the last tuple
item to retrieve the address family.

This removes the now-redundant check for equality against socket.AF_CAN,
as the tuple will not contain the address family.

4 years agoClarify rx parameter of compileall functions (#25857)
Jean-Abou-Samra [Tue, 4 May 2021 19:37:39 +0000 (21:37 +0200)] 
Clarify rx parameter of compileall functions (#25857)

4 years agoFix inconsistent fsum vs sum and fmean vs mean (GH-25898)
Raymond Hettinger [Tue, 4 May 2021 18:27:28 +0000 (11:27 -0700)] 
Fix inconsistent fsum vs sum and fmean vs mean (GH-25898)

4 years agoFix typo in ast.py (GH-25740)
Ikko Ashimine [Tue, 4 May 2021 13:18:58 +0000 (22:18 +0900)] 
Fix typo in ast.py (GH-25740)

parantheses -> parentheses

4 years agobpo-42686: Enable SQLite math functions in Windows build (#24053)
Erlend Egeberg Aasland [Tue, 4 May 2021 12:47:44 +0000 (14:47 +0200)] 
bpo-42686: Enable SQLite math functions in Windows build (#24053)

4 years agobpo-32822: Add finally with return/break/continue to the tutorial (#25600)
Roberto Hueso [Tue, 4 May 2021 12:36:01 +0000 (14:36 +0200)] 
bpo-32822: Add finally with return/break/continue to the tutorial (#25600)

This documents in the tutorial docs the behavior of a finally clause in
case it should re-raise an exception but contains a
return/break/continue statement.

4 years agoFix error in Enum documentation example code that was referring to the wrong enum...
krisaoe [Tue, 4 May 2021 12:34:14 +0000 (22:34 +1000)] 
Fix error in Enum documentation example code that was referring to the wrong enum. (#25837)

4 years agoAdd C-API tests (#25886)
Ken Jin [Tue, 4 May 2021 11:07:31 +0000 (19:07 +0800)] 
Add C-API tests (#25886)

4 years agobpo-38352: Add to typing.__all__ (#25821)
Jelle Zijlstra [Tue, 4 May 2021 09:29:49 +0000 (02:29 -0700)] 
bpo-38352: Add to typing.__all__ (#25821)

This adds IO, TextIO, BinaryIO, Match, and Pattern.

Co-authored-by: Łukasz Langa <lukasz@langa.pl>
Co-authored-by: Ken Jin <28750310+Fidget-Spinner@users.noreply.github.com>
4 years agoCopyedits to 3.10 What's New (#25787)
Jelle Zijlstra [Tue, 4 May 2021 09:19:23 +0000 (02:19 -0700)] 
Copyedits to 3.10 What's New (#25787)

Co-authored-by: Dominic Davis-Foster <dominic@davis-foster.co.uk>
4 years agobpo-44025: Clarify when '_' is a keyword. (#25873)
Terry Jan Reedy [Tue, 4 May 2021 09:00:29 +0000 (05:00 -0400)] 
bpo-44025: Clarify when '_' is a keyword. (#25873)

In match statements, in case patterns and nowhere else.

Co-authored-by: Jelle Zijlstra <jelle.zijlstra@gmail.com>
4 years agobpo-40465: Remove random module features deprecated in 3.9 (GH-25874)
Raymond Hettinger [Tue, 4 May 2021 08:55:40 +0000 (01:55 -0700)] 
bpo-40465: Remove random module features deprecated in 3.9 (GH-25874)

4 years agobpo-44001: improve Literal documentation (GH-25877)
Jelle Zijlstra [Tue, 4 May 2021 08:54:12 +0000 (01:54 -0700)] 
bpo-44001: improve Literal documentation (GH-25877)

4 years agobpo-43666: Lib/_aix_support.py routines may fail in a WPAR environment (GH-25095)
Michael Felt [Tue, 4 May 2021 08:36:50 +0000 (10:36 +0200)] 
bpo-43666: Lib/_aix_support.py routines may fail in a WPAR environment (GH-25095)

Since WPAR and LPAR both have a builddate for teh fileset bos.rte
The name of the fileset checked is modified.
To prevent a similiar situation (no builddate in ODM) a value
sufficient for pep425 activity if retrieved buildate is zero or NULL
Patch by M Felt.

4 years agoupdate docstring for `win_getpass` to reflect code changes (GH-24967)
Jürgen Gmach [Tue, 4 May 2021 06:48:29 +0000 (08:48 +0200)] 
update docstring for `win_getpass` to reflect code changes (GH-24967)

The code was updated in
https://github.com/python/cpython/commit/0ec88b33d093db00ec68b220247681354a650f0c
but the docstring was left untouched.

=> updated the docstring to reflect the code changes

4 years agofix enum.property reference in docs (GH-25875)
Jelle Zijlstra [Tue, 4 May 2021 03:19:46 +0000 (20:19 -0700)] 
fix enum.property reference in docs (GH-25875)

4 years agofix enum and backslash warnings (GH-25861)
Ethan Furman [Tue, 4 May 2021 01:44:30 +0000 (18:44 -0700)] 
fix enum and backslash warnings (GH-25861)

- Enum warning in test_faulthandler
- backslash warning in test_ipaddress

4 years agobuild(deps): bump actions/cache from v2.1.4 to v2.1.5 (#25773)
dependabot[bot] [Tue, 4 May 2021 01:09:51 +0000 (03:09 +0200)] 
build(deps): bump actions/cache from v2.1.4 to v2.1.5 (#25773)

Bumps [actions/cache](https://github.com/actions/cache) from v2.1.4 to v2.1.5.
- [Release notes](https://github.com/actions/cache/releases)
- [Commits](https://github.com/actions/cache/compare/v2.1.4...1a9e2138d905efd099035b49d8b7a3888c653ca8)

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
4 years agobuild(deps): bump actions/upload-artifact from v2.2.2 to v2.2.3 (#25772)
dependabot[bot] [Tue, 4 May 2021 01:09:34 +0000 (03:09 +0200)] 
build(deps): bump actions/upload-artifact from v2.2.2 to v2.2.3 (#25772)

Bumps [actions/upload-artifact](https://github.com/actions/upload-artifact) from v2.2.2 to v2.2.3.
- [Release notes](https://github.com/actions/upload-artifact/releases)
- [Commits](https://github.com/actions/upload-artifact/compare/v2.2.2...ee69f02b3dfdecd58bb31b4d133da38ba6fe3700)

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
4 years agobpo-43822: Prioritize tokenizer errors over custom syntax errors when raising parser...
Pablo Galindo [Tue, 4 May 2021 00:32:46 +0000 (01:32 +0100)] 
bpo-43822: Prioritize tokenizer errors over custom syntax errors when raising parser exceptions (GH-25866)

4 years agoCorrect the version of the first alpha in the README.rst (GH-25862)
Pablo Galindo [Mon, 3 May 2021 23:28:47 +0000 (00:28 +0100)] 
Correct the version of the first alpha in the README.rst (GH-25862)

4 years agobpo-44018: random.seed() no longer mutates its inputs (GH-25856)
Raymond Hettinger [Mon, 3 May 2021 23:11:35 +0000 (16:11 -0700)] 
bpo-44018: random.seed() no longer mutates its inputs (GH-25856)

4 years agoUpdate CI files to account for the master -> main rename (GH-25860)
Pablo Galindo [Mon, 3 May 2021 22:36:55 +0000 (23:36 +0100)] 
Update CI files to account for the master -> main rename (GH-25860)

4 years agoPython 3.11.0a0
Pablo Galindo [Mon, 3 May 2021 20:25:35 +0000 (21:25 +0100)] 
Python 3.11.0a0

4 years agoRemove Enum warnings from test_httpservers (GH-25844)
Shreyan Avigyan [Mon, 3 May 2021 19:27:47 +0000 (00:57 +0530)] 
Remove Enum warnings from test_httpservers (GH-25844)

4 years agobpo-38530: Refactor and improve AttributeError suggestions (GH-25776)
Dennis Sweeney [Mon, 3 May 2021 15:47:27 +0000 (11:47 -0400)] 
bpo-38530: Refactor and improve AttributeError suggestions (GH-25776)

- Make case-swaps half the cost of any other edit
- Refactor Levenshtein code to not use memory allocator, and to bail early on no match.
- Add comments to Levenshtein distance code
- Add test cases for Levenshtein distance behind a debug macro
- Set threshold to `(name_size + item_size + 3) * MOVE_COST / 6`.
  - Reasoning: similar to `difflib.SequenceMatcher.ratio()` >= 2/3:
```
"Multiset Jaccard similarity" >= 2/3
matching letters / total letters >= 2/3
(name_size - distance + item_size - distance) / (name_size + item_size) >= 2/3
1 - (2*distance) / (name_size + item_size) >= 2/3
1/3 >= (2*distance) / (name_size + item_size)
(name_size + item_size) / 6 >= distance
With rounding:
(name_size + item_size + 3) // 6 >= distance
```

Co-authored-by: Pablo Galindo <pablogsal@gmail.com>
4 years agobpo-43943: ssl tests: Increase server socket timeout, backlog, debugging (GH-25850)
Christian Heimes [Mon, 3 May 2021 15:45:02 +0000 (17:45 +0200)] 
bpo-43943: ssl tests: Increase server socket timeout, backlog, debugging (GH-25850)

Signed-off-by: Christian Heimes <christian@python.org>
4 years agobpo-44011: Revert "New asyncio ssl implementation (GH-17975)" (GH-25848)
Pablo Galindo [Mon, 3 May 2021 15:21:59 +0000 (16:21 +0100)] 
bpo-44011: Revert "New asyncio ssl implementation (GH-17975)" (GH-25848)

This reverts commit 5fb06edbbb769561e245d0fe13002bab50e2ae60 and all
subsequent dependent commits.

4 years agobpo-43754: Fix compiler warning in Python/compile.c (GH-25855)
Pablo Galindo [Mon, 3 May 2021 15:20:46 +0000 (16:20 +0100)] 
bpo-43754: Fix compiler warning in Python/compile.c (GH-25855)

This fixes the following warning:

'initializing': conversion from 'Py_ssize_t' to 'int', possible loss of data [D:\a\cpython\cpython\PCbuild\pythoncore.vcxproj]

4 years agobpo-43916: Move the _PyStructSequence_InitType function to the internal API (GH-25854)
Pablo Galindo [Mon, 3 May 2021 14:50:24 +0000 (15:50 +0100)] 
bpo-43916: Move the _PyStructSequence_InitType function to the internal API (GH-25854)

4 years agoDoc: Fix random.uniform example comment. (GH-25784)
Julien Palard [Mon, 3 May 2021 09:20:54 +0000 (11:20 +0200)] 
Doc: Fix random.uniform example comment. (GH-25784)

4 years agoIncrease test timeout (GH-25842)
Andrew Svetlov [Mon, 3 May 2021 09:06:17 +0000 (12:06 +0300)] 
Increase test timeout (GH-25842)

4 years agobpo-42725: Render annotations effectless on symbol table with PEP 563 (GH-25583)
Batuhan Taskaya [Mon, 3 May 2021 07:43:00 +0000 (10:43 +0300)] 
bpo-42725: Render annotations effectless on symbol table with PEP 563 (GH-25583)

4 years agobpo-44011: Fix asyncio tests without ssl module (GH-25840)
Christian Heimes [Mon, 3 May 2021 07:38:56 +0000 (09:38 +0200)] 
bpo-44011: Fix asyncio tests without ssl module (GH-25840)

Signed-off-by: Christian Heimes <christian@python.org>
4 years agobpo-44015: dataclasses should allow KW_ONLY to be specified only once per class ...
Eric V. Smith [Mon, 3 May 2021 07:24:53 +0000 (03:24 -0400)] 
bpo-44015: dataclasses should allow KW_ONLY to be specified only once per class (GH-25841)

bpo-44015: Raise a TypeError if KW_ONLY is specified more than once.

4 years agodataclasses docs: add a missing word. (GH-25839)
Eric V. Smith [Mon, 3 May 2021 06:33:34 +0000 (02:33 -0400)] 
dataclasses docs: add a missing word. (GH-25839)

4 years agoMore clarification of kw_only args. (GH-25838)
Eric V. Smith [Mon, 3 May 2021 05:55:13 +0000 (01:55 -0400)] 
More clarification of kw_only args. (GH-25838)

Also, clarify that the dataclass decorator is what raises an error for some mutable defaults.

4 years agoUpdate macOS installer welcome and readme for 3.10b1 (GH-25835)
Ned Deily [Mon, 3 May 2021 05:02:13 +0000 (01:02 -0400)] 
Update macOS installer welcome and readme for 3.10b1 (GH-25835)

4 years agobpo-42362: use clang name on 10.9 builds as well (GH-25834)
Ned Deily [Mon, 3 May 2021 04:23:54 +0000 (00:23 -0400)] 
bpo-42362: use clang name on 10.9 builds as well (GH-25834)

4 years agoFix invalid markup (#25833)
Raymond Hettinger [Mon, 3 May 2021 04:07:29 +0000 (21:07 -0700)] 
Fix invalid markup (#25833)

4 years agobpo-42235: [macOS] Use LTO/PGO in build-installer.py with new enough compilers (GH...
Ronald Oussoren [Mon, 3 May 2021 03:43:52 +0000 (05:43 +0200)] 
bpo-42235: [macOS] Use LTO/PGO in build-installer.py with new enough compilers (GH-23079)

With recent enough compilers we can build binaries with
LTO/PGO on macOS. This patch enables this when building on
macOS 10.15 or later (Xcode 11 or later).

4 years agobpo-25478: Add total() method to collections.Counter (GH-25829)
Raymond Hettinger [Mon, 3 May 2021 03:19:51 +0000 (20:19 -0700)] 
bpo-25478: Add total() method to collections.Counter (GH-25829)

4 years agobpo-41129: Fix check for macOS SDK paths when building Python (GH-25785)
Ned Batchelder [Mon, 3 May 2021 02:58:57 +0000 (19:58 -0700)] 
bpo-41129: Fix check for macOS SDK paths when building Python (GH-25785)

Narrow search to match contents of SDKs, namely only files in ``/System/Library``,
``/System/IOSSupport``, and ``/usr`` other than ``/usr/local``. Previously,
anything under ``/System`` was assumed to be in an SDK which causes problems
with the new file system layout in 10.15+ where user file systems may appear
to be mounted under ``/System``.  Paths in ``/Library`` were also
incorrectly treated as SDK locations.

Co-authored-by: Ned Deily <nad@python.org>
4 years agobpo-37903: IDLE: add shell sidebar mouse interactions (GH-25708)
Tal Einat [Mon, 3 May 2021 02:27:38 +0000 (05:27 +0300)] 
bpo-37903: IDLE: add shell sidebar mouse interactions (GH-25708)

Left click and drag to select lines.  With selection, right click for context menu with copy and copy-with-prompts.
Also add copy-with-prompts to the text-box context menu.

Co-authored-by: Terry Jan Reedy <tjreedy@udel.edu>
4 years agobpo-42362: Switch to clang/clang++ as the default compiler in build-installer.py...
Ronald Oussoren [Mon, 3 May 2021 01:29:03 +0000 (03:29 +0200)] 
bpo-42362: Switch to clang/clang++ as the default compiler in build-installer.py (GH-23298)

This change is cosmetic only, the "gcc" command in Apple's compiler tools is an alias for "clang" (and using non-system tooling for building the installer is not supported by this script).

Automerge-Triggered-By: GH:ned-deily
4 years agoMore work on documenting dataclass keyword-only fields. (GH-25828)
Eric V. Smith [Mon, 3 May 2021 01:20:50 +0000 (21:20 -0400)] 
More work on documenting dataclass keyword-only fields. (GH-25828)

4 years agobpo-43851: Build SQLite with SQLITE_OMIT_AUTOINIT on macOS (GH-25413)
Erlend Egeberg Aasland [Mon, 3 May 2021 00:37:35 +0000 (02:37 +0200)] 
bpo-43851: Build SQLite with SQLITE_OMIT_AUTOINIT on macOS (GH-25413)

4 years agobpo-43568: Drop support for MACOSX_DEPLOYMENT_TARGET < 10.3 (GH-25827)
Ned Deily [Mon, 3 May 2021 00:28:43 +0000 (20:28 -0400)] 
bpo-43568: Drop support for MACOSX_DEPLOYMENT_TARGET < 10.3 (GH-25827)

Only complain if the config target is >= 10.3 and the current target is
< 10.3. The check was originally added to ensure that incompatible
LDSHARED flags are not used, because -undefined dynamic_lookup is
used when building for 10.3 and later, and is not supported on older OS
versions. Apart from that, there should be no problem in general
with using an older target.

Authored-by: Joshua Root <jmr@macports.org>
4 years agobpo-43977: Make sure that tp_flags for pattern matching are inherited correctly....
Mark Shannon [Sun, 2 May 2021 23:38:22 +0000 (00:38 +0100)] 
bpo-43977: Make sure that tp_flags for pattern matching are inherited correctly. (GH-25813)

4 years agobpo-43977: Document the new pattern matching type flags (GH-25734)
Brandt Bucher [Sun, 2 May 2021 22:35:00 +0000 (15:35 -0700)] 
bpo-43977: Document the new pattern matching type flags (GH-25734)

4 years agobpo-43434: Clean up sqlite3.connect() after GH-25818 (GH-25823)
Erlend Egeberg Aasland [Sun, 2 May 2021 22:10:51 +0000 (00:10 +0200)] 
bpo-43434: Clean up sqlite3.connect() after GH-25818 (GH-25823)

4 years agobpo-44011: New asyncio ssl implementation (#17975)
Andrew Svetlov [Sun, 2 May 2021 21:34:15 +0000 (00:34 +0300)] 
bpo-44011: New asyncio ssl implementation (#17975)

4 years agobpo-43434: Move sqlite3.connect audit events to sqlite3.Connection.__init__ (GH-25818)
Erlend Egeberg Aasland [Sun, 2 May 2021 21:25:17 +0000 (23:25 +0200)] 
bpo-43434: Move sqlite3.connect audit events to sqlite3.Connection.__init__ (GH-25818)