Commit graph

24037 commits

Author SHA1 Message Date
Miss Islington (bot)
35ce2b771b
Add redirects to Misc/NEWS bpo links (GH-91454) (GH-91536)
(cherry picked from commit 17dbb6bc10)

Co-authored-by: Ezio Melotti <ezio.melotti@gmail.com>
2022-04-14 17:01:15 +02:00
Miss Islington (bot)
f3f5d4be7a
gh-90879: Fix missing parameter for put_nowait() (GH-91514)
(cherry picked from commit 0fc3517cf4)

Co-authored-by: slateny <46876382+slateny@users.noreply.github.com>
2022-04-14 02:23:15 -07:00
Miss Islington (bot)
0ab5e83ff7
gh-87497: Document that urllib.request sends headers in camel case (GH-24661)
Co-authored-by: Jelle Zijlstra <jelle.zijlstra@gmail.com>
(cherry picked from commit 325d6f5035)

Co-authored-by: Alix Lourme <alix.lourme@gmail.com>
2022-04-13 19:45:56 -07:00
Miss Islington (bot)
a8d245a675
gh-88513: clarify shutil.copytree's dirs_exist_ok arg (GH-91434) (GH-91465)
* add a paragraph to document this kwarg in detail
* update docstring in the source accordingly
(cherry picked from commit f33e2c87a8)

Co-authored-by: Jack DeVries <jdevries3133@gmail.com>
2022-04-12 19:58:02 -07:00
Miss Islington (bot)
8cd0f27492
pickle docs: Fix typos and improve wording (GH-24776) (GH-32396)
Co-authored-by: Jelle Zijlstra <jelle.zijlstra@gmail.com>
(cherry picked from commit 1d0f08fa46)

Co-authored-by: Géry Ogam <gery.ogam@gmail.com>
2022-04-07 18:56:29 -07:00
Miss Islington (bot)
8b358d4147
ssl docs: Fix typo (GH-32336)
(cherry picked from commit 9ee2d3a939)

Co-authored-by: Frederick <fmoor@users.noreply.github.com>
2022-04-07 10:06:54 -07:00
Miss Islington (bot)
b124a3913d
c-api docs: There are five fields, not four (GH-32379)
(cherry picked from commit 4c92427fb8)

Co-authored-by: Jelle Zijlstra <jelle.zijlstra@gmail.com>
2022-04-07 07:32:09 -07:00
Miss Islington (bot)
85f0792b8f
doc: Link to string.capwords from str.title (GH-20913)
Since `title()` mentions its own short-comings, it should also mention the library function which does not possess them.

Co-authored-by: Jelle Zijlstra <jelle.zijlstra@gmail.com>
(cherry picked from commit b786d9ec52)

Co-authored-by: Eric Wieser <wieser.eric@gmail.com>
2022-04-06 18:57:38 -07:00
Miss Islington (bot)
ea6dc5ec08
pkgutil docs: Link sys constants, add backticks (GH-32356)
Co-authored-by: Éric <merwok@netwok.org>
(cherry picked from commit 63bd72448a)

Co-authored-by: Boris Verkhovskiy <boris.verk@gmail.com>
2022-04-06 18:18:56 -07:00
Miss Islington (bot)
30dfc46be4
ssl docs: Fix typo (GH-32314)
(cherry picked from commit 1da9c38fd3)

Co-authored-by: Frederick <fmoor@users.noreply.github.com>
2022-04-06 18:16:53 -07:00
Ken Jin
d6a7ee69fb
[3.9] bpo-46769: Fix backticks in typing.rst to appease rstlint (GH-32375)
* Use double backticks to appease rstlint

* Update susp-ignored.csv
2022-04-07 02:03:11 +08:00
Miss Islington (bot)
b5b3b9151c
stdtypes docs: fix typo (GH-32349)
(cherry picked from commit b33c4564ac)

