Commit graph

114573 commits

Author SHA1 Message Date
Miss Islington (bot)
3db036888c
gh-95913: Fix PEP number in PEP 678 What's New ref label (GH-97739)
What's New: Fix PEP number in PEP 678 ref target label
(cherry picked from commit e738b5190b)

Co-authored-by: C.A.M. Gerlach <CAM.Gerlach@Gerlach.CAM>
2022-10-02 21:21:46 -07:00
Miss Islington (bot)
2049c9db15
gh-95913: Copyedit/improve New Modules What's New section (GH-97721)
* Link TOML & WSGI in New Modules section, refine text & add ref label

* Further reformat new modules & add PEP link to tomllib
(cherry picked from commit bd00112a99)

Co-authored-by: C.A.M. Gerlach <CAM.Gerlach@Gerlach.CAM>
2022-10-02 21:11:05 -07:00
Miss Islington (bot)
827f77e5f1
gh-97740: Fix bang in Sphinx C domain ref target syntax (GH-97741)
* gh-97740: Fix bang in Sphinx C domain ref target syntax

Co-authored-by: Adam Turner <9087854+AA-Turner@users.noreply.github.com>

* Add NEWS entry for C domain bang fix

Co-authored-by: Adam Turner <9087854+AA-Turner@users.noreply.github.com>
(cherry picked from commit 9148c0d893)

Co-authored-by: C.A.M. Gerlach <CAM.Gerlach@Gerlach.CAM>
2022-10-02 21:02:46 -07:00
Miss Islington (bot)
f59506780a
gh-96819: multiprocessing.resource_tracker: check if length of pipe write <= 512 (GH-96890)
Co-authored-by: Kumar Aditya <59607654+kumaraditya303@users.noreply.github.com>
(cherry picked from commit 19ca114645)

Co-authored-by: Koki Saito <49419225+saito828koki@users.noreply.github.com>
2022-10-02 18:09:58 -07:00
Miss Islington (bot)
b26fb3cdc6
GH-85447: Clarify docs about awaiting future multiple times (GH-97738)
(cherry picked from commit 9151bbefea)

Co-authored-by: Kumar Aditya <59607654+kumaraditya303@users.noreply.github.com>
2022-10-02 15:27:17 -07:00
Miss Islington (bot)
011260bca0
[3.11] [docs] Update logging cookbook with recipe for using a logger like an output… (GH-97730) (GH-97735) 2022-10-02 17:44:42 +01:00
Miss Islington (bot)
8c528ef4a1
gh-97607: Fix content parsing in the impl-detail reST directive (GH-97652)
* Don't parse content as arg in the impl-detail directive

This does not change the (untranslated) output,
but ensures that the doctree node metadata is correct.
which fixes gh-97607 with the text not being translated.
It also simplifies the code and logic
and makes it consistant with the docutils built-in directives.

* Remove unused branch from impl-detail directive handling no-content case

This is not used anywhere in the docs and lacks a clear use case,
and is more likely a mistake which is now flagged at build time.
This simplifies the logic from two code paths to one,
and makes the behavior consistant with similar built-in directives
(e.g. the various admonition types).

* Further simplify impl-detail reST directive code
(cherry picked from commit e8165d47b8)

Co-authored-by: C.A.M. Gerlach <CAM.Gerlach@Gerlach.CAM>
2022-10-01 22:28:54 -07:00
Miss Islington (bot)
1fa848ac39
gh-95975: Move except/*/finally ref labels to more precise locations (GH-95976)
* gh-95975: Move except/*/finally ref labels to more precise locations

* Add section headers to fix :keyword: role and aid navigation

* Move see also to the introduction rather than a particular subsection

* Fix other minor Sphinx syntax issues with except

Co-authored-by: Ezio Melotti <ezio.melotti@gmail.com>

* Suppress redundant link to same section for except too

* Don't link try/except/else/finally keywords if in the same section

* Format try/except/finally as keywords in modified sections

Co-authored-by: Ezio Melotti <ezio.melotti@gmail.com>
(cherry picked from commit dcc82331c8)

Co-authored-by: C.A.M. Gerlach <CAM.Gerlach@Gerlach.CAM>
2022-10-01 22:20:43 -07:00
Miss Islington (bot)
dbde686a49
gh-97591: In Exception.__setstate__() acquire strong references before calling tp_hash slot (GH-97700)
(cherry picked from commit d639438609)

Co-authored-by: Ofey Chan <ofey206@gmail.com>
2022-10-01 21:19:57 -07:00
Miss Islington (bot)
9189cd6b05
gh-95588: Drop the safety claim from ast.literal_eval docs. (GH-95919)
It was never really safe and this claim conflicts directly with the big warning in the docs about it being able to crash the interpreter.
(cherry picked from commit 8baef8ae36)

