Commit graph

108469 commits

Author SHA1 Message Date
Miss Islington (bot)
fbd9b9939c
bpo-44074: let patchcheck infer the base branch name (GH-25991)
(cherry picked from commit 21fbbb98ba)

Co-authored-by: Leonardo Lai <leonardo.lai@live.com>
2021-05-10 11:58:45 -07:00
Miss Islington (bot)
4d532d3f8f
bpo-43558: Add note about base class initialization to dataclasses doc (GH-25967) (GH-26019)
(cherry picked from commit 2a031723ee)

Co-authored-by: dhoekstra2000 <douwe.hoekstra2512@gmail.com>

Co-authored-by: dhoekstra2000 <douwe.hoekstra2512@gmail.com>
2021-05-10 09:38:01 -04:00
Miss Islington (bot)
20fcd83634
bpo-32924: Fix the Show Source url in the documentation (GH-25994)
(cherry picked from commit 03acfc50ac)

Co-authored-by: Pablo Galindo <Pablogsal@gmail.com>
2021-05-08 11:43:59 -07:00
Miss Islington (bot)
a25c46bd7d
Fix make libainstall. (GH-25980)
Initial patch by Benno Leslie.
(cherry picked from commit 80d250d68c)

Co-authored-by: Senthil Kumaran <senthil@uthcode.com>
2021-05-07 23:58:27 -07:00
Miss Islington (bot)
bf309d74a5
Simple Enhancement. Add missing return statements in ftplib documentation. (GH-25968) (#25970)
(cherry picked from commit b32c8e9795)

Co-authored-by: Senthil Kumaran <senthil@uthcode.com>

Co-authored-by: Senthil Kumaran <senthil@uthcode.com>
2021-05-07 07:13:19 -07:00
Miss Islington (bot)
7424105a02
Fix minor grammar problems in dataclasses documentation (GH-25948) (#25959)
Some missing words; some odd word choices.
(cherry picked from commit ee8e7c2fa9)

Co-authored-by: Scott Noyes <snoyes@gmail.com>

Co-authored-by: Scott Noyes <snoyes@gmail.com>
2021-05-06 17:54:58 -04:00
Miss Islington (bot)
1326f51bfc
docs: clearly document that ":GH-X" string formatting results in "0X..." (GH-25941)
* clearly document that ":GH-X" string formatting results in "0X..."

* put back the "serial comma"
(cherry picked from commit 92ceb1c840)

Co-authored-by: Tal Einat <532281+taleinat@users.noreply.github.com>
2021-05-06 12:52:50 -07:00
Miss Islington (bot)
b391b9b925
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>
(cherry picked from commit fb42725561)

Co-authored-by: Stephen Rosen <sirosen@globus.org>
2021-05-06 12:50:54 -07:00
Miss Islington (bot)
ce47addfb6
[3.9] bpo-36515: Disable unaligned memory access in _sha3 on ARM (GH-25927) (GH-25928)
Contributed-By: Matthias Klose

Automerge-Triggered-By: GH:tiran
(cherry picked from commit da5c808fb5)

Co-authored-by: Gregory P. Smith <greg@krypto.org>

Co-authored-by: Gregory P. Smith <greg@krypto.org>
2021-05-06 08:55:35 +02:00
Miss Islington (bot)
ea93270366
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>
(cherry picked from commit 47895e31b6)

Co-authored-by: Gen Xu <xgbarry@gmail.com>
2021-05-05 16:05:52 -07:00
Miss Islington (bot)
bc8b93c9a9
bpo-44040: Update broken link in pathlib source (GH-25905) (GH-25911)
(cherry picked from commit 96d5c7038b)

Co-authored-by: Kevin Follstad <kfollstad@gmail.com>
2021-05-05 10:53:54 +02:00
Miss Islington (bot)
df99532a05
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 a30f6d45ac. 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.
(cherry picked from commit 355bae8882)

Co-authored-by: karl ding <karlding@users.noreply.github.com>
2021-05-04 14:03:48 -07:00
Miss Islington (bot)
8faed45242
Clarify rx parameter of compileall functions (GH-25857)
(cherry picked from commit 09490298d4)

Co-authored-by: Jean-Abou-Samra <37271310+Jean-Abou-Samra@users.noreply.github.com>
2021-05-04 12:59:45 -07:00
Jelle Zijlstra
ab0a54adad
[3.9] bpo-44001: improve Literal documentation (GH-25877). (#25897)
(cherry picked from commit 87109f4d85)

Co-authored-by: Jelle Zijlstra <jelle.zijlstra@gmail.com>
2021-05-04 18:48:41 +02:00
Petr Viktorin
ec18362f6a
[3.9] bpo-42083: Allow NULL doc in PyStructSequence_NewType (#25896)
(cherry picked from commit 2f5baa1750)

Co-authored-by: Ken Jin <28750310+Fidget-Spinner@users.noreply.github.com>
2021-05-04 16:07:13 +02:00
Miss Islington (bot)
4b90c8f176
closes bpo-43349: Fix tuning(7) manpage hyperlink. (GH-24680) (#25694)
(cherry picked from commit f4d7d46cb4)

Co-authored-by: Erlend Egeberg Aasland <erlend.aasland@innova.no>
2021-05-04 15:48:24 +02:00
Miss Islington (bot)
c3bf0bd472
Fix typo in ast.py (GH-25740) (GH-25894)
parantheses -> parentheses
(cherry picked from commit 9ee8448243)

Co-authored-by: Ikko Ashimine <eltociear@gmail.com>

Co-authored-by: Ikko Ashimine <eltociear@gmail.com>
2021-05-04 06:39:08 -07:00
Miss Islington (bot)
91cb1e20e6
bpo-32822: Add finally with return/break/continue to the tutorial (GH-25600) (#25890)
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.
(cherry picked from commit a0b9915a8b)

Co-authored-by: Roberto Hueso <robertohueso96@gmail.com>
2021-05-04 15:17:21 +02:00
Miss Islington (bot)
00726e51ad
bpo-38352: Add to typing.__all__ (GH-25821) (#25885)
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>
(cherry picked from commit b115579734)
Co-authored-by: Jelle Zijlstra <jelle.zijlstra@gmail.com>
2021-05-04 12:02:49 +02:00
Miss Islington (bot)
7a92beea2c
bpo-43666: Lib/_aix_support.py routines may fail in a WPAR environment (GH-25095) (#25880)
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.
(cherry picked from commit 5017cde20e)

Co-authored-by: Michael Felt <aixtools@users.noreply.github.com>
2021-05-04 11:00:47 +02:00
Miss Islington (bot)
7ec94cdd1f
update docstring for win_getpass to reflect code changes (GH-24967)
The code was updated in
0ec88b33d0
but the docstring was left untouched.

=> updated the docstring to reflect the code changes
(cherry picked from commit d4222ea6b0)

Co-authored-by: Jürgen Gmach <juergen.gmach@googlemail.com>
2021-05-04 00:10:32 -07:00
Miss Islington (bot)
e733e9951d
bpo-44018: random.seed() no longer mutates its inputs (GH-25856) (GH-25864) 2021-05-03 16:36:14 -07:00
Senthil Kumaran
8a595744e6
[3.9] bpo-43882 Remove the newline, and tab early. From query and fragments. (#25853)
* Remove the newline, and tab early. From query and fragments.
2021-05-03 12:08:59 -07:00
Łukasz Langa
bf124244f0
Post 3.9.5 2021-05-03 20:26:51 +02:00
Łukasz Langa
0a7dcbdb13
Python 3.9.5 2021-05-03 16:54:42 +02:00
Steve Dower
bb2f3ff7a8
bpo-42800: Add audit events for f_code and tb_frame (GH-24182)
Accessing the following attributes will now fire PEP 578 style audit hooks as (object.__getattr__, obj, name):
* PyTracebackObject: tb_frame
* PyFrameObject: f_code
* PyGenObject: gi_code, gi_frame
* PyCoroObject: cr_code, cr_frame
* PyAsyncGenObject: ag_code, ag_frame
2021-05-03 14:06:36 +01:00
Miss Islington (bot)
1536342c44
[3.9] Doc: Fix random.uniform example comment. (GH-25784) (GH-25843)
(cherry picked from commit 440c025726)


Co-authored-by: Julien Palard <julien@palard.fr>

Automerge-Triggered-By: GH:JulienPalard
2021-05-03 05:43:04 -07:00
Ned Deily
7f7dc67354
[3.9] Update macOS installer readme for 3.9.5 (GH-25836) 2021-05-03 01:49:27 -04:00
Miss Islington (bot)
98035ec93f
bpo-41129: Fix check for macOS SDK paths when building Python (GH-25785) (GH-25830)
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>
(cherry picked from commit d52bbde942)

Co-authored-by: Ned Batchelder <ned@nedbatchelder.com>
2021-05-02 23:38:49 -04:00
Erlend Egeberg Aasland
ad73d1657c
bpo-43434: Move sqlite3.connect audit event to sqlite3.Connection.__init__ (GH-25818) 2021-05-02 23:43:06 +01:00
Miss Islington (bot)
e60b1e150d
bpo-43990: Fix the footnote ordering in the operator precedence docs (GH-25805) (GH-25819) 2021-05-02 13:14:30 -07:00
Miss Islington (bot)
5374fbc314
bpo-36384: Leading zeros in IPv4 addresses are no longer tolerated (GH-25099) (GH-25815)
Reverts commit e653d4d8e8 and makes
parsing even more strict. Like socket.inet_pton() any leading zero
is now treated as invalid input.

Signed-off-by: Christian Heimes <christian@python.org>

Co-authored-by: Łukasz Langa <lukasz@langa.pl>
(cherry picked from commit 60ce8f0be6)
2021-05-02 15:49:03 +02:00
Miss Islington (bot)
cf6a79644c
bpo-32745: Fix a regression in the handling of ctypes' c_wchar_p type (GH-8721) (#25812)
Embedded nulls would cause a ValueError to be raised. Thanks go to Eryk Sun for their analysis.

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

Co-authored-by: Zackery Spytz <zspytz@gmail.com>
2021-05-02 13:03:10 +02:00
Miss Islington (bot)
bb3ec9ceae
bpo-41100: Update Misc/ACKS (GH-25808) (GH-25809)
(cherry picked from commit 518f8b5dd5)

Co-authored-by: Ned Deily <nad@python.org>
2021-05-02 05:25:38 -04:00
Miss Islington (bot)
de0e3f8c16
[3.9] bpo-44009: Provide "python3.x-intel64" for Apple Silicon Macs (GH-25804) (GH-25807)
This allows reliably forcing macOS universal2 framework builds
to run under Rosetta 2 Intel-64 emulation on Apple Silicon Macs
if needed for testing or when universal2 wheels are not yet
available.
(cherry picked from commit 0cb33da1cc)


Co-authored-by: Ned Deily <nad@python.org>

Automerge-Triggered-By: GH:ned-deily
2021-05-02 02:10:21 -07:00
Miss Islington (bot)
ee0df3dee4
Fix broken name in build.yml (GH-25759) (GH-25802)
(cherry picked from commit 29282b2825)
2021-05-01 19:56:56 -07:00
Miss Islington (bot)
10a62bbecc
Fix exceptions mentioned in os.setxattr() docs (GH-25742) (GH-25794)
(cherry picked from commit 779232413a)

Co-authored-by: Shreyash Sharma <shreyash.sharma@philips.com>

Co-authored-by: Shreyash Sharma <shreyash.sharma@philips.com>
2021-05-01 16:56:05 -04:00
Miss Islington (bot)
5c018db467
Fixing doc for callback for lambda (GG-25779) (GH-25788)
Fixing callback for lambda when no return value is provided
(cherry picked from commit 50c21ad353)

Co-authored-by: Shreyash Sharma <shreyash.sharma@philips.com>

Co-authored-by: Shreyash Sharma <shreyash.sharma@philips.com>
2021-05-01 15:55:46 -04:00
Stéphane Bidoul
af1e06c62f
[3.9] bpo-43993: Update vendored pip to 21.1.1 (GH-25761). (GH-25782) 2021-05-01 16:49:34 +01:00
Miss Islington (bot)
e48405a9be
bpo-43971: Add spaces around annotated arg default '=' (GH-25702)
Result: "quantity_on_hand: int = 0".
(cherry picked from commit e726a902b7)

Co-authored-by: Mohamed Moselhy <look4d@gmail.com>

Co-authored-by: Mohamed Moselhy <look4d@gmail.com>
2021-04-30 20:30:38 -04:00
Miss Islington (bot)
a7f15ba547
bpo-43935: Fix typo in Turtle.back() docstring (GH-25581)
'e ,' to 'e, '.
(cherry picked from commit 0048c60f01)

Co-authored-by: Tarjei Bærland <tarjeibaerland@gmail.com>
2021-04-30 15:27:48 -07:00
Miss Islington (bot)
a92d738763
bpo-43954: Fix a missing word in the unittest docs (GH-25672)
(cherry picked from commit 2abbd8f2ad)

Co-authored-by: Zackery Spytz <zspytz@gmail.com>
2021-04-30 00:56:56 -07:00
Miss Islington (bot)
3eaa6f9d18
bpo-42589: Change URL for 'from' link when used in a raised exception (GH-23872)
Links for 'raise Exception from x' target to 'The raise statement' (7.8) section instead of 'The import statement' (7.11) section.

There are more modified links than in the bug report because I searched some other ones which can get the same improvement.
(cherry picked from commit 2fd928c8c1)

Co-authored-by: sblondon <sblondon@users.noreply.github.com>
2021-04-29 11:26:26 -07:00
Miss Islington (bot)
491fde0161
[3.9] bpo-43882 - urllib.parse should sanitize urls containing ASCII newline and tabs. (GH-25595) (GH-25725)
* bpo-43882 - urllib.parse should sanitize urls containing ASCII newline and tabs. (GH-25595)

Co-authored-by: Gregory P. Smith <greg@krypto.org>
Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
(cherry picked from commit 76cd81d603)
Co-authored-by: Senthil Kumaran <skumaran@gatech.edu>
2021-04-29 10:57:31 -07:00
Miss Islington (bot)
8d47f92d46
[doc] Be more clear on super() regarding multiple base classes methods (GH-21789) (GH-25706)
(cherry picked from commit 69a733bda3)

Co-authored-by: Andre Delfino <adelfino@gmail.com>

Co-authored-by: Andre Delfino <adelfino@gmail.com>
2021-04-28 18:13:12 -07:00
Miss Islington (bot)
c4e503ed80
[doc] Do some polishing in IDEs section (GH-22070) (GH-25703)
(cherry picked from commit 08a4803863)

Co-authored-by: Andre Delfino <adelfino@gmail.com>

Co-authored-by: Andre Delfino <adelfino@gmail.com>
2021-04-28 18:09:03 -07:00
Miss Islington (bot)
0252ce3571
bpo-43472: Ensure PyInterpreterState_New audit events are raised when called through _xxsubinterpreters module (GH-25506) (GH-25508)
(cherry picked from commit 7b86e47617)

Co-authored-by: Steve Dower <steve.dower@python.org>

Co-authored-by: Steve Dower <steve.dower@python.org>
2021-04-28 18:20:40 +02:00
Miss Islington (bot)
629ef0fb9c
bpo-43961: Fix test_logging.test_namer_rotator_inheritance() (GH-25684) (GH-25688)
Fix test_logging.test_namer_rotator_inheritance() on Windows: use
os.replace() rather than os.rename().
(cherry picked from commit fe52eb6219)

Co-authored-by: Victor Stinner <vstinner@python.org>

Co-authored-by: Victor Stinner <vstinner@python.org>
2021-04-28 17:28:15 +02:00
Irit Katriel
2dc6b1789e
bpo-43960: test_pdb resets breakpoints to make tests deterministic (GH-25691) 2021-04-28 17:21:11 +02:00
Miss Islington (bot)
fdb11897d7
bpo-43959: clarify the documentation of the PyContextVar C-API (GH-25671) (GH-25689)
(cherry picked from commit 4c49be7668)
2021-04-28 17:11:15 +02:00