Co-authored-by: Ian <40774387+isteptoe@users.noreply.github.com>
2022-04-06 09:04:38 -07:00
Miss Islington (bot)
770780e63e
bpo-47235: Note where a typo is intentional in code. (GH-32348)
People keep popping up reporting these as typos in the docs despite
being described as typos in the surrounding text.  Hopefully a comment
on the line itself makes it more obvious?

Arguably some of the typo examples are not using the "right" typo as the
"assret" one in particular is now detected by default due to how common
it was in actual code.  But I don't want to to typo chasing by changing
these examples to be other not yet auto-detected typos as they still
illustrate the point well enough.
(cherry picked from commit ac1fb07b6e)

Co-authored-by: Gregory P. Smith <greg@krypto.org>
2022-04-06 08:32:16 -07:00
Jelle Zijlstra
d1fb16ae28
[3.9] bpo-45790: List macros in same order in which fields are described (GH-29529) (GH-32321)
Signed-off-by: Rodrigo Tobar <rtobar@icrar.org>

Co-authored-by: Jelle Zijlstra <jelle.zijlstra@gmail.com>.
(cherry picked from commit b275267aa7)

Co-authored-by: rtobar <rtobar@icrar.org>
2022-04-04 22:28:21 -07:00
Miss Islington (bot)
bc9ec24290
bpo-40982: shutil docs: Remove outdated copytree() example (GH-24778)
It is not preferable to keep a copy of the implementation in the
docs.
(cherry picked from commit e06f920c5b)

Co-authored-by: Zackery Spytz <zspytz@gmail.com>
2022-04-04 20:22:04 -07:00
Miss Islington (bot)
c1984f39c5
crypt docs: Fix references to methods attr (GH-26806)
Co-authored-by: Jelle Zijlstra <jelle.zijlstra@gmail.com>
(cherry picked from commit cae0f5d3da)

Co-authored-by: andrei kulakov <andrei.avk@gmail.com>
2022-04-04 20:15:30 -07:00
Miss Islington (bot)
31c9e35e53
bpo-32658: Regex docs: Fix metacharacter reference (GH-32230)
Co-authored-by: Jelle Zijlstra <jelle.zijlstra@gmail.com>
(cherry picked from commit 43571a3eea)

Co-authored-by: Mike cm <mikecmcleod@gmail.com>
2022-04-04 20:11:36 -07:00
Miss Islington (bot)
c0063bdc7b
bpo-47007: [doc] str special method lookup (GH-31863)
Clarify the `str()` docs to point out that `object.__str__()`
follows special method lookup.

Co-authored-by: Jelle Zijlstra <jelle.zijlstra@gmail.com>
(cherry picked from commit bb86d1d9fb)

Co-authored-by: Vanshaj Singhania <8797467+itsvs@users.noreply.github.com>
2022-04-04 19:59:04 -07:00
Miss Islington (bot)
e47e6ffed3
bpo-41233: Add links to errnos referenced in exceptions docs (GH-21380)
Co-authored-by: Andrew Kuchling <amk@amk.ca>
Co-authored-by: Jelle Zijlstra <jelle.zijlstra@gmail.com>
(cherry picked from commit a74892cb21)

Co-authored-by: yyyyyyyan <24644216+yyyyyyyan@users.noreply.github.com>
2022-04-04 19:30:25 -07:00
Miss Islington (bot)
a8f29b887e
Demonstrate py --list in the quickstart section of the Windows doc page (GH-29383)
(cherry picked from commit 1ecfe3d5ae)

Co-authored-by: Christian Clauss <cclauss@me.com>
2022-04-04 09:02:23 -07:00
Miss Islington (bot)
0d0a6f18a0
Follow PEP-8 guidelines in tutorial for standard library (GH-26127)
(cherry picked from commit 6db2db91b9)

Co-authored-by: Bob Kline <bkline@users.noreply.github.com>
2022-04-03 15:58:21 -07:00
Miss Islington (bot)
b5092350b2
Language reference: Remove duplicated text about iterable unpacking (GH-25212)
(cherry picked from commit 4f5d56f8f3)

