Keep the page though, because people might still rely on it (the traffic shows that they do).
Instead of our own manual we now give links to the 3rd-party ones.
(cherry picked from commit 705c76d4a2)
Co-authored-by: Nikita Sobolev <mail@sobolevn.me>
Co-authored-by: Hugo van Kemenade <1324225+hugovk@users.noreply.github.com>
Also add more tests for LoggerAdapter.
Also support stacklevel in LoggerAdapter._log().
(cherry picked from commit 225856ef3e)
(cherry picked from commit 91822018ee)
Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
gh-113625: Align object addresses in the Descriptor HowTo Guide (GH-113894)
(cherry picked from commit 901a971e16)
Co-authored-by: Raymond Hettinger <rhettinger@users.noreply.github.com>
gh-110812: Isolating Extension Modules HOWTO: List GC-related gotchas (GH-111504)
(cherry picked from commit 985679f05d)
Co-authored-by: Petr Viktorin <encukou@gmail.com>
Co-authored-by: Hugo van Kemenade <hugovk@users.noreply.github.com>
Co-authored-by: Eric Snow <ericsnowcurrently@gmail.com>
gh-111895: Convert definition list to bullet list for readability on mobile (GH-111898)
Convert definition list to bullet list for readability on mobile
(cherry picked from commit 7d21e3d5ee)
Co-authored-by: Hugo van Kemenade <hugovk@users.noreply.github.com>
gh-111724: Fix doctest `ResourceWarning` in `howto/descriptor.rst` (GH-111725)
Close database connection explicitly in test cleanup.
(cherry picked from commit f48e669504)
Co-authored-by: Nikita Sobolev <mail@sobolevn.me>
(cherry picked from commit d1f7fae424)
* Remove the content of the Argument Clinic HOWTO
* Update cross-references to the Argument Clinic
* Add a note directing readers to the devguide
Co-authored-by: Adam Turner <9087854+AA-Turner@users.noreply.github.com>
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 d48760b2f1)
https://docs.python.org/3/howto/pyporting.html 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 809ea7c4b6)
Co-authored-by: Daniele Procida <daniele@vurt.org>
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 5e2746d6e2)
Co-authored-by: Daniele Procida <daniele@vurt.org>
Summarise the goals of Argument Clinic in a single sentence.
Mention that Argument Clinic was introduced with PEP-436.
(cherry picked from commit abb71c6a8f)
Co-authored-by: Erlend E. Aasland <erlend@python.org>
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)
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>
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 505eede38d)
Co-authored-by: Erlend E. Aasland <erlend@python.org>
howto/urllib2: remove link to an outdated french translation (GH-104193)
We now have our own translation and it's not outdated
(cherry picked from commit 151b6bfb5d)
Co-authored-by: Mathieu Dupuy <deronnax@gmail.com>