Co-authored-by: Gregory P. Smith <greg@krypto.org>
2022-10-01 18:21:15 -07:00
Miss Islington (bot)
35a394c556
Fix capitalization of Unix in documentation (GH-96913)
(cherry picked from commit bd7d0e875e)

Co-authored-by: Will Hawkins <8715530+hawkinsw@users.noreply.github.com>
2022-10-01 16:51:34 -07:00
Miss Islington (bot)
3614bbb8eb
gh-90908: Document asyncio.Task.cancelling() and asyncio.Task.uncancel() (GH-95253)
Co-authored-by: Thomas Grainger <tagrain@gmail.com>
(cherry picked from commit f00645d5db)

Co-authored-by: Łukasz Langa <lukasz@langa.pl>
2022-10-01 11:10:04 -07:00
Miss Islington (bot)
95609525de
GH-96827: Don't touch closed loops from executor threads (GH-96837)
* When chaining futures, skip callback if loop closed.
* When shutting down an executor, don't wake a closed loop.
(cherry picked from commit e9d63760fe)

Co-authored-by: Guido van Rossum <guido@python.org>
2022-09-30 13:23:33 -07:00
Miss Islington (bot)
3124618fd5
GH-97592: Fix crash in C remove_done_callback due to evil code (GH-97660)
Evil code could cause fut_callbacks to be cleared when PyObject_RichCompareBool is called.
(cherry picked from commit 63780f4599)

Co-authored-by: Guido van Rossum <guido@python.org>
2022-09-30 13:22:48 -07:00
Miss Islington (bot)
cdc01eaed9
gh-87597: Document TimeoutExpired.stdout & .stderr types (GH-97685)
This documents the behavior that has always been the case since timeout
support was introduced in Python 3.3.
(cherry picked from commit b05dd79649)

Co-authored-by: Gregory P. Smith <greg@krypto.org>
2022-09-30 10:54:12 -07:00
Miss Islington (bot)
ab2f1a6152
bpo-35675: IDLE - separate config_key window and frame (GH-11427)
bpo-35598: IDLE: Refactor window and frame class

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

Co-authored-by: Cheryl Sabella <cheryl.sabella@gmail.com>
2022-09-30 10:08:36 -07:00
Miss Islington (bot)
6537bc9a49
gh-94526: getpath_dirname() no longer encodes the path (GH-97645)
Fix the Python path configuration used to initialized sys.path at
Python startup. Paths are no longer encoded to UTF-8/strict to avoid
encoding errors if it contains surrogate characters (bytes paths are
decoded with the surrogateescape error handler).

getpath_basename() and getpath_dirname() functions no longer encode
the path to UTF-8/strict, but work directly on Unicode strings. These
functions now use PyUnicode_FindChar() and PyUnicode_Substring() on
the Unicode path, rather than strrchr() on the encoded bytes string.
(cherry picked from commit 9f2f1dd131)

Co-authored-by: Victor Stinner <vstinner@python.org>
2022-09-30 06:38:41 -07:00
Steve Dower
0fbee30f71
gh-90989: Clarify some installer text (GH-97668) 2022-09-30 13:48:19 +01:00
Miss Islington (bot)
1a620c579d
[3.11] Use SyntaxError invalid range in tutorial introduction example (GH-93031) (GH-97666)
Use SyntaxError invalid range in tutorial introduction example (GH-93031)

Use output from a 3.10+ REPL, showing invalid range, for the
SyntaxError examples in the tutorial introduction page.

Co-authored-by: Eddie Hebert <eddie@eddiehebert.com>
2022-09-30 10:12:22 +01:00
Miss Islington (bot)
27891e0d7b
gh-96397: Document that attributes need not be identifiers (GH-96454)
Co-authored-by: C.A.M. Gerlach <CAM.Gerlach@Gerlach.CAM>
(cherry picked from commit 9a11ed8e50)

Co-authored-by: Jeff Allen <ja.py@farowl.co.uk>
2022-09-29 16:25:10 -07:00
Miss Islington (bot)
bad137bd93
closes gh-97650: correct sphinx executable (gh-97651)
(cherry picked from commit 0179a82caa)

Co-authored-by: NoSuck <NoSuck@users.noreply.github.com>
2022-09-29 16:00:33 -07:00
Miss Islington (bot)
11b66717fe
gh-52597: Add position-only markers for os functions (GH-94735)
(cherry picked from commit c759944f16)

Co-authored-by: Stanley <46876382+slateny@users.noreply.github.com>
2022-09-29 06:51:39 -07:00
Miss Islington (bot)
9cf41f4a7a
gh-91212: Fixed flickering when the tracer is turned off (GH-95129)
Fixed flickering when the tracer is turned off.
(cherry picked from commit 4652093e1b)