Co-authored-by: Jiashuo Li <4003950+jiasli@users.noreply.github.com>
2022-04-02 20:06:54 -07:00
Miss Islington (bot)
f4e280d8c5
bpo-24563: Link encoding names to encoding declarations (GH-32274)
(cherry picked from commit 01be5d6446)

Co-authored-by: Terry Jan Reedy <tjreedy@udel.edu>
2022-04-02 17:40:31 -07:00
Jelle Zijlstra
6eff004b96
[3.9] More minor fixes to C API docs (GH-31525) (GH-32259)
* wording fixes in type.rst

* grammar and punctuation in sys.rst

* set: grammar fixes

* structures: capitalization fix

* grammar fixes for sequence

* objects: point to Py_TYPE instead of direct object access

* numbers: add more explicit Python equivalences

* method: add missing period

* memory: grammar fix

* mapping: grammar fixes

* long: grammar fix

* iter: fix grammar for PyAIter_Check

* init: grammar fix.
(cherry picked from commit 897bc6f928)

Co-authored-by: Jelle Zijlstra <jelle.zijlstra@gmail.com>
2022-04-02 16:00:36 -07:00
Jelle Zijlstra
74138ac954
[3.9] More minor fixes to C API docs (GH-31714) (GH-32260)
* init_config: wording fixes

* bytearray: remove XXX, there is a good link to the buffer docs

* bytes, call, exceptions: minor wording fixes.
(cherry picked from commit 677a879466)

Co-authored-by: Jelle Zijlstra <jelle.zijlstra@gmail.com>
2022-04-02 16:00:13 -07:00
Jelle Zijlstra
62da258a45
[3.9] Document func parameter of locale.atof (GH-18183) (GH-32261)
The second parameter (named `func`) has been present since the `locale`
module was introduced in eef1d4e8b1, but has never been documented.

This commit updates the documentation for `locale.atof` to clarify the
behavior of the function and how the `func` parameter is used.

Signed-off-by: Kevin Locke <kevin@kevinlocke.name>.
(cherry picked from commit 208da6d508)

Co-authored-by: Kevin Locke <kevin@kevinlocke.name>
2022-04-02 15:59:57 -07:00
Miss Islington (bot)
694425817b
bpo-45584: Clarify math.trunc documentation (GH-29183)
While floor/ceil 's documentation are very precise, `truncate` was not explained. I actually had to search online to understand the difference between `truncate` and `floor` (admittedly, once I remembered that numbers are signed, and that floating numbers actually uses a bit for negation symbol instead of two complement, it became obvious)

Co-authored-by: Alex Waygood <Alex.Waygood@Gmail.com>
Co-authored-by: Éric Araujo <merwok@netwok.org>
Co-authored-by: Terry Jan Reedy <tjreedy@udel.edu>
Co-authored-by: Jelle Zijlstra <jelle.zijlstra@gmail.com>
(cherry picked from commit ebbdbbff5d)

Co-authored-by: Arthur Milchior <arthur@milchior.fr>
2022-04-02 15:36:33 -07:00
Miss Islington (bot)
bf0f04f871
codecs docs: fix grammar mistake (GH-29462)
(cherry picked from commit ea56845744)

Co-authored-by: 180909 <wjh180909@gmail.com>
2022-04-02 14:34:18 -07:00
Miss Islington (bot)
dc9322a91d
bpo-45114: Use lstat() instead of stat() in stat docs example (GH-29845)
(cherry picked from commit c93a0ac697)

Co-authored-by: 180909 <wjh180909@gmail.com>
2022-04-02 14:21:45 -07:00
Miss Islington (bot)
5b80031fb0
bpo-47031: Improve documentation for math.nan (GH-32170)
Co-authored-by: Jelle Zijlstra <jelle.zijlstra@gmail.com>
(cherry picked from commit 182e93c3f5)

Co-authored-by: Charlie Zhao <zhaoyu_hit@qq.com>
2022-04-02 13:23:26 -07:00
Miss Islington (bot)
98d57737de
bpo-14911: Corrected generator.throw() documentation (GH-32207)
Co-authored-by: Andrew Svetlov <andrew.svetlov@gmail.com>
(cherry picked from commit 8be7c2bc5a)

