summaryrefslogtreecommitdiffstats
path: root/Doc/howto
Commit message (Collapse)AuthorAgeFilesLines
* [3.12] gh-101100: Fix references to ``URLError`` and ``HTTPError`` in ↵Miss Islington (bot)2023-09-291-8/+8
| | | | | | | | | ``howto/urllib2.rst`` (GH-107966) (#110086) gh-101100: Fix references to ``URLError`` and ``HTTPError`` in ``howto/urllib2.rst`` (GH-107966) (cherry picked from commit bfd94ab9e9f4055ecedaa500b46b0270da9ffe12) Co-authored-by: Yuki K <drsuaimqjgar@gmail.com> Co-authored-by: Hugo van Kemenade <hugovk@users.noreply.github.com>
* [3.12] gh-109634: Use :samp: role (GH-109635) (#109776)Miss Islington (bot)2023-09-242-3/+3
| | | | | | gh-109634: Use :samp: role (GH-109635) (cherry picked from commit 92af0cc580051fd1129c7a86af2cbadeb2aa36dc) Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
* [3.12] gh-108682: [Enum] raise TypeError if super().__new__ called in custom ↵Miss Islington (bot)2023-08-311-1/+22
| | | | | | | | | | | | | | | | __new__ (GH-108704) (#108733) gh-108682: [Enum] raise TypeError if super().__new__ called in custom __new__ (GH-108704) When overriding the `__new__` method of an enum, the underlying data type should be created directly; i.e. . member = object.__new__(cls) member = int.__new__(cls, value) member = str.__new__(cls, value) Calling `super().__new__()` finds the lookup version of `Enum.__new__`, and will now raise an exception when detected. (cherry picked from commit d48760b2f1e28dd3c1a35721939f400a8ab619b8) Co-authored-by: Ethan Furman <ethan@stoneleaf.us>
* [3.12] gh-101100: Fix Sphinx warnings in the Logging Cookbook (GH-108678) ↵Miss Islington (bot)2023-08-301-4/+11
| | | | | | | | (#108680) gh-101100: Fix Sphinx warnings in the Logging Cookbook (GH-108678) (cherry picked from commit c7cef546319c51defa01236469b636b6978b99ab) Co-authored-by: Hugo van Kemenade <hugovk@users.noreply.github.com>
* [3.12] gh-107432 Update Porting Python 2 Code to Python 3 how-to (GH-107434) ↵Miss Islington (bot)2023-08-241-121/+94
| | | | | | | | | | | | | (#108409) gh-107432 Update Porting Python 2 Code to Python 3 how-to (GH-107434) https://docs.python.org/3/howto/pyporting.htmlGH-porting-python-2-code-to-python-3 was written for another time. In this patch: - material that frames Python 3 as "new" is removed - descriptions and directions have been trimmed (cherry picked from commit 809ea7c4b6c2b818ae510f1f58e82b6b05ed4ef9) Co-authored-by: Daniele Procida <daniele@vurt.org>
* [3.12] docs: fix grammar in isolating-extensions.rst (GH-108037) (#108218)Miss Islington (bot)2023-08-211-1/+1
| | | | | | docs: fix grammar in isolating-extensions.rst (GH-108037) (cherry picked from commit 47022a079eb9d2a2af781abae3de4a71f80247c2) Co-authored-by: David Lechner <david@pybricks.com>
* [3.12] Docs: Argument Clinic: Move the CConverter class to the reference ↵Miss Islington (bot)2023-08-071-64/+69
| | | | | | | | (GH-107671) (#107701) Docs: Argument Clinic: Move the CConverter class to the reference (GH-107671) (cherry picked from commit a6675b1a597c67be972598ac8562883fabe48099) Co-authored-by: Erlend E. Aasland <erlend@python.org>
* [3.12] Docs: Argument Clinic: Improve 'How to write a custom converter' ↵Miss Islington (bot)2023-08-061-24/+26
| | | | | | | | | | | | | (GH-107328) (#107669) Docs: Argument Clinic: Improve 'How to write a custom converter' (GH-107328) - Omit unneccesary wording and sentences - Don't mention implementation details (no digression, explanation) (cherry picked from commit 4a5b4221e381c541f3f73537b7b87580d100158b) Co-authored-by: Erlend E. Aasland <erlend@python.org> Co-authored-by: Ezio Melotti <ezio.melotti@gmail.com>
* [3.12] gh-107432 Fix incorrect indentation in annotations HOWTO (GH-107445) ↵Miss Islington (bot)2023-08-051-163/+163
| | | | | | | | | | | | | (#107654) gh-107432 Fix incorrect indentation in annotations HOWTO (GH-107445) gh-107432 Fix incorrect indentation in annotations document Body text in https://docs.python.org/3/howto/annotations.html was indented throughout, and was being rendered in blockquote elements. (cherry picked from commit 5e2746d6e2fb0da29225ead7135f078c5f087b57) Co-authored-by: Daniele Procida <daniele@vurt.org>
* [3.12] gh-107306: Add a Doc Entry for Py_mod_multiple_interpreters ↵Miss Islington (bot)2023-07-311-0/+2
| | | | | | | | | | (GH-107403) (gh-107521) gh-107306: Add a Doc Entry for Py_mod_multiple_interpreters (GH-107403) It was added in 3.12 for PEP 684 (per-interpreter GIL). (cherry picked from commit fb344e99aa0da5bef9318684ade69978585fe060) Co-authored-by: Eric Snow <ericsnowcurrently@gmail.com>
* [3.12] gh-107507: Replace 'The goals of Argument Clinic' with a summary ↵Miss Islington (bot)2023-07-311-54/+4
| | | | | | | | | (GH-107508) (#107516) Summarise the goals of Argument Clinic in a single sentence. Mention that Argument Clinic was introduced with PEP-436. (cherry picked from commit abb71c6a8f73482c910ffdf050a86089a48e0e60) Co-authored-by: Erlend E. Aasland <erlend@python.org>
* [3.12] gh-101100: Sphinx warnings: pick the low hanging fruits (GH-107386) ↵Serhiy Storchaka2023-07-291-1/+1
| | | | | (GH-107419) (cherry picked from commit f2d07d3289947d10b065b2bb7670c8fb6b6582f2)
* [3.12] gh-107298: Fix yet more Sphinx warnings in the C API doc (GH-107345) ↵Serhiy Storchaka2023-07-281-5/+5
| | | | | (GH-107380) (cherry picked from commit 983305268e2291b0a7835621b81bf40cba7c27f3)
* [3.12] Docs: Argument Clinic: Restructure "Basic concepts and usage" ↵Miss Islington (bot)2023-07-271-43/+129
| | | | | | | | | | | | | | | | | | | (GH-106981) (#107325) Split "Basic concepts and usage" into: - Reference - Terminology - CLI reference - Background - Basic concepts (cherry picked from commit 2ad699002e3ce09e9fa41e333ac72f16a32d94de) 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>
* [3.12] Docs: Remove the numbered steps from the Argument Clinic tutorial ↵Miss Islington (bot)2023-07-261-314/+310
| | | | | | | | | | (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 592395577c679543d899e68a3cff538b8b4df80d) Co-authored-by: Erlend E. Aasland <erlend@python.org>
* [3.12] gh-107091: Fix some uses of :c:member: role (GH-107129) (GH-107310)Miss Islington (bot)2023-07-261-1/+1
| | | | | (cherry picked from commit af61cb9c7837ff3c11da79e3ee1cab3fdd0ba4da) Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
* [3.12] Docs: Add missing markup to Argument Clinic docs (GH-106876) (#107181)Miss Islington (bot)2023-07-241-126/+143
| | | | | | | (cherry picked from commit ff5f94b72c8aad8e45c397c263dbe7f19221735f) 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>
* [3.12] Docs: Remove duplicate word in Argument Clinic howto heading ↵Miss Islington (bot)2023-07-241-2/+2
| | | | | | | (GH-107169) (#107171) (cherry picked from commit ebe44a5155e9abc70c4b8914ad26b27c2b84f72b) Co-authored-by: Hakan Celik <hakancelikdev@gmail.com>
* [3.12] gh-106948: Docs: Disable links for C standard library functions, OS ↵Miss Islington (bot)2023-07-231-3/+3
| | | | | | | | utility functions and system calls (GH-107062) (#107154) (cherry picked from commit b447e19e720e6781025432a40eb72b1cc93ac944) Co-authored-by: Erlend E. Aasland <erlend@python.org> Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
* [3.12] gh-107091: Fix the use of some C domain roles (GH-107092) (GH-107113)Miss Islington (bot)2023-07-231-2/+2
| | | | | (cherry picked from commit 08a228da05a7aec937b65eea21f4091fa3c6b5cf) Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
* [3.12] gh-101100: Fix some broken sphinx references (GH-107095) (#107103)Miss Islington (bot)2023-07-234-9/+11
| | | | | (cherry picked from commit f5147c0cfbd7943ff10917225448c36a53f9828d) Co-authored-by: wulmer <wulmer@users.noreply.github.com>
* [3.12] gh-54738: Add argparse i18n howto (GH-104562) (#107102)Miss Islington (bot)2023-07-231-0/+53
| | | | | (cherry picked from commit dcd7acb04a719d8d30c8d03b80d3d48b6c035e14) Co-authored-by: Tomas R <tomas.roun8@gmail.com>
* [3.12] gh-106919: Use role :c:macro: for referencing the C "constants" ↵Serhiy Storchaka2023-07-211-5/+5
| | | | | (GH-106920) (GH-106951) (cherry picked from commit fcc816dbff7ca66c26f57a506e4d2330fe41d0ff)
* [3.12] Docs: Argument Clinic: Add Background and Tutorial top-level sections ↵Miss Islington (bot)2023-07-211-9/+27
| | | | | | | | | | | | | | | | | | | | | | | | | | | (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 81861fd90b4ae981e7881cd03a3c370713063525) Co-authored-by: Erlend E. Aasland <erlend@python.org> Co-authored-by: Ezio Melotti <ezio.melotti@gmail.com>
* [3.12] Docs: Argument Clinic: Group guides about default values (GH-106872) ↵Miss Islington (bot)2023-07-181-20/+20
| | | | | | | | | | | | | | | | | | | | | | | | (#106874) Docs: Argument Clinic: Group guides about default values (GH-106872) Previous ToC layout (excerpt): - How to use symbolic default values ... - How to assign default values to parameter - How to use the ``NULL`` default value - How to use expressions as default values New layout: - How to assign default values to parameter - The ``NULL`` default value - Symbolic default values - Expressions as default values (cherry picked from commit 505eede38d141d43e40e246319b157e3c77211d3) Co-authored-by: Erlend E. Aasland <erlend@python.org>
* [3.12] Docs: Normalise Argument Clinic advanced topics headings (GH-106842) ↵Miss Islington (bot)2023-07-181-49/+46
| | | | | | | | (#106853) (cherry picked from commit 4cb0b9c0a9f6a4154238c98013d2679229b1f794) Co-authored-by: Erlend E. Aasland <erlend@python.org> Co-authored-by: Ezio Melotti <ezio.melotti@gmail.com>
* [3.12] Docs: Normalize Argument Clinic How-To section capitalization ↵Miss Islington (bot)2023-07-151-11/+18
| | | | | | | (GH-106788) (#106791) (cherry picked from commit 8c177294899b621fe04ae755abd41b4d319dd4b5) Co-authored-by: Erlend E. Aasland <erlend@python.org>
* [3.12] gh-105332: [Enum] Fix unpickling flags in edge-cases (GH-105348) ↵Miss Islington (bot)2023-06-091-1/+10
| | | | | | | | | | (GH-105520) * revert enum pickling from by-name to by-value (cherry picked from commit 4ff5690e591b7d11cf11e34bf61004e2ea58ab3c) Co-authored-by: Nikita Sobolev <mail@sobolevn.me> Co-authored-by: Ethan Furman <ethan@stoneleaf.us>
* [3.12] gh-102304: doc: Add links to Stable ABI and Limited C API (#105345) ↵Victor Stinner2023-06-061-1/+1
| | | | | | | | | | | | | | | | | | | (#105371) * gh-102304: doc: Add links to Stable ABI and Limited C API (#105345) * Add "limited-c-api" and "stable-api" references. * Rename "stable-abi-list" reference to "limited-api-list". * Makefile: Document files regenerated by "make regen-limited-abi" * Remove first empty line in generated files: - Lib/test/test_stable_abi_ctypes.py - PC/python3dll.c (cherry picked from commit bae415ad02c79cf3a2eec4aa6969221a12e6716f) * gh-102304: Fix up Simple ABI doc (GH-105351) (cherry picked from commit 0202aa002e06acef9aa55ace0d939103df19cadd)
* [3.12] howto/urllib2: remove link to an outdated french translation ↵Miss Islington (bot)2023-05-231-7/+0
| | | | | | | | (GH-104193) (#104758) We now have our own translation and it's not outdated (cherry picked from commit 151b6bfb5d9a15b6e2682e5a3008a3f9ec3086ae) Co-authored-by: Mathieu Dupuy <deronnax@gmail.com>
* gh-103295: expose API for writing perf map files (#103546)gsallam2023-05-211-3/+1
| | | | | Co-authored-by: Aniket Panse <aniketpanse@fb.com> Co-authored-by: Gregory P. Smith <greg@krypto.org> Co-authored-by: Carl Meyer <carl@oddbird.net>
* gh-104389: Add 'unused' keyword to Argument Clinic C converters (#104390)Erlend E. Aasland2023-05-121-0/+3
| | | | | | | | | Use the unused keyword param in the converter to explicitly mark an argument as unused: /*[clinic input] SomeBaseClass.stubmethod flag: bool(unused=True) [clinic start generated code]*/
* gh-103960: Dark mode: invert image brightness (#103983)Hugo van Kemenade2023-05-101-0/+1
|
* gh-64658: Expand Argument Clinic return converter docs (#104175)Erlend E. Aasland2023-05-051-13/+28
|
* gh-101100: Fix Sphinx warnings in `curses` and `curses.ascii` modules (#103457)Hugo van Kemenade2023-05-031-21/+23
| | | | Co-authored-by: Shantanu <12621235+hauntsaninja@users.noreply.github.com>
* GH-103484: Fix redirected permanently URLs (#104001)Rafael Fontenelle2023-05-021-1/+1
| | | | | Co-authored-by: Hugo van Kemenade <hugovk@users.noreply.github.com> Co-authored-by: Oleg Iarygin <dralife@yandex.ru>
* gh-101100: Fix Sphinx warnings in `argparse` module (#103289)Hugo van Kemenade2023-04-241-7/+9
| | | | | Co-authored-by: C.A.M. Gerlach <CAM.Gerlach@Gerlach.CAM> Co-authored-by: Ezio Melotti <ezio.melotti@gmail.com>
* GH-103484: Fix broken links reported by linkcheck (#103608)Rafael Fontenelle2023-04-222-4/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | * Doc: Fix broken links reported by linkcheck * Apply suggestions from code review - Remove extra diff line in faq/library.rst (merwok) - Use HTTPS to link Unicode 15.0.0 to solve a redirect (hugovk) - Use wayback machine link for openssl 1.1.0 instead of linking 1.1.1, "as this text mentions a feature from 1.1.0" (hugovk) Co-authored-by: Éric <merwok@netwok.org> Co-authored-by: Hugo van Kemenade <hugovk@users.noreply.github.com> * Doc: Make mark-up code as literal * Doc: Alphabetize items in linkcheck_ignore Co-authored-by: Hugo van Kemenade <hugovk@users.noreply.github.com> * Doc: Improve comment in sphinx conf Co-authored-by: Adam Turner <9087854+AA-Turner@users.noreply.github.com> --------- Co-authored-by: Éric <merwok@netwok.org> Co-authored-by: Hugo van Kemenade <hugovk@users.noreply.github.com> Co-authored-by: Adam Turner <9087854+AA-Turner@users.noreply.github.com>
* Descriptor HowTo: Update to include attributes added in Python 3.10 ↵Raymond Hettinger2023-04-221-8/+90
| | | | (GH-103666)
* gh-103596: [Enum] do not shadow mixed-in methods/attributes (GH-103600)Ethan Furman2023-04-181-3/+11
| | | | | | | | | | | | | | | | | | For example: class Book(StrEnum): title = auto() author = auto() desc = auto() Book.author.desc is Book.desc but Book.author.title() == 'Author' is commonly expected. Using upper-case member names avoids this confusion and possible performance impacts. Co-authored-by: samypr100 <3933065+samypr100@users.noreply.github.com>
* Fix syntax typo in isolating extensions doc (#103516)AN Long2023-04-141-3/+3
|
* Proofread howto/perf_profiling.rst (#103530)Boris Verkhovskiy2023-04-141-10/+10
|
* gh-103479: [Enum] require __new__ to be considered a data type (GH-103495)Ethan Furman2023-04-131-3/+5
| | | a mixin must either have a __new__ method, or be a dataclass, to be interpreted as a data-type
* gh-93910: [Enum] remove member.member deprecation (GH-103236)Ethan Furman2023-04-061-4/+3
| | | | i.e. Color.RED.BLUE is now officially supported.
* gh-103056: [Enum] use staticmethod decorator for _gnv_ (GH-103231)Ethan Furman2023-04-041-0/+1
| | | _gnv_ --> _generate_next_value_
* gh-98298, gh-74730: [Enum] update docs (GH-103163)Ethan Furman2023-04-031-0/+5
| | | | fix FlagBoundary statements add warning about reloading modules and enum identity
* gh-102582: Fix invalid JSON in Doc/howto/logging-cookbook.rst (GH-102635)Matěj Cepl2023-03-291-10/+14
|
* [doc] Improve grammar/fix missing word (GH-102060)VMan2023-02-261-1/+1
|
* gh-101440: fix json snippet error in logging-cookbook.rst (#101439)Peter Jiping Xie2023-01-311-1/+1
|
* gh-101386: fix typos found by codespell (#101387)Peter Jiping Xie2023-01-281-2/+2
|