Commit graph

26805 commits

Author SHA1 Message Date
Miss Islington (bot)
0f42f41ea8
[3.12] gh-107091: Fix some uses of :const: role (GH-107379) (GH-107384)
It is for references, not for literals.
(cherry picked from commit 0aa58fa7a6)

Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
2023-07-28 10:35:20 +00:00
Mark Shannon
3b1a4c1842
[3.12] GH-106897: Add RERAISE event to sys.monitoring. (GH-107291) (GH-107346)
* Ensures that exception handling events are balanced. Each [re]raise event has a matching unwind/handled event.
2023-07-28 09:48:35 +01:00
Serhiy Storchaka
4014869b4b
[3.12] gh-107298: Fix yet more Sphinx warnings in the C API doc (GH-107345) (GH-107380)
(cherry picked from commit 983305268e)
2023-07-28 08:20:53 +00:00
Serhiy Storchaka
e6a4b10820
[3.12] gh-107298: Fix more Sphinx warnings in the C API doc (GH-107329) (GH-107376)
Declare the following functions as macros, since they are actually
macros. It avoids a warning on "TYPE" or "macro" argument.

* PyMem_New()
* PyMem_Resize()
* PyModule_AddIntMacro()
* PyModule_AddStringMacro()
* PyObject_GC_New()
* PyObject_GC_NewVar()
* PyObject_New()
* PyObject_NewVar()

Add C standard C types to nitpick_ignore in Doc/conf.py:

* int64_t
* uint64_t
* uintptr_t

No longer ignore non existing "__int" type in nitpick_ignore.

Update Doc/tools/.nitignore.
(cherry picked from commit 8d61a71f9c)

Co-authored-by: Victor Stinner <vstinner@python.org>
2023-07-28 09:56:52 +03:00
Serhiy Storchaka
ef7422a1b9
[3.12] gh-107298: Fix Sphinx warnings in the C API doc (GH-107302) (GH-107375)
(cherry picked from commit 391e03fa05)

Co-authored-by: Victor Stinner <vstinner@python.org>
2023-07-28 06:40:16 +00:00
Miss Islington (bot)
17ce87ba7f
[3.12] gh-107298: Fix doc references to undocumented modules (GH-107300) (GH-107370)
Update also Doc/tools/.nitignore.
(cherry picked from commit 87b39028e5)