Co-authored-by: Dave Goncalves <davegoncalves@gmail.com>
2022-03-31 07:24:39 -07:00
Miss Islington (bot)
c26af2bc53
bpo-42340: Document issues around KeyboardInterrupt (GH-23255)
Update documentation to note that in some circumstances,
KeyboardInterrupt may cause code to enter an inconsistent state. Also
document sample workaround to avoid KeyboardInterrupt, if needed.
(cherry picked from commit d0906c90fc)

Co-authored-by: benfogle <benfogle@gmail.com>
2022-03-29 14:48:10 -07:00
Miss Islington (bot)
5f0305b383
ctypes docs: Fix array-length reference to "non-negative" from "positive" (GH-32097) (GH-32143)
(cherry picked from commit 76f14b0463)

Co-authored-by: Yonatan Goldschmidt <yon.goldschmidt@gmail.com>
Co-authored-by: Jelle Zijlstra <jelle.zijlstra@gmail.com>
2022-03-28 19:47:37 -07:00
Miss Islington (bot)
d2c6a4428d
bpo-47138: Ensure Windows docs build uses the same pinned version as other platforms (GH-32161)
(cherry picked from commit 0dfabf9b4a)

Co-authored-by: Steve Dower <steve.dower@python.org>
2022-03-28 17:10:30 -07:00
Miss Islington (bot)
1e3132b1c3
bpo-28516: document contextlib.ExitStack.__enter__ behavior (GH-31636) (GH-32145)
The enter_context is updated with following information: 'The :meth:`__enter__` method
      returns the ExitStack instance, and performs no additional operations.'

Co-authored-by: Jelle Zijlstra <jelle.zijlstra@gmail.com>
(cherry picked from commit 86384cf83f)

Co-authored-by: vidhya <96202776+Vidhyavinu@users.noreply.github.com>
Co-authored-by: Ned Deily <nad@python.org>
2022-03-28 11:45:45 -07:00
Hugo van Kemenade
25c40bd994
bpo-47138: Fix documentation build by pinning Jinja version to 3.0.3 (GH-32153)
Co-authored-by: Maciej Olko <maciej.olko@gmail.com>
2022-03-28 13:19:56 -04:00
Miss Islington (bot)
b8b473e943
bpo-47105: Cite grp.h instead of pwd.h in grp docs (GH-32091) (GH-32121)
(cherry picked from commit ee912ad6f6)

Co-authored-by: Alex Hedges <aphedges@users.noreply.github.com>
2022-03-25 20:23:04 -04:00
Hugo van Kemenade
e513b8188a
[3.9] bpo-47061: document module deprecations due to PEP 594 (GH-31984) (GH-32082)
Also removed asynchat, asyncore, and smtpd from their respective toctree entries so they are only  in the superceded subtree.
(cherry picked from commit 9ac2de922a)

Co-authored-by: Brett Cannon <brett@python.org>

Automerge-Triggered-By: GH:brettcannon
2022-03-23 13:13:08 -07:00
Jelle Zijlstra
0bbb6956f8
[3.9] bpo-46769: Improve documentation for typing.TypeVar (GH-31712) (GH-31941) (GH-32067)
* [3.9] [3.10] bpo-46769: Improve documentation for `typing.TypeVar` (GH-31712) (GH-31941)

* [3.10] bpo-46769: Improve documentation for `typing.TypeVar` (GH-31712)

Co-authored-by: Jelle Zijlstra <jelle.zijlstra@gmail.com>
(cherry picked from commit 81b425d4dc)

* Remove references to `reveal_type`, add new section on `self` types.
(cherry picked from commit d5ed8a8258)

Co-authored-by: Alex Waygood <Alex.Waygood@Gmail.com>

* remove unused susp allowlist

Co-authored-by: Alex Waygood <Alex.Waygood@Gmail.com>
2022-03-23 19:19:23 +01:00
Miss Islington (bot)
f5af1677c0
[doc] configparser: avoid inline comments. (GH-31247)
People are testing those blocs with the default
inline_comment_prefixes of None, leading to a:

