Commit graph

11675 commits

Author SHA1 Message Date
Miss Islington (bot)
7b1be2ac81
gh-96130: Rephrase use of "typecheck" verb for clarity (GH-98144)
I'm sympathetic to the issue report, especially in case this helps
clarify to new users that Python itself does not do type checking at runtime
(cherry picked from commit ed6344eed0)

Co-authored-by: Shantanu <12621235+hauntsaninja@users.noreply.github.com>
2022-10-22 20:04:44 +01:00
Miss Islington (bot)
61e24f3abd
Formatting fixes in contextlib docs (GH-98111)
(cherry picked from commit 3b33c2010a)

Co-authored-by: Stanley <46876382+slateny@users.noreply.github.com>
2022-10-22 20:04:43 +01:00
Miss Islington (bot)
168ec080e8
gh-65046: Link to logging cookbook from asyncio docs (GH-98207)
(cherry picked from commit c39a0c3354)

Co-authored-by: Shantanu <12621235+hauntsaninja@users.noreply.github.com>
2022-10-22 20:04:42 +01:00
Miss Islington (bot)
3737a0e3ab
gh-91485: Doc: Using Python syntax to document builtin Python functions. (GH-96579)
(cherry picked from commit 3c4cbd177f)

Co-authored-by: Julien Palard <julien@palard.fr>
2022-10-22 20:04:39 +01:00
Miss Islington (bot)
be5de50166
Faster sieve() recipe (GH-98287)
(cherry picked from commit f4370318d6)

Co-authored-by: Raymond Hettinger <rhettinger@users.noreply.github.com>
2022-10-22 20:04:37 +01:00
Miss Islington (bot)
1a84816c30
docs(typing): harmonize "See PEP x for more details" (GH-97927)
(cherry picked from commit 02389658a4)

Co-authored-by: Simon Legner <Simon.Legner@gmail.com>
2022-10-22 20:04:36 +01:00
Miss Islington (bot)
a2820a0ec8
gh-85299: Add note warning about entry point guard for asyncio example (GH-93457)
(cherry picked from commit 79fd6ccdbe)

Co-authored-by: Stanley <46876382+slateny@users.noreply.github.com>
2022-10-22 20:04:34 +01:00
Miss Islington (bot)
335bd1ee8b
gh-94972: document that shield users need to keep a reference to their task (GH-96724)
Co-authored-by: Thomas Grainger <tagrain@gmail.com>
Co-authored-by: Guido van Rossum <gvanrossum@gmail.com>
(cherry picked from commit 6281affee6)