Co-authored-by: Victor Stinner <vstinner@python.org>
2023-07-28 06:17:49 +00:00
Miss Islington (bot)
0063ad8189
[3.12] Bump some docs dependencies to resolve a Dependabot security alert (GH-107341) (#107342)
Bump some docs dependencies to resolve a Dependabot security alert (GH-107341)
(cherry picked from commit f84d77b4e0)

Co-authored-by: Alex Waygood <Alex.Waygood@Gmail.com>
2023-07-27 13:13:02 +01:00
Miss Islington (bot)
38c982d92e
[3.12] gh-106996: Rewrite turtle explanation (GH-107244) (#107335)
Co-authored-by: Daniele Procida <daniele@vurt.org>
Co-authored-by: Hugo van Kemenade <hugovk@users.noreply.github.com>
2023-07-27 08:11:50 +00:00
Miss Islington (bot)
5f3e371e2d
[3.12] Docs: Argument Clinic: Restructure "Basic concepts and usage" (GH-106981) (#107325)
Split "Basic concepts and usage" into:

- Reference
  - Terminology
  - CLI reference

- Background
  - Basic concepts

(cherry picked from commit 2ad699002e)

Co-authored-by: Erlend E. Aasland <erlend@python.org>
Co-authored-by: Adam Turner <9087854+AA-Turner@users.noreply.github.com>
Co-authored-by: Alex Waygood <Alex.Waygood@Gmail.com>
Co-authored-by: Ezio Melotti <ezio.melotti@gmail.com>
2023-07-27 09:07:55 +02:00
Miss Islington (bot)
36e96baa33
[3.12] gh-107298: Docs: add targets for some :c:member: and :c:macro: references (GH-107316) (GH-107332)
Add targets for PyStructSequence_Desc and PyStructSequence_Field members
and macros like Py_EQ.
Fix target for Py_RETURN_RICHCOMPARE.
(cherry picked from commit abec9a1b20)

Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
2023-07-27 09:37:54 +03:00
Serhiy Storchaka
434e3b89a7
[3.12] gh-107091: Fix some uses of :attr: role (GH-107318) (GH-107330)
Fix also formatting of PyMethodDef members.
(cherry picked from commit d363eb5b02)
2023-07-27 09:24:18 +03:00
Miss Islington (bot)
6bbcd792f7
[3.12] Docs: Remove the numbered steps from the Argument Clinic tutorial (GH-107203) (#107317)
Instead, order the tutorial as one body of prose, making it easier to
align the tutorial according to Diátaxis principles.

(cherry picked from commit 592395577c)

Co-authored-by: Erlend E. Aasland <erlend@python.org>
2023-07-26 21:03:35 +00:00
Miss Islington (bot)
58af565c50
[3.12] Document that os.link() is not available on Emscripten (GH-104822) (GH-107308)
Document that `os.link()` is not available on Emscripten (GH-104822)
(cherry picked from commit 737d1da074)

Co-authored-by: Roman Yurchak <rth.yurchak@gmail.com>
2023-07-26 13:00:40 -07:00
Miss Islington (bot)
da2097dffb
[3.12] gh-107091: Fix some uses of :c:type: role (GH-107138) (GH-107312)
(cherry picked from commit 6d5b6e71c8)

Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
2023-07-26 19:37:39 +00:00
Miss Islington (bot)
9f5a5f0b33
[3.12] gh-107091: Fix some uses of :c:member: role (GH-107129) (GH-107310)
(cherry picked from commit af61cb9c78)

Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
2023-07-26 22:30:46 +03:00
Miss Islington (bot)
0d2e1317bd
[3.12] gh-106948: Update documentation nitpick_ignore for c:identifer domain (GH-107295) (#107297)
gh-106948: Update documentation nitpick_ignore for c:identifer domain (GH-107295)

Update the nitpick_ignore of the documentation configuration to fix
Sphinx warnings about standard C types when declaring functions with
the "c:function" markups.

Copy standard C types declared in the "c:type" domain to the
"c:identifier" domain, since "c:function" markup looks for types in
the "c:identifier" domain.

(cherry picked from commit b1de3807b8)

Co-authored-by: Victor Stinner <vstinner@python.org>
Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
2023-07-26 18:16:04 +02:00
Miss Islington (bot)
0107731a06
[3.12] gh-106939: document ShareableList nul-strip quirk. (GH-107266) (#107269)
gh-106939: document ShareableList nul-strip quirk. (GH-107266)

* gh-106939: document ShareableList nul-strip quirk.
* Mention the `int` size constraint.
(cherry picked from commit 70dc009469)

Co-authored-by: Gregory P. Smith <greg@krypto.org>
2023-07-25 21:19:25 +00:00
Ezio Melotti
313284aa42
[3.12] Remove superflous whitespaces in layout.html. (#107251)
Remove superflous whitespaces in layout.html.
2023-07-25 16:25:07 +00:00
Miss Islington (bot)
fab36fb63e
[3.12] gh-106996: Add a how-to section to the turtle documentation (GH-107153) (#107233)
Co-authored-by: Daniele Procida <daniele@vurt.org>
Co-authored-by: Hugo van Kemenade <hugovk@users.noreply.github.com>
2023-07-25 12:20:30 +00:00
Miss Islington (bot)
beb5514826
[3.12] gh-107017: Change Chapter Strings to Texts in the Introduction chapter. (GH-107104) (#107167)
Co-authored-by: TommyUnreal <45427816+TommyUnreal@users.noreply.github.com>
Co-authored-by: Hugo van Kemenade <hugovk@users.noreply.github.com>
2023-07-24 16:30:22 +00:00
Miss Islington (bot)
5ff4dfa0cb
[3.12] Docs: Add missing markup to Argument Clinic docs (GH-106876) (#107181)
(cherry picked from commit ff5f94b72c)

Co-authored-by: Erlend E. Aasland <erlend@python.org>
Co-authored-by: Ezio Melotti <ezio.melotti@gmail.com>
Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
2023-07-24 15:32:51 +00:00
Miss Islington (bot)
4fd576478c
[3.12] Fix PyVectorcall_Function doc versionadded (GH-107140) (#107173)
Fix PyVectorcall_Function doc versionadded (GH-107140)

The documentation implies that PyVectorcall_Function() was available in Python 3.8.
This is half-true - it was available under a different name. I think it's clearer to set
the "version added" to 3.9.
(cherry picked from commit 0a9b339363)

Co-authored-by: da-woods <dw-git@d-woods.co.uk>
2023-07-24 13:06:16 +00:00
Miss Islington (bot)
03271069af
[3.12] Docs: Remove duplicate word in Argument Clinic howto heading (GH-107169) (#107171)
(cherry picked from commit ebe44a5155)

Co-authored-by: Hakan Celik <hakancelikdev@gmail.com>
2023-07-24 12:03:01 +00:00
Miss Islington (bot)
84c5676e91
[3.12] gh-105291: Add link to migration guide for distutils (GH-107130) (#107160)
Co-authored-by: cLupus <cLupus@users.noreply.github.com>
Co-authored-by: Shantanu <12621235+hauntsaninja@users.noreply.github.com>
2023-07-23 15:00:51 -07:00
Miss Islington (bot)
40a337fbaa
[3.12] gh-106948: Docs: Disable links for C standard library functions, OS utility functions and system calls (GH-107062) (#107154)
(cherry picked from commit b447e19e72)

Co-authored-by: Erlend E. Aasland <erlend@python.org>
Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
2023-07-23 23:13:23 +02:00
Miss Islington (bot)
e02ddb33ce
[3.12] gh-107017: Analolgy to Pascal and C replaced. (GH-107025) (#107124)
(cherry picked from commit e59da0c4f2)

Co-authored-by: TommyUnreal <45427816+TommyUnreal@users.noreply.github.com>
Co-authored-by: Shantanu <12621235+hauntsaninja@users.noreply.github.com>
2023-07-23 13:59:50 +00:00
Miss Islington (bot)
95a82dcbe7
[3.12] gh-107091: Fix the use of some C domain roles (GH-107092) (GH-107113)
(cherry picked from commit 08a228da05)

Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
2023-07-23 14:50:21 +03:00
Moritz Neeb
074fcf15fa
[3.12] gh-106969: Indicate no modules were added in 3.10 & 3.12 (GH-106988) (#107094)
The "New Modules" section was left in place to ensure that the anchor
link for new modules will still exist:

/whatsnew/3.12.htmlGH-new-modules
/whatsnew/3.10.htmlGH-new-modules

This means that existing links to this section don't break.
(cherry picked from commit 6dbffaed17)

Co-authored-by: Sebastiaan Zeeff <33516116+SebastiaanZ@users.noreply.github.com>
2023-07-23 12:26:05 +02:00
Daniele Procida
f7e13002ff
[3.12] gh-106996: Add the basics of a turtle graphics tutorial (GH-107072) (#107109) 2023-07-23 04:22:05 -06:00
Miss Islington (bot)
332db37835
[3.12] gh-101100: Fix some broken sphinx references (GH-107095) (#107103)
(cherry picked from commit f5147c0cfb)

Co-authored-by: wulmer <wulmer@users.noreply.github.com>
2023-07-23 12:00:31 +02:00
Miss Islington (bot)
a73d5c5e2e
[3.12] gh-106976: alphabetise bullets by module name task2-3 (GH-107005) (#107106)
Co-authored-by: littlebutt's workshop <luogan199686@gmail.com>
Co-authored-by: Hugo van Kemenade <hugovk@users.noreply.github.com>
2023-07-23 09:44:39 +00:00
Miss Islington (bot)
63ae7edd35
[3.12] gh-54738: Add argparse i18n howto (GH-104562) (#107102)
(cherry picked from commit dcd7acb04a)

Co-authored-by: Tomas R <tomas.roun8@gmail.com>
2023-07-23 11:36:10 +02:00
Sviatoslav Sydorenko
1703262c0a
[3.12] Convert doc.yml workflow to be reusable (GH-103914 + GH-105151) (#107042)
Co-authored-by: Sviatoslav Sydorenko <wk.cvs.github@sydorenko.org.ua>
Co-authored-by: Adam Turner <9087854+AA-Turner@users.noreply.github.com>
Co-authored-by: Hugo van Kemenade <hugovk@users.noreply.github.com>

(cherry picked from commit 88d14da76f)
(cherry picked from commit eaa6702280)
2023-07-23 11:35:17 +02:00
Serhiy Storchaka
456cf8b097
[3.12] gh-106948: Add standard external names to nitpick_ignore (GH-106949) (#107060)
* [3.12] gh-106948: Add standard external names to nitpick_ignore (GH-106949)

It includes standard C types, macros and variables like "size_t",
"LONG_MAX" and "errno", and standard environment variables like "PATH".

(cherry picked from commit f8b7fe2f26)

Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>

* Delete 2023-05-31-18-37-57.gh-issue-105156.R4El5V.rst
2023-07-23 11:24:51 +02:00
Miss Islington (bot)
98626c3c71
[3.12] gh-107017: removed mention that C does it the same way (GH-107020) (#107097)
Co-authored-by: Jakub Červinka <cervinka.jakub.1989@gmail.com>
2023-07-23 03:11:26 -06:00
Miss Islington (bot)
a80721b83d
[3.12] gh-71261: Add paragraph on shadowing submodules with star imports (GH-107004) (#107100)
Co-authored-by: wulmer <wulmer@users.noreply.github.com>
2023-07-23 09:01:24 +00:00
Miss Islington (bot)
52804b3801
[3.12] gh-102111: Add link to string escape sequences in re module (GH-106995) (#107096)
Co-authored-by: wulmer <wulmer@users.noreply.github.com>
Co-authored-by: Alex Waygood <Alex.Waygood@Gmail.com>
2023-07-23 02:59:16 -06:00
Miss Islington (bot)
bd907dcc50
gh-106847: Add -X warn_default_encoding in sys.flags Doc (GH-106854)
gh-106847: Add -X warn_default_encoding in sys.flags Doc (GH-106854)
(cherry picked from commit fd84ac0ee0)

Co-authored-by: qqwqqw689 <114795525+qqwqqw689@users.noreply.github.com>
Co-authored-by: Nikita Sobolev <mail@sobolevn.me>
2023-07-23 06:15:19 +09:00
Miss Islington (bot)
dd431d791f
[3.12] gh-107028: tiny textual changes in logging docs and docstrings (GH-107029) (GH-107065)
(cherry picked from commit 5e5a34ac3a)
2023-07-22 22:11:29 +01:00
Miss Islington (bot)
0fff068181
[3.12] gh-83006: Document behavior of shutil.disk_usage for non-mounted filesystems on Unix (GH-107031) (#107047)
(cherry picked from commit 6e5f2235f3)

Co-authored-by: Matthieu Caneill <matthieucan@users.noreply.github.com>
2023-07-22 20:25:03 +02:00
Miss Islington (bot)
3889d39471
[3.12] gh-107008: Document the curses module variables LINES and COLS (GH-107011) (GH-107057)
LINES and COLS referred in curses.update_lines_cols() documentations are
the module variables, not the environment variables.
(cherry picked from commit 26e08dfdd7)

Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
2023-07-22 21:12:58 +03:00
Miss Islington (bot)
844bdce712
[3.12] Fix Sphinx warnings in re module docs (GH-107044) (#107046)
Fix Sphinx warnings in `re` module docs (GH-107044)
(cherry picked from commit 149748ea4f)

Co-authored-by: wulmer <wulmer@users.noreply.github.com>
2023-07-22 16:54:02 +01:00
Miss Islington (bot)
c8a0296901
[3.12] gh-105090: Replace incorrect TLSv1.2 with TLSv1.3 (GH-105404) (#107040)
Co-authored-by: Jocelyn Castellano <admin@malwarefight.gq>
2023-07-22 14:30:28 +00:00
Miss Islington (bot)
e7757ab9e1
[3.12] Reformat code block to make it easier to read (GH-106965) (#107010)
(cherry picked from commit ed491d9f78)

Co-authored-by: Joe Kaufeld <opensource@joekaufeld.com>
2023-07-22 14:54:13 +02:00
Miss Islington (bot)
9cbde7c6ce
[3.12] gh-106973: Change non-integral to non-integer in "3.12 What's New" (GH-106984) (#106986)
Co-authored-by: Sebastiaan Zeeff <33516116+SebastiaanZ@users.noreply.github.com>
2023-07-22 02:40:37 -06:00
Serhiy Storchaka
ffc7678f46
[3.12] gh-106892: Use roles :data: and :const: for referencing module variables (GH-106894) (GH-106954)
(cherry picked from commit d036db728e)
2023-07-21 14:51:00 +03:00
Serhiy Storchaka
84e52171b5
[3.12] gh-106909: Use role :const: for referencing module constants (GH-106910) (GH-106956)
(cherry picked from commit 4b9948617f)
2023-07-21 14:49:39 +03:00
Serhiy Storchaka
ac9aa8a369
[3.12] gh-106919: Use role :c:macro: for referencing the C "constants" (GH-106920) (GH-106951)
(cherry picked from commit fcc816dbff)
2023-07-21 14:48:15 +03:00
Miss Islington (bot)
1a3766bb3e
[3.12] Docs: Argument Clinic: Add Background and Tutorial top-level sections (GH-106904) (#106945)
Docs: Argument Clinic: Add Background and Tutorial top-level sections (GH-106904)

Add Background as a toplevel section with the following subsections:

- Background
  - The goals of Argument Clinic
  - Basic concepts and usage

Rename "Converting your first function" to Tutorial.

Add anchors for Background, Tutorial, and How-to Guides:

- :ref:`clinic-background`
- :ref:`clinic-tutorial`
- :ref:`clinic-howtos`

Link to these from within the Abstract.

Break the compatibility paragraph out of Abstract and make it a note.
(cherry picked from commit 81861fd90b)

Co-authored-by: Erlend E. Aasland <erlend@python.org>
Co-authored-by: Ezio Melotti <ezio.melotti@gmail.com>
2023-07-21 08:18:18 +02:00
Gregory P. Smith
656f62454b
[3.12] gh-106669: Revert "gh-102988: Detect email address parsing errors ... (GH-105127)" (GH-106733) (#106941)
This reverts commit 18dfbd0357.
Adds a regression test from the issue.

See https://github.com/python/cpython/issues/106669..
(cherry picked from commit a31dea1feb)
2023-07-21 04:05:46 +00:00