configparser.InterpolationSyntaxError: '$' must be followed by '$' or '{', found: '$ sign ($ is the only character that needs to be escaped)'
(cherry picked from commit 3ac4e783e0)

Co-authored-by: Julien Palard <julien@palard.fr>
2022-03-23 02:01:24 -07:00
Miss Islington (bot)
1e4044c74e
Fix typo in Path.iterdir docs (GH-31822)
(cherry picked from commit 795b365e8a)

Co-authored-by: Matt Williams <matt@milliams.com>
2022-03-22 20:16:18 -07:00
Hugo van Kemenade
af341ebf00
[3.9] bpo-47022: Document asynchat, asyncore and smtpd removals in 3.12 (GH-31891) (#31998)
Document the deprecation of asyncore, asynchat, and smtpd with a slated removal in Python 3.12 thanks to PEP 594..
(cherry picked from commit 7747384643)

Co-authored-by: Hugo van Kemenade <hugovk@users.noreply.github.com>
2022-03-22 11:12:39 -07:00
Irit Katriel
2d5e9f8d62
bpo-12029: [doc] clarify that except does not match virtual subclasses of the specified exception type (GH-32027) (GH-32035)
(cherry picked from commit 45833b50f0)
2022-03-21 21:27:53 +00:00
Miss Islington (bot)
504973a133
bpo-46013: Fix confusing kerning on period in docs (GH-29989) (GH-32006)
(cherry picked from commit 3af68fc77c)

Co-authored-by: jmcb <joel.mcbride1@live.com>

Co-authored-by: jmcb <joel.mcbride1@live.com>
2022-03-20 12:18:02 +00:00
Miss Islington (bot)
73f4b475d1
[3.10] bpo-47040: improve document of checksum functions (GH-31955) (GH-32002)
Clarifies a versionchanged note on crc32 & adler32 docs that the workaround is only needed for Python 2 and earlier.
Also cleans up an unnecessary intermediate variable in the implementation.

Authored-By: Ma Lin / animalize
Co-authored-by: Gregory P. Smith <greg@krypto.org>
(cherry picked from commit 6d290d5862)

Co-authored-by: Ma Lin <animalize@users.noreply.github.com>
2022-03-20 00:21:34 -07:00
Miss Islington (bot)
fcd5799689
bpo-44544: add textwrap placeholder arg (GH-27671)
(cherry picked from commit cb7874f49d)

Co-authored-by: andrei kulakov <andrei.avk@gmail.com>
2022-03-19 05:54:07 -07:00
Miss Islington (bot)
73943ce7d3
bpo-31415: importtime was made by Inada Naoki (GH-31875)
(cherry picked from commit 29624e769c)

Co-authored-by: Victor Stinner <vstinner@python.org>
2022-03-14 14:30:15 -07:00
Miss Islington (bot)
b4fd91b4d9
[3.9] bpo-30677: [doc] mention that os.mkdir() can raise FileNotFoundError (GH-31548) (GH-31878)
(cherry picked from commit 879fbd9472)


Co-authored-by: slateny <46876382+slateny@users.noreply.github.com>

Automerge-Triggered-By: GH:iritkatriel
2022-03-14 13:52:07 -07:00
Illia Volochii
649cc9d688
[3.9] bpo-43215: Document Happy Eyeballs args of asyncio.open_connection (GH-24525) (GH-31868)
Co-authored-by: Andrew Svetlov <andrew.svetlov@gmail.com>.
(cherry picked from commit 3543ddb4c4)

Co-authored-by: Illia Volochii <illia.volochii@gmail.com>
2022-03-14 15:15:49 +02:00
Jason R. Coombs
177be52517
[3.9] bpo-47004: Sync with importlib_metadata 4.11.3. (GH-31854). (GH-31859)
(cherry picked from commit b1e2868607)

Co-authored-by: Jason R. Coombs <jaraco@jaraco.com>
2022-03-13 17:30:07 -04:00