30193 Commits

Author SHA1 Message Date
Miss Islington (bot)
ca6142dae9
[3.14] Programming FAQ: fix some punctuaction typos (GH-144058) (GH-144185)
(cherry picked from commit 03e651d601c7d54ffe93ef1bbd4f66fafb89eded)

Co-authored-by: Bartosz Sławecki <bartosz@ilikepython.com>
Co-authored-by: Stan Ulbrych <89152624+StanFromIreland@users.noreply.github.com>
2026-01-26 11:37:28 +01:00
Miss Islington (bot)
2097ff3e98
[3.14] gh-144233: Fix typo in os.eventfd documentation (GH-144234) (#144238)
gh-144233: Fix typo in os.eventfd documentation (GH-144234)
(cherry picked from commit 99821474336187eaf657740c4eb618044d83b9c7)

Co-authored-by: Solomon Ritzow <11698787+ritzow@users.noreply.github.com>
2026-01-26 08:14:29 +00:00
Miss Islington (bot)
1947d6ea56
[3.14] gh-144027: Fix documentation for ignorechars in base64.a85decode() (GH-144028) (GH-144192)
It does not support an ASCII string.

Also add more tests.
(cherry picked from commit 25a10b60b04ab2fa802409dc6f211cf2ca028a0a)

Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
2026-01-23 19:24:06 +00:00
Miss Islington (bot)
712452e6f1
[3.14] gh-143919: Reject control characters in http cookies (#144089)
Co-authored-by: Seth Michael Larson <seth@python.org>
Co-authored-by: Bartosz Sławecki <bartosz@ilikepython.com>
Co-authored-by: sobolevn <mail@sobolevn.me>
2026-01-23 13:44:29 +02:00
Miss Islington (bot)
80a0ce40c3
[3.14] Doc: fix incorrect reference in isasyncgenfunction docs (GH-144099) (GH-144170)
(cherry picked from commit f3dd0cae6cea38b15b42b20d39c7142a4a0f716e)

Co-authored-by: Yongtao Huang <yongtaoh2022@gmail.com>
2026-01-23 11:35:35 +01:00
Miss Islington (bot)
1fa166888b
[3.14] gh-143513: Remove importlib.abc documentation for removed ABCs (GH-143605) (GH-144166)
gh-143513: Remove importlib.abc documentation for removed ABCs (GH-143605)

In 3.11 ResourceReader, Traversable, & TraversableResources moved from importlib.abc to importlib.resources.abc (commit e712a5b277866a71c195f38c1b5d87d9126dba3e).

In 3.12 old import locations were deprecated (commit 71848c960927af801656026203371c41ad139b5a).

In 3.14 backwards-compat support was removed (commit 0751511d24295c39fdf2f5b2255e3fa3d796ce4d).
(cherry picked from commit f8262b84f5b76e45cfea9d73b09657919926850f)

Co-authored-by: Alex Willmer <alex@moreati.org.uk>
Co-authored-by: Brett Cannon <brett@python.org>
2026-01-22 14:44:32 -08:00
Miss Islington (bot)
f2b9a74cf6
[3.14] gh-141004: Mark up constants for PyOS_double_to_string (GH-143867) (GH-144146)
This ensures they show up as C macros in search and the Sphinx inventory.
(cherry picked from commit fb690c38cafb15e4ccddc52aba37f9470ce201a0)

Co-authored-by: Petr Viktorin <encukou@gmail.com>
2026-01-22 13:30:14 +01:00
Miss Islington (bot)
9d021506f0
[3.14] gh-141004: Mark up docs of old PyMem macros (GH-143783) (GH-143864)
gh-141004: Mark up docs of old PyMem macros (GH-143783)

These had a docs-only deprecation notice since the first version of the docs in this repo. Nowadays we call things “soft deprecated” if there's just a note in the docs.

The deprecated directive needs a version, I went with the first one that had the notice (2.0; it's not in 1.6):
- https://docs.python.org/release/2.0/api/memoryInterface.html
- https://docs.python.org/release/1.6/api/memoryInterface.html

Since PEP 445, they are now direct aliases; there are no (additional) binary compatibility concerns over the preferred names.
(cherry picked from commit a009e78b79ec340d9ff0e1a8ad20f8178fd3257f)

Co-authored-by: Petr Viktorin <encukou@gmail.com>
2026-01-22 11:52:05 +01:00
Miss Islington (bot)
4e63fdb31f
[3.14] gh-143993: Document ways to disable remote debugging support (GH-143994) (#144139)
gh-143993: Document ways to disable remote debugging support (GH-143994)

Although PEP 768 mentions how to disable the mechanism of
remote debugging, it is not documented in the Python docs.

This change adds a note on how to disable remote debugging support
in a Python interpreter to the remote debugging how-to.
(cherry picked from commit 0b5f8359c52f8a5ce0fe436cde499553f3b8f5d5)

Co-authored-by: Rafael Weingartner-Ortner <38643099+RafaelWO@users.noreply.github.com>
Co-authored-by: Hugo van Kemenade <1324225+hugovk@users.noreply.github.com>
2026-01-22 10:47:05 +00:00
Miss Islington (bot)
9f1ad56635
Update install manager docs (python/pymanager#227) (GH-144079)
(cherry picked from commit f52af86cba644b6eeb32506a8948b6bf53a4f363)

Co-authored-by: Steve Dower <steve.dower@python.org>
2026-01-21 15:39:00 +00:00
Miss Islington (bot)
41f76ae1c0
[3.14] gh-75459: versionadded for PyObject_CallFinalizer*() API (GH-143982) (#144026)
Co-authored-by: Sergey B Kirpichev <skirpichev@gmail.com>
2026-01-20 12:06:21 +02:00
Miss Islington (bot)
f318126907
[3.14] gh-143774 - Improve IDLE Format Paragraph doc (GH-143775) (#144062)
gh-143774 - Improve IDLE Format Paragraph doc (GH-143775)

Add a reminder to not rewrap code line to the Menu => Format => Reformat Paragraph entry.
In Editing and Nagivagion, add a new 'Format block' subsection that defines 'paragraph'
to better match what is dependably handled as more or less expected.
In particular, specify equal indents and that the resulting indent equals original indent.
Also mention that selections are expanded to complete lines and how to modify max length.

(Also fix a couple case errors in cross references.)
(cherry picked from commit fa3abf5a51d42b2d62e1bc89e9465b398a567e94)

Co-authored-by: Terry Jan Reedy <tjreedy@udel.edu>
2026-01-20 09:34:29 +00:00
Miss Islington (bot)
ec39b66878
[3.14] gh-106318: Add examples for str.rpartition() method (GH-143891) (#144040)
gh-106318: Add examples for str.rpartition() method (GH-143891)
(cherry picked from commit 3c9c3d33cbdef257526871cbc12e93635026f5d6)

Co-authored-by: Adorilson Bezerra <adorilson@gmail.com>
2026-01-19 14:22:03 +00:00
Miss Islington (bot)
5573df18d9
[3.14] gh-143754: Modernize Tkinter docs (GH-143841) (GH-144032)
Use more relevant terminology instead of "master"/"slave" widgets where possible.
(cherry picked from commit 813fc7a291c98654c27f2b5d8f9afa8e53b066a6)

Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
2026-01-19 12:27:32 +00:00
Miss Islington (bot)
bbd11568a7
[3.14] gh-143054: Disallow non-top-level Cut for now (GH-143622) (GH-143790)
The behaviour of Cut in nested parentheses, Repeat, Opt, and similar
is somewhat chaotic. Apparently even the academic papers on PEG aren't
as clear as they could be.

And it doesn't really matter. Python only uses top-level cuts.
When that changes, we can clarify as much as necessary (and even
change the implementation to make sense for what we'll need).

Document that this is deliberately unspecified, and add a test to
make sure any decision is deliberate, tested and documented.
(cherry picked from commit f0a0467c176e245a8fd45d4480a0876d748d7e78)

Co-authored-by: Petr Viktorin <encukou@gmail.com>
2026-01-15 13:52:39 +01:00
Miss Islington (bot)
37c4a6551a
[3.14] gh-141004: Document symbol visibility macros (PyAPI_DATA, Py_EXPORTED_SYMBOL, Py_LOCAL_SYMBOL,Py_IMPORTED_SYMBOL) (GH-143508) (GH-143786)
(cherry picked from commit a7ba3b124f707f73b94b59f13908872f1a48e24f)

Co-authored-by: Yashraj <yashrajpala8@gmail.com>
Co-authored-by: Petr Viktorin <encukou@gmail.com>
Co-authored-by: Victor Stinner <vstinner@python.org>
2026-01-15 13:34:27 +01:00
Miss Islington (bot)
2e493239b1
[3.14] gh-143834: Fix PyLong_AsNativeBytes docs for negative number padding (GH-143840) (GH-143854)
(cherry picked from commit 421bd1770a87d141f66754ae29e407589e44ce83)

Co-authored-by: Muneeb Ullah <moneebullah25@gmail.com>
2026-01-15 09:34:13 +01:00
Miss Islington (bot)
fd174d76de
[3.14] gh-141004: Document several soft-deprecated C APIs (GH-141634) (GH-143837)
gh-141004: Document several soft-deprecated C APIs (GH-141634)
(cherry picked from commit 0e0d51cdcef903d8a990c8e264f32f2f28af0673)

Co-authored-by: Peter Bierma <zintensitydev@gmail.com>
Co-authored-by: Petr Viktorin <encukou@gmail.com>
Co-authored-by: Victor Stinner <vstinner@python.org>
2026-01-14 13:25:57 +00:00
Miss Islington (bot)
a36ba5aee3
[3.14] gh-141004: Document old provisional names for vectorcall/code API (GH-143568) (GH-143828)
For vectorcall API, the underscore-prefixed provisional names
continue to be available per PEP 590:
https://peps.python.org/pep-0590/#finalizing-the-api
Use `versionadded`, `versionchanged`, and `:no-typesetting:`
to mark this up.

For PyCode API, use `:no-typesetting:` rather than `index::` so that
these are semantically documented as C functions.
(cherry picked from commit 7e8a1b5061313e03f99bc2ffa2062702bcc76426)

Co-authored-by: Petr Viktorin <encukou@gmail.com>
2026-01-14 11:01:37 +01:00
Miss Islington (bot)
145879b402
[3.14] gh-137113 docs: note readline no longer supported in REPL after 3.13 (GH-137142) (GH-143791)
gh-137113 docs: note readline no longer supported in REPL after 3.13 (GH-137142)

Add a note to the readline module documentation stating that
Python 3.13 and later no longer supports readline in the default REPL,
as per gh-118840. Includes workaround using PYTHON_BASIC_REPL.

Update tutorial to remove the reference, and use a different key to
test things out.
(cherry picked from commit 971f387bbb598a481aa8974ddc7a358459030415)

Signed-off-by: Kuang Yu Heng <yuheng3107@gmail.com>
Co-authored-by: Kuang Yu Heng <yuheng3107@gmail.com>
2026-01-14 10:55:52 +01:00
Petr Viktorin
9c834b4f84
[3.14] gh-141004: Document PyUnicode_IS_COMPACT and PyUnicode_IS_COMPACT_ASCII macros (GH-143494) (GH-143785)
(cherry picked from commit 42f7c2dfba58a8a8f31aba727d0fc51dd3ce2fce)

Co-authored-by: Yashraj <yashrajpala8@gmail.com>
2026-01-13 19:06:23 +01:00
Miss Islington (bot)
baba8d2c78
[3.14] gh-143728: Keep TypedDict and NamedTuple in class role in docs (GH-143702) (#143799)
Co-authored-by: Bartosz Sławecki <bartosz@ilikepython.com>
2026-01-13 13:58:10 +00:00
Miss Islington (bot)
3c8c4e98da
[3.14] gh-106318: Add examples for str.replace() method (GH-143581) (GH-143789)
(cherry picked from commit af9f783a7e9bfdca94ce5b9619c1b82a32d9e170)

Co-authored-by: Adorilson Bezerra <adorilson@gmail.com>
2026-01-13 12:22:49 +00:00
Miss Islington (bot)
af89f7cacd
[3.14] Add example of min-heap and max-heap working together (gh-137251) (#143780) 2026-01-13 09:36:59 +00:00
Raymond Hettinger
2426c4539d
[3.14] gh-143762 Backport a6bc60d for random combinatoric recipes (#143764) 2026-01-12 18:19:57 -06:00
Miss Islington (bot)
ef24f552fb
[3.14] Minor readability/usability improvement to the recipes section (gh-143753) (gh-143755) 2026-01-12 20:18:43 +00:00
Miss Islington (bot)
341e086d45
[3.14] gh-142518: Document thread-safety guarantees of list operations (GH-142519) (#143736)
* Add everything to code blocks
* Improve wording around atomicity; specify exact types
* Better explain lock-free and atomicity
(cherry picked from commit 1de46715ec50c7ae0b8e8671287239771c121e68)

Co-authored-by: Lysandros Nikolaou <lisandrosnik@gmail.com>
2026-01-12 17:55:14 +01:00
Miss Islington (bot)
46594d4fbc
[3.14] gh-140806: add docs for enum.bin function (GH-140807) (#143726)
Co-authored-by: Guo Ci <zguoci@gmail.com>
Co-authored-by: Stan Ulbrych <89152624+StanFromIreland@users.noreply.github.com>
Co-authored-by: blurb-it[bot] <43283697+blurb-it[bot]@users.noreply.github.com>
2026-01-12 12:01:01 +00:00
Hugo van Kemenade
dcf499f95f
[3.14] gh-143578: Restore note about patchlevel.h (GH-143596) (#143725)
Co-authored-by: Petr Viktorin <encukou@gmail.com>
2026-01-12 13:49:43 +02:00
Miss Islington (bot)
bfc57f70ac
[3.14] gh-142972: Document arbitrary ordering in Path.glob and Path.rglob (GH-143025) (GH-143709)
gh-142972: Document arbitrary ordering in `Path.glob` and `Path.rglob` (GH-143025)
(cherry picked from commit 9d13ca97c1a83ed649a16fb0512b5f1c5f9ad108)

Co-authored-by: Bartosz Sławecki <bartosz@ilikepython.com>
2026-01-11 19:42:10 +00:00
Miss Islington (bot)
1b38e89d9f
[3.14] gh-143420: Clarify sequence behavior for slice indexes (GH-143422) (#143701)
Co-authored-by: Sergey B Kirpichev <skirpichev@gmail.com>
2026-01-11 17:23:51 +00:00
Miss Islington (bot)
d3bd245c73
[3.14] gh-86139: Correct NamedTuple and TypedDict's type in typing.rst (GH-143692) (#143696)
Co-authored-by: AN Long <aisk@users.noreply.github.com>
Co-authored-by: Alex Waygood <Alex.Waygood@Gmail.com>
2026-01-11 15:59:14 +00:00
Miss Islington (bot)
4a33fe59f7
[3.14] Sync the batched() example with the grouper() example. (gh-143676) (gh-143678) 2026-01-10 22:19:15 -06:00
Miss Islington (bot)
92a13a00a5
[3.14] Add derangements() recipe (gh-143671) (gh-143677) 2026-01-10 22:06:37 -06:00
Miss Islington (bot)
7ed4134862
[3.14] Doc: remove duplicate GitHub issue reference in "What's New in Python 3.13" (GH-143654) (#143656)
Doc: remove duplicate GitHub issue reference in "What's New in Python 3.13" (GH-143654)
(cherry picked from commit aa8578dc54df2af9daa3353566359e602e5905cf)

Co-authored-by: emmanuel <emmanuel20232035@gmail.com>
2026-01-10 13:40:39 +00:00
Miss Islington (bot)
efa52eda61
[3.14] gh-72239: Add note distinguishing concurrent.futures.Future from asyncio.Future (GH-143288) (#143607)
gh-72239: Add note distinguishing concurrent.futures.Future from asyncio.Future (GH-143288)
(cherry picked from commit a9ca49d9c699ce4040f1391d9054d88b4098466b)

Co-authored-by: AN Long <aisk@users.noreply.github.com>
2026-01-10 12:23:21 +05:30
Miss Islington (bot)
426683e7b7
[3.14] gh-106318: Add examples for str.rfind() method (GH-143582) (#143616)
gh-106318: Add examples for str.rfind() method (GH-143582)
(cherry picked from commit c696f33d9ee425d7acd5de90d5418a3280444962)

Co-authored-by: Adorilson Bezerra <adorilson@gmail.com>
2026-01-09 15:30:11 +00:00
Miss Islington (bot)
ae62d2bb31
[3.14] gh-106318: Improve str.removeprefix() and str.removesuffix() docs (GH-143580) (#143614)
gh-106318: Improve str.removeprefix() and str.removesuffix() docs (GH-143580)

Add doctest role and 'See also'.
(cherry picked from commit 6d6c7ed73786915d16f6ac3d8b6e6d67f404209f)

Co-authored-by: Adorilson Bezerra <adorilson@gmail.com>
2026-01-09 15:28:36 +00:00
Miss Islington (bot)
335c83ed28
[3.14] gh-143553: Add support for parametrized resources in regrtests (GH-143554) (GH-143555)
For example, "-u xpickle=2.7" will run test_xpickle only against Python 2.7.
(cherry picked from commit c07e5ec0a9e5843fc39dec6aa94172faf6354858)

Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
2026-01-08 18:12:33 +02:00
Miss Islington (bot)
6c6eb7abe5
[3.14] gh-143513: Clarify changed argument name of ResourceReader.is_resource (GH-143523) (GH-143562)
gh-143513: Clarify changed argument name of `ResourceReader.is_resource` (GH-143523)
(cherry picked from commit 5462002bbefd6cb79716828051beae94de8f2529)

Co-authored-by: Alex Willmer <alex@moreati.org.uk>
2026-01-08 13:45:57 +00:00
Miss Islington (bot)
9ab5a24d86
[3.14] Fix a typo in STORE_SLICE docs (GH-143500) (#143533)
Fix a typo in STORE_SLICE docs (GH-143500)
(cherry picked from commit 228d95582e080c60335d5f0a229a6698eb69b11c)

Co-authored-by: Tomas R <tomas.roun8@gmail.com>
2026-01-07 22:42:12 +00:00
Miss Islington (bot)
76afbe2747
[3.14] gh-106318: Add examples for str.casefold() and str.lower() methods (GH-142154) (#143524)
gh-106318: Add examples for str.casefold() and str.lower() methods (GH-142154)
(cherry picked from commit 51a56a3a7bd8cf05ceda65e843fb7bae40509799)

Co-authored-by: Adorilson Bezerra <adorilson@gmail.com>
Co-authored-by: Victor Stinner <vstinner@python.org>
Co-authored-by: Stan Ulbrych <89152624+StanFromIreland@users.noreply.github.com>
2026-01-07 18:03:20 +01:00
Miss Islington (bot)
951bb2ab4b
[3.14] gh-106318: Add example for str.index() (GH-137023) (#143502)
Co-authored-by: Adorilson Bezerra <adorilson@gmail.com>
2026-01-06 21:48:19 +00:00
Miss Islington (bot)
b0eb1980bb
[3.14] gh-133315: Document that compat32 should not be used with MIMEPart/EmailMessage (GH-143307) (#143496)
gh-133315: Document that compat32 should not be used with MIMEPart/EmailMessage (GH-143307)
(cherry picked from commit ff7d1cec41f391270560b9f4726791d8476c6eba)

Co-authored-by: Andrii Hrimov <andrew.hrimov@gmail.com>
2026-01-06 15:33:31 -05:00
Miss Islington (bot)
66d38b326f
[3.14] Doc: Fix missing closing parenthesis in argparse example (GH-143488) (#143489)
Doc: Fix missing closing parenthesis in argparse example (GH-143488)
(cherry picked from commit 51227b6b1a9181ef4da10811e7b5a55474fc4378)

Co-authored-by: Xiao Yuan <yuanx749@gmail.com>
2026-01-06 17:59:49 +00:00
Miss Islington (bot)
22a99ca8e1
[3.14] gh-142302: Fix mkstemp() documentation: clarify file descriptor inheritance behavior (GH-142338) (#143486)
gh-142302: Fix mkstemp() documentation: clarify file descriptor inheritance behavior (GH-142338)

The documentation incorrectly stated that the file descriptor is not
inherited by child processes. In reality, the close-on-exec flag (when
available) only prevents inheritance across exec() calls, not fork().
(cherry picked from commit e79c9b703117d8b0e7c4d86b704e2e7f120db883)

Co-authored-by: ADITYA RAI <adi.hack1234@gmail.com>
Co-authored-by: Victor Stinner <vstinner@python.org>
2026-01-06 17:14:12 +00:00
Miss Islington (bot)
b9b2b3d86a
[3.14] gh-106318: Add examples for str.isprintable() (GH-140043) (#143483)
gh-106318: Add examples for str.isprintable()  (GH-140043)
(cherry picked from commit 7b0a372b20ae3b80053d52e84c2b7bdd114c19f0)

Co-authored-by: Adorilson Bezerra <adorilson@gmail.com>
Co-authored-by: Stan Ulbrych <89152624+StanFromIreland@users.noreply.github.com>
2026-01-06 16:49:41 +00:00
Semyon Moroz
8b72c3d561
[3.14] gh-143331: Schedule to remove format "N" for Decimal (GH-143372) (#143476)
(cherry picked from commit dd750b348501247d458ea8d454213d4959a8f8b9)
2026-01-06 15:58:29 +02:00
Miss Islington (bot)
dbf08242b5
[3.14] gh-143434: Fix typo in zstd documentation (GH-143437) (#143444)
gh-143434: Fix typo in zstd documentation (GH-143437)
(cherry picked from commit 240a6c326276c01cc7714a91a3e08eb77ddc4bc7)

Co-authored-by: Ritam Pal <ritamjunior26@gmail.com>
2026-01-05 20:01:08 +00:00
Miss Islington (bot)
98bb48e55c
[3.14] gh-76187: Document the c typecode for multiprocessing.Array. (GH-132504) (#143369)
gh-76187: Document the `c` typecode for `multiprocessing.Array`. (GH-132504)

* Document the `c` typecode for `multiprocessing.Array`.

* Add quotes

* Mention that 'w' is not supported
(cherry picked from commit 136f6d835588e0f72cecdff855afc8f424381ed5)

Co-authored-by: Tomas R <tomas.roun8@gmail.com>
2026-01-02 19:24:06 +00:00