Commit graph

13597 commits

Author SHA1 Message Date
Serhiy Storchaka
d321b6ec82
[3.13] gh-132099: Harmonize Bluetooth address handling (GH-132486) (GH-132497)
Now all protocols always accept the Bluetooth address as string and
getsockname() always returns the Bluetooth address as string.

* BTPROTO_SCO now accepts not only bytes, but str.
* BTPROTO_SCO now checks address for embedded null.
* On *BSD, BTPROTO_HCI now accepts str instead of bytes.
* On FreeBSD, getsockname() for BTPROTO_HCI now returns str instead of bytes.
* On NetBSD and DragonFly BSD, BTPROTO_HCI now checks address for embedded null.
(cherry picked from commit 1fc1df8dcc)
2025-04-14 19:36:04 +03:00
Miss Islington (bot)
fd0bba67c4
[3.13] gh-86513: improve docs of loop.call_exception_handler (GH-132466) (#132487)
gh-86513: improve docs of loop.call_exception_handler (GH-132466)
(cherry picked from commit ce753517a8)

Co-authored-by: Kumar Aditya <kumaraditya@python.org>
2025-04-14 11:42:45 +00:00
Miss Islington (bot)
f206b98c18
[3.13] gh-101100: Fix sphinx warnings in library/plistlib.rst (GH-132422) (#132485)
Co-authored-by: Yuki Kobayashi <drsuaimqjgar@gmail.com>
2025-04-13 18:41:56 +00:00
Miss Islington (bot)
d021b719ed
[3.13] gh-132111: Document dataclasses.InitVar (GH-132446) (#132483)
gh-132111: Document dataclasses.InitVar (GH-132446)
(cherry picked from commit 281fc338fd)

Co-authored-by: Tapeline <mail@tapeline.dev>
2025-04-13 16:53:40 +00:00
Serhiy Storchaka
54e1b63333
[3.13] gh-132099: Fix documentation for the BTPROTO_HCI protocol (GH-132118) (GH-132482)
(cherry picked from commit 1d97488c95)
2025-04-13 16:27:41 +00:00
Vinay Sajip
1dcdac6e08
[3.13] gh-132106: Ensure that running `logging.handlers.QueueListener… (GH-132471)
Cherry-picked using 5863cd70b8
2025-04-13 13:00:50 +01:00
Miss Islington (bot)
ff66901d8a
[3.13] gh-132354: document return value for asyncio.Task.cancel (GH-132374) (#132465)
gh-132354: document return value for `asyncio.Task.cancel` (GH-132374)
(cherry picked from commit 64b066ad29)

Co-authored-by: Felix Scherz <felixwscherz@gmail.com>
2025-04-13 07:41:26 +00:00
Miss Islington (bot)
17b61394ee
[3.13] gh-123441: Update Belorussian spelling (GH-132409) (GH-132432)
(cherry picked from commit ad3bbe8fbc)

Co-authored-by: Stan Ulbrych <89152624+StanFromIreland@users.noreply.github.com>
2025-04-12 10:42:31 +00:00
Miss Islington (bot)
c1744902c7
[3.13] gh-106482: Clarify documentation of character set in RE (GH-106517) (#132365)
Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
Co-authored-by: Martin Panter <vadmium@users.noreply.github.com>
Co-authored-by: Hugo van Kemenade <1324225+hugovk@users.noreply.github.com>
2025-04-10 13:48:57 +00:00
Miss Islington (bot)
8e017f2f48
[3.13] Docs: Add a missing trailing full stop (GH-130561) (#132358)
Co-authored-by: Liam DeVoe <orionldevoe@gmail.com>
2025-04-10 11:57:40 +00:00
Miss Islington (bot)
b328e4bc57
[3.13] gh-72631: Fix wrong documentation for GzipFile.peek (GH-29820) (#132353)
Co-authored-by: 180909 <wjh180909@gmail.com>
Co-authored-by: Hugo van Kemenade <hugovk@users.noreply.github.com>
Co-authored-by: Erlend E. Aasland <erlend@python.org>
2025-04-10 11:27:20 +00:00
Miss Islington (bot)
c3c8e31547
[3.13] gh-106670: Fix a typo in doc of pdb's exceptions command (GH-132277) (#132279)
gh-106670: Fix a typo in doc of pdb's exceptions command (GH-132277)
(cherry picked from commit efd8aca62c)

Co-authored-by: Tian Gao <gaogaotiantian@hotmail.com>
2025-04-08 21:28:35 +00:00
Miss Islington (bot)
5aa7aeb50f
[3.13] gh-132021: Add bool type to the list of allowed JSON key types (GH-132048) (#132255)
gh-132021: Add bool type to the list of allowed JSON key types (GH-132048)
(cherry picked from commit 403886c28d)

Co-authored-by: Srinivas Reddy Thatiparthy (తాటిపర్తి శ్రీనివాస్  రెడ్డి) <thatiparthysreenivas@gmail.com>
Co-authored-by: Eric V. Smith <ericvsmith@users.noreply.github.com>
2025-04-08 08:51:39 +00:00
Miss Islington (bot)
7e9c5772a8
[3.13] gh-115684: Clarify datetime replace documentation (GH-116519) (#131676)
gh-115684: Clarify datetime `replace` documentation (GH-116519)

* Clarify datetime `replace` documentation

In GH-115684, HopedForLuck noted that `datetime.date.replace()`
documentation was confusing because it looked like it would be changing
immutable objects.

This documentation change specifies that the `replace()` methods in
`datetime` return new objects. This uses similar wording to the
documentation for `datetime.combine()`, which specifies that a new
datetime is returned. This is also similar to wording for
`string.replace()`, except `string.replace()` emphasizes that a "copy"
is returned.

Resolves GH-115684.

* Include reviewer comments

Thanks Privat33r-dev for the comments!

---------
(cherry picked from commit d2d886215c)

Co-authored-by: David Lowry-Duda <david@lowryduda.com>
Co-authored-by: Paul Ganssle <1377457+pganssle@users.noreply.github.com>
2025-04-08 10:45:21 +02:00
Miss Islington (bot)
bd2f518555
[3.13] gh-132221: Fix __match_args__ generation docs in dataclasses.rst (GH-132222) (#132226)
gh-132221: Fix `__match_args__` generation docs in `dataclasses.rst` (GH-132222)
(cherry picked from commit 8b62374b34)

Co-authored-by: sobolevn <mail@sobolevn.me>
2025-04-07 14:52:55 +00:00
Prometheus3375
07483c2c80
[3.13] gh-131912: Improve description of grouping options in the format specification docs (GH-132030) (#132123)
(cherry picked from commit 06a110f522)
2025-04-07 09:19:13 +02:00
Miss Islington (bot)
2f1fc0fab9
[3.13] Docs: Add a single table summary for `cmath` (GH-131887) (#132179)
Docs: Add a single table summary for ``cmath`` (GH-131887)
(cherry picked from commit 6eaa4aeef2)

Co-authored-by: Sergey B Kirpichev <skirpichev@gmail.com>
Co-authored-by: Adam Turner <9087854+AA-Turner@users.noreply.github.com>
Co-authored-by: Bénédikt Tran <10796600+picnixz@users.noreply.github.com>
Co-authored-by: Hugo van Kemenade <1324225+hugovk@users.noreply.github.com>
Co-authored-by: Stan Ulbrych <89152624+StanFromIreland@users.noreply.github.com>
2025-04-06 23:42:49 +00:00
Miss Islington (bot)
65181de34c
[3.13] Docs: document plistlib.InvalidFileException (GH-132069) (#132116)
Docs: document `plistlib.InvalidFileException` (GH-132069)
(cherry picked from commit 99e9798d61)

Co-authored-by: Yuki Kobayashi <drsuaimqjgar@gmail.com>
2025-04-05 10:53:13 +02:00
Miss Islington (bot)
2745984d13
[3.13] gh-125957: sync argument naming in sphinx docs of the cmath and help() (GH-125958) (#131962)
gh-125957: sync argument naming in sphinx docs of the cmath and help() (GH-125958)
(cherry picked from commit 0a3eb8855c)

Co-authored-by: Sergey B Kirpichev <skirpichev@gmail.com>
Co-authored-by: Bénédikt Tran <10796600+picnixz@users.noreply.github.com>
2025-04-01 07:22:29 +00:00
Miss Islington (bot)
19187991a8
[3.13] gh-129994: update docs when using dualstack_ipv6 in socket.create_server (GH-129996) (#131890)
gh-129994: update docs when using `dualstack_ipv6` in `socket.create_server` (GH-129996)
(cherry picked from commit 044a1e13d5)

Co-authored-by: Alexander Ershov <150328014+AEErshov@users.noreply.github.com>
2025-03-30 12:07:08 +02:00
Miss Islington (bot)
2570896ad7
[3.13] gh-131885: Document that dict.setdefault and dict.get take no keyword arguments (GH-128208) (#131893)
gh-131885: Document that `dict.setdefault` and `dict.get` take no keyword arguments (GH-128208)
(cherry picked from commit edfbd8c062)

Co-authored-by: Adam Dangoor <adamdangoor@gmail.com>
2025-03-30 09:28:49 +00:00
Miss Islington (bot)
9ffa80f21e
[3.13] gh-127541: Update os.walk example (GH-127765) (GH-131869)
gh-127541: Update os.walk example (GH-127765)

Update os.walk example to be more modern, skip `__pycache__` dirs rather than `CVS` dirs.
(cherry picked from commit a5949986d6)

Co-authored-by: Totosuki <116938397+totosuki@users.noreply.github.com>
Co-authored-by: Bénédikt Tran <10796600+picnixz@users.noreply.github.com>
2025-03-29 06:49:15 +00:00
Miss Islington (bot)
9118cf77ae
[3.13] Fix typo in importlib.metadata.rst (gh-131596) (#131630)
Fix typo in importlib.metadata.rst (gh-131596)
(cherry picked from commit 5fc889ffbf)

Co-authored-by: Zsolt Dollenstein <zsol.zsol@gmail.com>
2025-03-27 15:42:47 +02:00
Miss Islington (bot)
b4fa4c2c3c
[3.13] document that sys._is_gil_enabled is CPython-specific (GH-131748) (#131760)
document that `sys._is_gil_enabled` is CPython-specific (GH-131748)
(cherry picked from commit ac12de2e6a)

Co-authored-by: Ralf Gommers <ralf.gommers@gmail.com>
2025-03-26 17:44:47 +05:30
Petr Viktorin
478eb73103
[3.13] gh-130587: Add hand-written docs for non-OP tokens (GH-130588) (GH-131465)
Co-authored-by: Blaise Pabon <blaise@gmail.com>
Co-authored-by: Adam Turner <9087854+AA-Turner@users.noreply.github.com>
Co-authored-by: Lysandros Nikolaou <lisandrosnik@gmail.com>
2025-03-24 12:34:23 +00:00
Miss Islington (bot)
f577a43b8d
[3.13] gh-130283: update deprecated links and examples in urllib.request docs (GH-130284) (#131626)
gh-130283: update deprecated links and examples in `urllib.request` docs (GH-130284)
(cherry picked from commit fd459b1153)

Co-authored-by: Kanishk Pachauri <itskanishkp.py@gmail.com>
Co-authored-by: Bénédikt Tran <10796600+picnixz@users.noreply.github.com>
2025-03-23 13:35:24 +00:00
Miss Islington (bot)
5e3f93a8d7
[3.13] gh-121529: Document from_ parameter in _mboxMMDF public methods (GH-121530) (#131623)
gh-121529: Document `from_` parameter in `_mboxMMDF` public methods (GH-121530)
(cherry picked from commit 557d2d20d4)

Co-authored-by: Sebb <sebbASF@users.noreply.github.com>
2025-03-23 12:17:37 +00:00
Miss Islington (bot)
49efc411fa
[3.13] gh-118915: Document PY_MONITORING_IS_INSTRUMENTED_EVENT (GH-128026) (GH-131424)
(cherry picked from commit f819900245)

Co-authored-by: Yuki Kobayashi <drsuaimqjgar@gmail.com>
2025-03-19 11:37:34 +01:00
Miss Islington (bot)
b39e67396f
[3.13] gh-131417: Mention asyncio Future and Task in docs for generic classes list (GH-131422) (#131445)
gh-131417: Mention asyncio Future and Task in docs for generic classes list (GH-131422)

Mention asyncio Future and Task in docs for generic classes list
(cherry picked from commit 61b4b2c57c)

Co-authored-by: Andrew Svetlov <andrew.svetlov@gmail.com>
2025-03-19 10:23:48 +01:00
Miss Islington (bot)
e425b075fe
[3.13] gh-131002: clarify how to enforce sqlite3 column types for generated fields (GH-131006) (#131385)
(cherry picked from commit f48887fb97)

Co-authored-by: Erlend E. Aasland <erlend@python.org>
2025-03-18 12:09:41 +01:00
Miss Islington (bot)
f297dabbe0
[3.13] gh-130132: properly free resources in urrlib.urlopen examples (GH-130280) (#131394)
gh-130132: properly free resources in `urrlib.urlopen` examples (GH-130280)
(cherry picked from commit 77d2fd4413)

Co-authored-by: Kanishk Pachauri <itskanishkp.py@gmail.com>
Co-authored-by: sobolevn <mail@sobolevn.me>
Co-authored-by: Bénédikt Tran <10796600+picnixz@users.noreply.github.com>
2025-03-18 09:33:19 +00:00
Miss Islington (bot)
98195b2108
[3.13] gh-131094: Refine math.isclose docs (GH-131139) (#131392)
gh-131094: Refine `math.isclose` docs (GH-131139)
(cherry picked from commit 3f50f96586)

Co-authored-by: Guy Jacoby <49398101+guyjacoby@users.noreply.github.com>
2025-03-18 09:21:13 +00:00
Miss Islington (bot)
3feebdd61d
[3.13] Docs: Fix incorrect sphinx markup for a class member (GH-130970) (GH-131366)
(cherry picked from commit 9a634c5c0c)

Co-authored-by: Yuki Kobayashi <drsuaimqjgar@gmail.com>
2025-03-17 16:46:05 +01:00
Miss Islington (bot)
4d7d249a05
[3.13] gh-131327: Document winsound.SND_APPLICATION (GH-131328) (#131330)
gh-131327: Document winsound.SND_APPLICATION (GH-131328)
(cherry picked from commit bf4c1bf344)

Co-authored-by: AN Long <aisk@users.noreply.github.com>
Co-authored-by: Bénédikt Tran <10796600+picnixz@users.noreply.github.com>
2025-03-16 15:52:48 +00:00
Miss Islington (bot)
1512cc0a81
[3.13] gh-130160: use .. program:: directive for documenting doctest CLI (GH-131034) (#131320)
gh-130160: use `.. program::` directive for documenting `doctest` CLI (GH-131034)
(cherry picked from commit 9558d22ac3)

Co-authored-by: donBarbos <donbarbos@proton.me>
Co-authored-by: Bénédikt Tran <10796600+picnixz@users.noreply.github.com>
2025-03-16 11:59:26 +00:00
Miss Islington (bot)
b7e15a93b4
[3.13] gh-130160: use .. program:: directive for documenting http.server CLI (GH-131010) (#131293)
gh-130160: use `.. program::` directive for documenting `http.server` CLI (GH-131010)
(cherry picked from commit 7ae9c5dd25)

Co-authored-by: donBarbos <donbarbos@proton.me>
2025-03-15 21:12:40 +02:00
Miss Islington (bot)
0f97abf498
[3.13] gh-124269: Simplify typing.Annotated docs (GH-130770) (#131222)
gh-124269: Simplify `typing.Annotated` docs (GH-130770)

---------
(cherry picked from commit e4ac196aaa)

Co-authored-by: Stan Ulbrych <89152624+StanFromIreland@users.noreply.github.com>
Co-authored-by: Jelle Zijlstra <jelle.zijlstra@gmail.com>
Co-authored-by: Bénédikt Tran <10796600+picnixz@users.noreply.github.com>
2025-03-14 09:53:03 +00:00
Yuki Kobayashi
a49f85a694
[3.13] gh-101100: Fix sphinx warnings in library/asyncio-subprocess.rst (GH-130994) (#131074)
(cherry picked from commit 7cc99a54b7)
2025-03-11 14:30:47 +02:00
Miss Islington (bot)
edb69578ed
[3.13] gh-80421: Correct definitions of time (GH-130984) (#131022)
gh-80421: Correct definitions of time (GH-130984)

Based on the Wikipedia article, UTC is better said to be a successor than a renaming of GTC and language agnostic rather than an English-French compromise.
(cherry picked from commit 98fa4a49fe)

Co-authored-by: Stan Ulbrych <89152624+StanFromIreland@users.noreply.github.com>
2025-03-09 20:15:37 +00:00
Miss Islington (bot)
28406cd0a1
[3.13] gh-130160: use .. program:: directive for documenting pdb CLI (GH-130996) (#131014)
gh-130160: use `.. program::` directive for documenting `pdb` CLI (GH-130996)
(cherry picked from commit c240c2d88a)

Co-authored-by: donBarbos <donbarbos@proton.me>
2025-03-09 16:15:41 +00:00
Miss Islington (bot)
d50941c1c3
[3.13] gh-130160: use .. program:: directive for documenting webbrowser CLI (GH-130995) (#131003)
gh-130160: use `.. program::` directive for documenting `webbrowser` CLI (GH-130995)

use `.. program::` directive for documenting `webbrowser` CLI
(cherry picked from commit 92e5f826ac)

Co-authored-by: donBarbos <donbarbos@proton.me>
2025-03-09 07:03:56 +00:00
Miss Islington (bot)
aef7edaf23
[3.13] gh-123726: Document caveats of zipfile.Path around name sanitization (GH-130537) (#130986)
gh-123726: Document caveats of zipfile.Path around name sanitization (GH-130537)

Add a note to the `zipfile.Path` class documentation clarifying that it does not sanitize filenames. This emphasizes the caller's responsibility to validate or sanitize inputs, especially when handling untrusted ZIP archives, to prevent path traversal vulnerabilities. The note also references the `extract` and `extractall` methods for comparison and suggests using `os.path.abspath` and `os.path.commonpath` for safe filename resolution.
(cherry picked from commit a3990df612)

Co-authored-by: Affan Shaikhsurab <51104750+AffanShaikhsurab@users.noreply.github.com>
2025-03-08 21:43:12 +00:00
Miss Islington (bot)
ab749678e5
[3.13] Update links from typing.readthedocs.io to typing.python.org (GH-130877) (#130883)
Update links from typing.readthedocs.io to typing.python.org (GH-130877)
(cherry picked from commit 4f6218959e)

Co-authored-by: Sebastian Rittau <srittau@rittau.biz>
2025-03-05 15:34:17 +00:00
Miss Islington (bot)
418021e229
[3.13] gh-129567: Add a note to typing.TypedDict docs about name mangling (GH-130233) (#130841)
gh-129567: Add a note to `typing.TypedDict` docs about name mangling (GH-130233)
(cherry picked from commit 63ffb406bb)

Co-authored-by: sobolevn <mail@sobolevn.me>
2025-03-04 15:21:11 +00:00
Miss Islington (bot)
57dcbfd7da
[3.13] Docs: Fix a misplaced statement in the document for ServerProxy (GH-130616) (GH-130640)
Docs: Fix a misplaced statement in the document for `ServerProxy` (GH-130616)

The sentence "If an HTTPS URL ..." explains what the parameter means,
so moved it to the paragraph explaining what the other parameters mean.
(cherry picked from commit b26286ca49)

Co-authored-by: Yuki Kobayashi <drsuaimqjgar@gmail.com>
2025-03-03 15:09:26 +01:00
Miss Islington (bot)
36e696738b
[3.13] gh-101100: Fix sphinx warnings in library/email.errors.rst (GH-130774) (#130781)
gh-101100: Fix sphinx warnings in `library/email.errors.rst` (GH-130774)
(cherry picked from commit a105f99019)

Co-authored-by: Yuki Kobayashi <drsuaimqjgar@gmail.com>
2025-03-03 12:04:51 +02:00
Miss Islington (bot)
f51a7483f5
[3.13] gh-101100: Fix Sphinx documentation warnings in collections.rst (GH-130629) (#130779)
gh-101100: Fix Sphinx documentation warnings in `collections.rst` (GH-130629)
(cherry picked from commit 373eb1b47a)

Co-authored-by: Victorien <65306057+Viicos@users.noreply.github.com>
2025-03-03 09:57:28 +00:00
Miss Islington (bot)
e96f914328
[3.13] gh-129015: Improve disambiguation between NotImplemented and NotImplementedError (GH-129562) (#130776)
gh-129015: Improve disambiguation between `NotImplemented` and `NotImplementedError` (GH-129562)

---------

(cherry picked from commit a85eeb9771)

Co-authored-by: Mike Castle <dalgoda+github@gmail.com>
Co-authored-by: Bénédikt Tran <10796600+picnixz@users.noreply.github.com>
Co-authored-by: Adam Turner <9087854+AA-Turner@users.noreply.github.com>
2025-03-03 08:29:29 +00:00
Miss Islington (bot)
3bef4af301
[3.13] gh-128481: indicate that the default value for FrameSummary.end_lineno changed in 3.13 (GH-130755) (#130767)
gh-128481: indicate that the default value for `FrameSummary.end_lineno` changed in 3.13 (GH-130755)

The value taken by `FrameSummary.end_lineno` when passing `end_lineno=None` changed in gh-112097.

Previously, a `end_lineno` could be specified to be `None` directly but since 939fc6d, passing None makes
the constructor use the value of `lineno` instead.
(cherry picked from commit c6513f7a62)

Co-authored-by: Bénédikt Tran <10796600+picnixz@users.noreply.github.com>
2025-03-02 17:22:48 +00:00
Miss Islington (bot)
ff14c1e7a9
[3.13] Add link in the importlib.metadata.version() docs (GH-130739) (#130761)
Add link in the `importlib.metadata.version()` docs (GH-130739)

Link the specification for the returned data makes it clearer what this is
and what the format of the version string can be.
(cherry picked from commit c71e55869e)

Co-authored-by: Tim Hoffmann <2836374+timhoffm@users.noreply.github.com>
2025-03-02 10:42:15 +00:00