Co-authored-by: Hendrik Makait <hendrik.makait@gmail.com>
2022-09-10 08:03:35 -07:00
Miss Islington (bot)
ae819ca6fd
[3.11] gh-68163: Correct conversion of Rational instances to float (GH-25619) (#96556)
Co-authored-by: Mark Dickinson <dickinsm@gmail.com>
Co-authored-by: Sergey B Kirpichev <skirpichev@gmail.com>
2022-09-08 12:03:53 +01:00
Miss Islington (bot)
a3d5ecba1c
[3.11] gh-88287: Add BufferingFormatter documentation. (GH-96608) (GH-96675) 2022-09-08 08:30:48 +01:00
Irit Katriel
a5a9d0517b
[3.11] [doc] Update example in traceback doc (GH-96600) (GH-96603)
This Monty Python reference is of-its-time. It could seem inappropriate in the context of today's sensibilities around mental health.

Automerge-Triggered-By: GH:iritkatriel
(cherry picked from commit c4999f261f)

Co-authored-by: Irit Katriel <1055913+iritkatriel@users.noreply.github.com>
2022-09-05 22:43:27 +01:00
Miss Islington (bot)
d09069abfe
[3.11] gh-84095: Fill documentation gap regarding user-defined objects. (GH-96574) (GH-96575) 2022-09-05 08:03:49 +01:00
Miss Islington (bot)
0c81909a7a
Docs: alphabetically order sqlite3.Cursor attrs (GH-96565)
(cherry picked from commit 9e55685782)

Co-authored-by: Erlend E. Aasland <erlend.aasland@protonmail.com>
2022-09-04 14:43:23 -07:00
Miss Islington (bot)
4587154cb9
gh-95778: remove unneeded doc note on float.as_integer_ratio (GH-96553)
Per mdickinson@'s comment on the main branch PR.
(cherry picked from commit 69bb83c2bf)

Co-authored-by: Gregory P. Smith <greg@krypto.org>
2022-09-04 00:12:00 -07:00
Miss Islington (bot)
c0af099816
doc typo: spell limitation (GH-96542)
(cherry picked from commit af6359dd5c)

Co-authored-by: Mehrdad Moradizadeh <mhrddmoradii@gmail.com>
2022-09-03 23:32:32 -07:00
Miss Islington (bot)
79fe67fa04
[3.11] gh-89087: Update logging.QueueHandler documentation to clarify record… (GH-96527) (GH-96528) 2022-09-03 13:16:40 +01:00
Miss Islington (bot)
02c59bebf7
bpo-30419: DOC: Update missing information in bdb docs (GH-1687)
Co-authored-by: Jelle Zijlstra <jelle.zijlstra@gmail.com>
Co-authored-by: Martin Panter <vadmium@users.noreply.github.com>
Co-authored-by: Terry Jan Reedy <tjreedy@udel.edu>
(cherry picked from commit ccce9b77e1)

Co-authored-by: Cheryl Sabella <cheryl.sabella@gmail.com>
2022-09-02 10:48:26 -07:00
Gregory P. Smith
f8b71da9aa
[3.11] gh-95778: CVE-2020-10735: Prevent DoS by very large int() (#96500)
Integer to and from text conversions via CPython's bignum `int` type is not safe against denial of service attacks due to malicious input. Very large input strings with hundred thousands of digits can consume several CPU seconds.

This PR comes fresh from a pile of work done in our private PSRT security response team repo.

This backports https://github.com/python/cpython/pull/96499 aka 511ca94520

Signed-off-by: Christian Heimes [Red Hat] <christian@python.org>
Tons-of-polishing-up-by: Gregory P. Smith [Google] <greg@krypto.org>
Reviews via the private PSRT repo via many others (see the NEWS entry in the PR).

<!-- gh-issue-number: gh-95778 -->
* Issue: gh-95778
<!-- /gh-issue-number -->

I wrote up [a one pager for the release managers](https://docs.google.com/document/d/1KjuF_aXlzPUxTK4BMgezGJ2Pn7uevfX7g0_mvgHlL7Y/edit#).
2022-09-02 09:48:57 -07:00
Miss Islington (bot)
57116d5682
gh-95180: Add TaskGroup and Runner to AsyncIO API Index (GH-95189)
Also rearrange some items in the list.

Co-authored-by: Thomas Grainger <tagrain@gmail.com>
(cherry picked from commit 2a9e4e4d73)

Co-authored-by: siph <42943030+siphc@users.noreply.github.com>
2022-09-02 09:45:42 -07:00
Miss Islington (bot)
fca8e94dbf
gh-96168: Improve sqlite3 dict_factory example (GH-96457)
Co-authored-by: C.A.M. Gerlach <CAM.Gerlach@Gerlach.CAM>
Co-authored-by: Ezio Melotti <ezio.melotti@gmail.com>
(cherry picked from commit 91f40f3f78)

Co-authored-by: Erlend E. Aasland <erlend.aasland@innova.no>
2022-09-01 14:55:37 -07:00
Miss Islington (bot)
d4d5e605cd
gh-96414: Inline code examples in sqlite3 docs (GH-96442)
(cherry picked from commit f7e7bf161a)

Co-authored-by: Erlend E. Aasland <erlend.aasland@protonmail.com>
2022-08-30 23:03:33 -07:00
Miss Islington (bot)
895c7a4401
Docs: normalise sqlite3 placeholder how-to heading (GH-96413)
(cherry picked from commit 7b01ce7953)

Co-authored-by: Erlend E. Aasland <erlend.aasland@protonmail.com>
2022-08-30 14:06:11 -07:00
Miss Islington (bot)
d00a9e0176
gh-95337: update TypeVarTuple example (GH-95338)
Co-authored-by: Alex Waygood <Alex.Waygood@Gmail.com>
(cherry picked from commit 07f12b5c15)

Co-authored-by: Adrian Garcia Badaracco <1755071+adriangb@users.noreply.github.com>
2022-08-30 08:06:19 -07:00
Miss Islington (bot)
d9d0d097a2
Docs: Improve clarity for bytes.hex() (GH-95257)
(cherry picked from commit 860fa35145)

Co-authored-by: Tim Burke <tim.burke@gmail.com>
2022-08-30 04:18:30 -07:00
Miss Islington (bot)
8e2d347183
[3.11] gh-91305: Add a note about DatagramHandler and DNS latency. (GH-96380) (GH-96401) 2022-08-30 09:58:37 +01:00
Miss Islington (bot)
4cfb6395e1
Docs: normalize SQL style in sqlite3 docs (GH-96403)
(cherry picked from commit 6d403e264a)

Co-authored-by: Erlend E. Aasland <erlend.aasland@protonmail.com>
2022-08-29 15:59:13 -07:00
Miss Islington (bot)
2ba877258a
gh-95432: Add doctests for the sqlite3 docs (GH-96225)
As a consequence of the added test, this commit also includes
fixes for broken examples.

- Add separate namespace for trace tests bco. module level callback
- Move more backup and cursor examples under separate namespaces
(cherry picked from commit bf9259776d)

Co-authored-by: Erlend E. Aasland <erlend.aasland@protonmail.com>
2022-08-29 02:01:37 -07:00
Miss Islington (bot)
698df306a9
Docs: Fix count of bullets in asyncio-task.rst (GH-96307) (#96330)
(cherry picked from commit 35e4da25d4)

Co-authored-by: zhanpon <pon.zhan@gmail.com>

Co-authored-by: zhanpon <pon.zhan@gmail.com>
2022-08-27 14:26:42 +01:00
Miss Islington (bot)
315807dac9
gh-96197: Define the behavior of repr if sys.displayhook is lost (gh-96242)
(cherry picked from commit 0319cd6825)

Co-authored-by: Dong-hee Na <donghee.na@python.org>
2022-08-25 19:12:43 -07:00
Miss Islington (bot)
888054ae8a
[3.11] gh-91070: Add note about SysLogHandler on macOS 12.x (Monterey). (GH-94803) (GH-96260) 2022-08-25 08:38:02 +01:00
Miss Islington (bot)
d02e8fbc5a
GH-96179: Fix misleading example on the bisect documentation (GH-96228)
The `movies[bisect(movies, 1960, key=by_year)]` will actually return only movies **after** 1960.
(cherry picked from commit 4317b25a23)

Co-authored-by: prego <pedropregueiro@gmail.com>
2022-08-24 08:54:15 -07:00
Miss Islington (bot)
bf2728b9f1
gh-96197: Define the behavior of breakpoint if sys.breakpointhook is lost (gh-96231)
(cherry picked from commit 09563a764e)

Co-authored-by: Dong-hee Na <donghee.na@python.org>
2022-08-24 07:20:22 -07:00
Erlend E. Aasland
2b8fd74548
[3.11] gh-94635: Frame sqlite3 how-to headings as such & move default adapters to reference (GH-96136) (#96226)
Co-authored-by: Erlend E. Aasland <erlend.aasland@protonmail.com>
Co-authored-by: Ezio Melotti <ezio.melotti@gmail.com>.
(cherry picked from commit 6bda5b85b5)

Co-authored-by: C.A.M. Gerlach <CAM.Gerlach@Gerlach.CAM>
2022-08-24 09:51:46 +02:00
Miss Islington (bot)
dc6391705e
gh-96096: Add undocumented SQLITE_OK/DENY/IGNORE sqlite3 constants (GH-96134)
Co-authored-by: Erlend E. Aasland <erlend.aasland@protonmail.com>
Co-authored-by: Ezio Melotti <ezio.melotti@gmail.com>
(cherry picked from commit d6259c58cb)

Co-authored-by: C.A.M. Gerlach <CAM.Gerlach@Gerlach.CAM>
2022-08-22 23:58:35 -07:00
Miss Islington (bot)
88a559ffea
gh-95432: Add doctest for sqlite3 tutorial (GH-96193)
(cherry picked from commit 04c73e5efb)

Co-authored-by: Erlend E. Aasland <erlend.aasland@protonmail.com>
2022-08-22 23:55:35 -07:00
Miss Islington (bot)
98622fa00e
gh-96121: Merge sqlite3.Row examples into sqlite3.Row class doc (GH-96122)
Co-authored-by: Ezio Melotti <ezio.melotti@gmail.com>
Co-authored-by: C.A.M. Gerlach <CAM.Gerlach@Gerlach.CAM>
(cherry picked from commit 18b1782192)

Co-authored-by: Erlend E. Aasland <erlend.aasland@innova.no>
2022-08-22 01:12:02 -07:00
Miss Islington (bot)
58e1fe24c7
GH-95880: Clarify StringIO append/overwrite behavior. (GH-96104) (GH-96156) 2022-08-21 09:55:50 -05:00
Miss Islington (bot)
21c46f359b
Add polynomial_from_roots() to the itertools recipes (GH-96102) (#96155) 2022-08-21 09:47:45 -05:00
Miss Islington (bot)
b21ff7433e
gh-96098: Clearly link concurrent.futures from threading & multiprocessing docs (GH-96112)
Clearly link concurrent.futures from threading & multiprocessing docs

Also link directly to asyncio from the beginning of the threading docs.
(cherry picked from commit bcc4cb0c7d)

Co-authored-by: Nick Coghlan <ncoghlan@gmail.com>
2022-08-20 21:28:10 -07:00
Miss Islington (bot)
fcf04217ab
Docs: Fix markup of module name in sqlite3 docs (GH-96115)
(cherry picked from commit ee9f22d346)

Co-authored-by: Erlend E. Aasland <erlend.aasland@protonmail.com>
2022-08-19 01:26:08 -07:00
Miss Islington (bot)
f21d7e5150
Doc: Use consistent markup for example Point class in sqlite3 (GH-96095)
(cherry picked from commit 303ef0913e)

Co-authored-by: C.A.M. Gerlach <CAM.Gerlach@Gerlach.CAM>
2022-08-19 00:48:03 -07:00
Miss Islington (bot)
eed7711547
Docs: group sqlite3.Connection attributes and methods (GH-96090)
(cherry picked from commit 1a140af40b)

Co-authored-by: Erlend E. Aasland <erlend.aasland@protonmail.com>
2022-08-19 00:37:51 -07:00
Miss Islington (bot)
c097fe0f09
gh-94635: Remove sqlite3 doc introduction heading (GH-96089)
(cherry picked from commit ede771cdf9)

Co-authored-by: Erlend E. Aasland <erlend.aasland@protonmail.com>
2022-08-19 00:28:33 -07:00
Miss Islington (bot)
e8e3fe9931
Docs: Escape lone stars in sqlite3 docs (GH-96081)
(cherry picked from commit 91afe66707)

Co-authored-by: Erlend E. Aasland <erlend.aasland@protonmail.com>
2022-08-18 11:47:42 -07:00
Miss Islington (bot)
972150b8e3
gh-95271: Rework sqlite3 tutorial (GH-95749)
Co-authored-by: C.A.M. Gerlach <CAM.Gerlach@Gerlach.CAM>
Co-authored-by: Ezio Melotti <ezio.melotti@gmail.com>
(cherry picked from commit c87ea10fc9)

Co-authored-by: Erlend E. Aasland <erlend.aasland@protonmail.com>
2022-08-18 11:44:27 -07:00
Miss Islington (bot)
3ce1d0093e
Clarify asyncio.Runner docs re: loop_factory (GH-95979)
(cherry picked from commit e8259e047c)

Co-authored-by: Kumar Aditya <59607654+kumaraditya303@users.noreply.github.com>
2022-08-14 09:02:07 -07:00
Miss Islington (bot)
1fccb1d493
[3.11] gh-94439: typing docs: Add minimum version to __required_keys__ and __optional_keys__ (GH-95373) (#95944)
Co-authored-by: Howie Zhao <howiezhaohr@hotmail.com>
2022-08-13 19:42:27 +01:00
Miss Islington (bot)
7fdda1a47f
gh-82180: Document support for non-integer arg removed from grp.getgrgid in 3.10 (GH-95346) (GH-95929)
(cherry picked from commit 50bf5fafcc)

Co-authored-by: Hugo van Kemenade <hugovk@users.noreply.github.com>
2022-08-12 19:03:04 +02:00
Erlend E. Aasland
bd86e09ab9
[3.11] gh-95273: Improve sqlite3.complete_statement docs (GH-95840) (#95917)
Co-authored-by: Ezio Melotti <ezio.melotti@gmail.com>
Co-authored-by: CAM Gerlach <CAM.Gerlach@Gerlach.CAM>.
(cherry picked from commit e6623e7083)

Co-authored-by: Erlend E. Aasland <erlend.aasland@protonmail.com>
2022-08-12 09:34:26 +02:00
Miss Islington (bot)
209f2a7b45
gh-75510: Edit idlelib entry in doc (GH-95869)
Make section instead of subsection and revise sentence.
(cherry picked from commit 9af4aed73a)

Co-authored-by: Terry Jan Reedy <tjreedy@udel.edu>
2022-08-10 20:02:09 -07:00