Co-authored-by: Shin-myoung-serp <relent95@naver.com>
2022-09-29 00:07:07 -07:00
Miss Islington (bot)
f418842a5c
[3.11] gh-96357: Improve typing.get_overloads coverage (GH-96358) (#96371)
gh-96357: Improve `typing.get_overloads` coverage (GH-96358)
(cherry picked from commit 675e3470cc)

Co-authored-by: Nikita Sobolev <mail@sobolevn.me>
2022-09-28 18:06:21 -07:00
Miss Islington (bot)
94582bb643
gh-97612: Fix shell injection in get-remote-certificate.py (GH-97613)
Fix a shell code injection vulnerability in the
get-remote-certificate.py example script. The script no longer uses a
shell to run "openssl" commands. Issue reported and initial fix by
Caleb Shortt.

Remove the Windows code path to send "quit" on stdin to the "openssl
s_client" command: use DEVNULL on all platforms instead.

Co-authored-by: Caleb Shortt <caleb@rgauge.com>
(cherry picked from commit 83a0f44ffd)

Co-authored-by: Victor Stinner <vstinner@python.org>
2022-09-28 16:46:11 -07:00
Miss Islington (bot)
7d60d10b63
gh-97616: list_resize() checks for integer overflow (GH-97617)
Fix multiplying a list by an integer (list *= int): detect the
integer overflow when the new allocated length is close to the
maximum size.  Issue reported by Jordan Limor.

list_resize() now checks for integer overflow before multiplying the
new allocated length by the list item size (sizeof(PyObject*)).
(cherry picked from commit a5f092f3c4)

Co-authored-by: Victor Stinner <vstinner@python.org>
2022-09-28 15:28:38 -07:00
Miss Islington (bot)
744087474b
Fix typo in error message in plistlib (GH-97540)
(cherry picked from commit 81b9d9ddc2)

Co-authored-by: Jakob Weigert <jakobjw@users.noreply.github.com>
2022-09-28 11:23:56 -07:00
Miss Islington (bot)
b8bc11e501
fixup policy docs (GH-97618)
(cherry picked from commit 9a404b173e)

Co-authored-by: Kumar Aditya <59607654+kumaraditya303@users.noreply.github.com>
2022-09-28 10:42:28 -07:00
Miss Islington (bot)
88ab19e47e
Fix docs on conditional expression grouping (GH-96447) (GH-97606) 2022-09-28 08:45:48 -05:00
Miss Islington (bot)
73557d5bd2
[3.11] gh-65046: Add note about logging from async code. (GH-97602) (GH-97608) 2022-09-28 05:32:01 +01:00
Miss Islington (bot)
c2ec6da74f
gh-96377: Update asyncio policy doc intro paras to be clear and accurate (GH-97603)
Also fix up some cross-references in the asyncio docs.
(cherry picked from commit cc0f3a10f0)

Co-authored-by: C.A.M. Gerlach <CAM.Gerlach@Gerlach.CAM>
2022-09-27 17:33:32 -07:00
Miss Islington (bot)
f391b3c6ab
gh-96478: Fix new test when run in refleak mode (GH-96615)
./python.exe -m test -R : test.test_typing would fail, apparently
because the dictionary used in the @patch decorator was modified.
(cherry picked from commit f0d9136c69)

Co-authored-by: Jelle Zijlstra <jelle.zijlstra@gmail.com>
2022-09-27 07:50:36 -07:00
Miss Islington (bot)
04aa15f5e7
gh-73588: Fix generation of the default name of tkinter.Checkbutton. (GH-97547)
Previously, checkbuttons in different parent widgets could have the same
short name and share the same state if arguments "name" and "variable" are
not specified. Now they are globally unique.
(cherry picked from commit adbed2d542)

Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
2022-09-27 04:34:24 -07:00
Miss Islington (bot)
dfe23ee20f
gh-96959: Update more HTTP links (GH-97536)
Use HTTPS for documents which are available by both HTTP and HTTPS
links, but there is no redirection from HTTP to HTTPS or vice versa.
(cherry picked from commit dd53b79de0)

Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
2022-09-27 04:16:37 -07:00
Miss Islington (bot)
9a9bf88898
gh-97545: Make Semaphore run faster. (GH-97549)
(cherry picked from commit 68c46ae68b)

Co-authored-by: Cyker Way <cykerway@gmail.com>
2022-09-26 17:00:53 -07:00
Miss Islington (bot)
82932b3ec9
GH-65046: Fix docs about logging in asyncio (GH-97559)
Explain that logging should not use network I/O.
(cherry picked from commit d68c37c0d0)

Co-authored-by: Kumar Aditya <59607654+kumaraditya303@users.noreply.github.com>
2022-09-26 15:45:58 -07:00
Miss Islington (bot)
a4ff0eaaf0
gh-96848: Fix -X int_max_str_digits option parsing (GH-96988)
Fix command line parsing: reject "-X int_max_str_digits" option with
no value (invalid) when the PYTHONINTMAXSTRDIGITS environment
variable is set to a valid limit.
(cherry picked from commit 41351662bc)

Co-authored-by: Victor Stinner <vstinner@python.org>
2022-09-26 08:43:26 -07:00
Miss Islington (bot)
cf61fa278e
gh-82530: Create blank function instead of invalid import for email example (GH-97529)
Co-authored-by: Terry Jan Reedy <tjreedy@udel.edu>
(cherry picked from commit 2b428a1fae)

Co-authored-by: Stanley <46876382+slateny@users.noreply.github.com>
2022-09-25 21:15:52 -07:00
Miss Islington (bot)
54bb8f9af4
gh-97519: Synchronize links in other copies of HISTORY OF THE SOFTWARE (GH-97520)
HTTP links in the "HISTORY OF THE SOFTWARE" section of Doc/license.rst
were converted to HTTPS in f62ff97f31.
But there were other copies of these links, which were left HTTP links.
(cherry picked from commit ea4be278fa)

Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
2022-09-25 02:02:09 -07:00
Miss Islington (bot)
6daff06fc2
gh-94808: Coverage: Test uppercase string literal prefixes (GH-95925)
(cherry picked from commit f00383ec9b)

Co-authored-by: Michael Droettboom <mdboom@gmail.com>
2022-09-25 01:21:58 -07:00
Miss Islington (bot)
a386d1341c
gh-96052: codeop: fix handling compiler warnings in incomplete input (GH-96132)
Previously codeop.compile_command() emitted compiler warnings (SyntaxWarning or
DeprecationWarning) and raised a SyntaxError for incomplete input containing
a potentially incorrect code. Now it always returns None for incomplete input
without emitting any warnings.
(cherry picked from commit 426d72e7dd)

Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
2022-09-25 01:21:00 -07:00
Miss Islington (bot)
4d1de87042
gh-96959: Update HTTP links which are redirected to HTTPS (GH-96961)
(cherry picked from commit db39050396)

Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
2022-09-25 01:20:45 -07:00
Miss Islington (bot)
fe8db634d4
gh-97527: IDLE: protect macosx Tk() call when no GUI (GH-97530)
Only call tkinter.tk and its follow-up code in _init_tk_type when requires('gui')
does not raise.  This function can be called as an unintended side-effect of
calling other idlelib code as part of tests on macOS without a GUI enabled.
(cherry picked from commit 9704f8da33)

Co-authored-by: Terry Jan Reedy <tjreedy@udel.edu>
2022-09-24 15:09:08 -07:00
Miss Islington (bot)
c2916d2f0e
gh-96965: Update Windows release to libffi 3.4.3 (GH-97512)
(cherry picked from commit f1cca801f5)

Co-authored-by: Steve Dower <steve.dower@python.org>
2022-09-23 08:31:53 -07:00
Miss Islington (bot)
512b305856
gh-94781: Fix Windows projects not cleaning intermediate and output files for frozen modules (GH-96423)
(cherry picked from commit 3e26de3c1f)

Co-authored-by: Charlie Zhao <zhaoyu_hit@qq.com>
2022-09-23 16:23:41 +01:00
Steve Dower
dc9065f8c2
gh-77171: Document that wave only supports simple PCM files (GH-97510) 2022-09-23 13:55:06 +01:00
Miss Islington (bot)
c29d9b599f
gh-75608: Add Windows FAQ entry for missing UCRT (GH-92765)
(cherry picked from commit 80bc7d7c0a)

Co-authored-by: Stanley <46876382+slateny@users.noreply.github.com>
2022-09-23 03:54:53 -07:00
Miss Islington (bot)
29f17a4ad8
gh-96761: Fix build process of the clang compiler for _bootstrap_python (gh-96945)
Co-authored-by: Matthias Goergens <matthias.goergens@gmail.com>
(cherry picked from commit 83d84e67cd)

Co-authored-by: Dong-hee Na <donghee.na@python.org>
2022-09-22 20:20:50 -07:00
Miss Islington (bot)
9eb1e6c692
gh-96397: Document that keywords in calls need not be identifiers (GH-96393)
This represents the official SC stance, see
https://github.com/python/steering-council/issues/142GH-issuecomment-1252172695
(cherry picked from commit 9d432b4a18)

Co-authored-by: Jeff Allen <ja.py@farowl.co.uk>
2022-09-22 11:18:02 -07:00
Miss Islington (bot)
6642d8a0f9
GH-85760: Fix race in calling process_exited callback too early (GH-97009)
(cherry picked from commit 282edd7b2a)

Co-authored-by: Kumar Aditya <59607654+kumaraditya303@users.noreply.github.com>
2022-09-22 10:24:54 -07:00