8000 gh-101100: Fix Sphinx warnings for removed dead batteries (#113669) · python/cpython@fab7ad6 · GitHub
[go: up one dir, main page]

Skip to content

Commit fab7ad6

Browse files
hugovkAlexWaygood
andauthored
gh-101100: Fix Sphinx warnings for removed dead batteries (#113669)
Co-authored-by: Alex Waygood <Alex.Waygood@Gmail.com>
1 parent 4de468c commit fab7ad6

19 files changed

+53
-53
lines changed

Doc/whatsnew/2.4.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -995,7 +995,7 @@ fixes. Here's a partial list of the most notable changes, sorted alphabetically
995995
by module name. Consult the :file:`Misc/NEWS` file in the source tree for a more
996996
complete list of changes, or look through the CVS logs for all the details.
997997

998-
* The :mod:`asyncore` module's :func:`loop` function now has a *count* parameter
998+
* The :mod:`!asyncore` module's :func:`!loop` function now has a *count* parameter
999999
that lets you perform a limited number of passes through the polling loop. The
10001000
default is still to loop forever.
10011001

Doc/whatsnew/2.6.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1789,7 +1789,7 @@ changes, sorted alphabetically by module name. Consult the
17891789
:file:`Misc/NEWS` file in the source tree for a more complete list of
17901790
changes, or look through the Subversion logs for all the details.
17911791

1792-
* The :mod:`asyncore` and :mod:`asynchat` modules are
1792+
* The :mod:`!asyncore` and :mod:`!asynchat` modules are
17931793
being actively maintained again, and a number of patches and bugfixes
17941794
were applied. (Maintained by Josiah Carlson; see :issue:`1736190` for
17951795
one patch.)

Doc/whatsnew/3.10.rst

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1278,7 +1278,7 @@ Add negative indexing support to :attr:`PurePath.parents
12781278
(Contributed by Yaroslav Pankovych in :issue:`21041`.)
12791279
12801280
Add :meth:`Path.hardlink_to <pathlib.Path.hardlink_to>` method that
1281-
supersedes :meth:`~pathlib.Path.link_to`. The new method has the same argument
1281+
supersedes :meth:`!link_to`. The new method has the same argument
12821282
order as :meth:`~pathlib.Path.symlink_to`.
12831283
(Contributed by Barney Gale in :issue:`39950`.)
12841284
@@ -1740,7 +1740,7 @@ Deprecated
17401740
17411741
(Contributed by Jelle Zijlstra in :gh:`87889`.)
17421742
1743-
* :meth:`pathlib.Path.link_to` is deprecated and slated for removal in
1743+
* :meth:`!pathlib.Path.link_to` is deprecated and slated for removal in
17441744
Python 3.12. Use :meth:`pathlib.Path.hardlink_to` instead.
17451745
(Contributed by Barney Gale in :issue:`39950`.)
17461746
@@ -1771,7 +1771,7 @@ Deprecated
17711771
* NPN features like :meth:`ssl.SSLSocket.selected_npn_protocol` and
17721772
:meth:`ssl.SSLContext.set_npn_protocols` are replaced by ALPN.
17731773
1774-
* The threading debug (:envvar:`PYTHONTHREADDEBUG` environment variable) is
1774+
* The threading debug (:envvar:`!PYTHONTHREADDEBUG` environment variable) is
17751775
deprecated in Python 3.10 and will be removed in Python 3.12. This feature
17761776
requires a :ref:`debug build of Python <debug-build>`.
17771777
(Contributed by Victor Stinner in :issue:`44584`.)

Doc/whatsnew/3.11.rst

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1747,7 +1747,7 @@ Modules
17471747
(Contributed by Brett Cannon in :issue:`47061` and Victor Stinner in
17481748
:gh:`68966`.)
17491749

1750-
* The :mod:`asynchat`, :mod:`asyncore` and :mod:`smtpd` modules have been
1750+
* The :mod:`!asynchat`, :mod:`!asyncore` and :mod:`!smtpd` modules have been
17511751
deprecated since at least Python 3.6. Their documentation and deprecation
17521752
warnings have now been updated to note they will be removed in Python 3.12.
17531753
(Contributed by Hugo van Kemenade in :issue:`47022`.)
@@ -1877,8 +1877,8 @@ and will be removed in Python 3.12.
18771877
C APIs pending removal are
18781878
:ref:`listed separately <whatsnew311-c-api-pending-removal>`.
18791879

1880-
* The :mod:`asynchat` module
1881-
* The :mod:`asyncore` module
1880+
* The :mod:`!asynchat` module
1881+
* The :mod:`!asyncore` module
18821882
* The :ref:`entire distutils package <distutils-deprecated>`
18831883
* The :mod:`!imp` module
18841884
* The :class:`typing.io <typing.IO>` namespace
@@ -1902,10 +1902,10 @@ C APIs pending removal are
19021902
* :func:`!importlib.util.set_package_wrapper`
19031903
* :class:`!pkgutil.ImpImporter`
19041904
* :class:`!pkgutil.ImpLoader`
1905-
* :meth:`pathlib.Path.link_to`
1905+
* :meth:`!pathlib.Path.link_to`
19061906
* :func:`!sqlite3.enable_shared_cache`
19071907
* :func:`!sqlite3.OptimizedUnicode`
1908-
* :envvar:`PYTHONTHREADDEBUG` environment variable
1908+
* :envvar:`!PYTHONTHREADDEBUG` environment variable
19091909
* The following deprecated aliases in :mod:`unittest`:
19101910

19111911
============================ =============================== ===============
@@ -2007,7 +2007,7 @@ Removed C APIs are :ref:`listed separately <whatsnew311-c-api-removed>`.
20072007
because it was not used and added by mistake in previous versions.
20082008
(Contributed by Nikita Sobolev in :issue:`46483`.)
20092009

2010-
* Removed the :class:`!MailmanProxy` class in the :mod:`smtpd` module,
2010+
* Removed the :class:`!MailmanProxy` class in the :mod:`!smtpd` module,
20112011
as it is unusable without the external :mod:`!mailman` package.
20122012
(Contributed by Donghee Na in :issue:`35800`.)
20132013

Doc/whatsnew/3.2.rst

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1858,12 +1858,12 @@ structure.
18581858
asyncore
18591859
--------
18601860

1861-
:class:`asyncore.dispatcher` now provides a
1862-
:meth:`~asyncore.dispatcher.handle_accepted()` method
1861+
:class:`!asyncore.dispatcher` now provides a
1862+
:meth:`!handle_accepted()` method
18631863
returning a ``(sock, addr)`` pair which is called when a connection has actually
18641864
been established with a new remote endpoint. This is supposed to be used as a
1865-
replacement for old :meth:`~asyncore.dispatcher.handle_accept()` and avoids
1866-
the user to call :meth:`~asyncore.dispatcher.accept()` directly.
1865+
replacement for old :meth:`!handle_accept()` and avoids
1866+
the user to call :meth:`!accept()` directly.
18671867

18681868
(Contributed by Giampaolo Rodolà; :issue:`6706`.)
18691869

@@ -2737,8 +2737,8 @@ require changes to your code:
27372737
thread-state aware APIs (such as :c:func:`PyEval_SaveThread`
27382738
and :c:func:`PyEval_RestoreThread`) should be used instead.
27392739

2740-
* Due to security risks, :func:`asyncore.handle_accept` has been deprecated, and
2741-
a new function, :func:`asyncore.handle_accepted`, was added to replace it.
2740+
* Due to security risks, :func:`!asyncore.handle_accept` has been deprecated, and
2741+
a new function, :func:`!asyncore.handle_accepted`, was added to replace it.
27422742

27432743
(Contributed by Giampaolo Rodola in :issue:`6706`.)
27442744

Doc/whatsnew/3.3.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1845,7 +1845,7 @@ signal
18451845
smtpd
18461846
-----
18471847

1848-
The :mod:`smtpd` module now supports :rfc:`5321` (extended SMTP) and :rfc:`1870`
1848+
The :mod:`!smtpd` module now supports :rfc:`5321` (extended SMTP) and :rfc:`1870`
18491849
(size extension). Per the standard, these extensions are enabled if and only
18501850
if the client initiates the session with an ``EHLO`` command.
18511851

Doc/whatsnew/3.4.rst

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1369,9 +1369,9 @@ error. (Contributed by Atsuo Ishimoto and Hynek Schlawack in
13691369
smtpd
13701370
-----
13711371

1372-
The :class:`~smtpd.SMTPServer` and :class:`~smtpd.SMTPChannel` classes now
1372+
The :class:`!SMTPServer` and :class:`!SMTPChannel` classes now
13731373
accept a *map* keyword argument which, if specified, is passed in to
1374-
:class:`asynchat.async_chat` as its *map* argument. This allows an application
1374+
:class:`!asynchat.async_chat` as its *map* argument. This allows an application
13751375
to avoid affecting the global socket map. (Contributed by Vinay Sajip in
13761376
:issue:`11959`.)
13771377

@@ -2370,7 +2370,7 @@ Changes in the Python API
23702370
:issue:`18011`.) Note: this change was also inadvertently applied in Python
23712371
3.3.3.
23722372

2373-
* The :attr:`~cgi.FieldStorage.file` attribute is now automatically closed when
2373+
* The :attr:`!file` attribute is now automatically closed when
23742374
the creating :class:`!cgi.FieldStorage` instance is garbage collected. If you
23752375
were pulling the file object out separately from the :class:`!cgi.FieldStorage`
23762376
instance and not keeping the instance alive, then you should either store the

Doc/whatsnew/3.5.rst

Lines changed: 11 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -878,7 +878,7 @@ size of decompressed data. (Contributed by Nikolaus Rath in :issue:`15955`.)
878878
cgi
879879
---
880880

881-
The :class:`~cgi.FieldStorage` class now supports the :term:`context manager`
881+
The :class:`!FieldStorage` class now supports the :term:`context manager`
882882
protocol. (Contributed by Berker Peksag in :issue:`20289`.)
883883

884884

@@ -1663,34 +1663,34 @@ during debugging, instead of integer "magic numbers".
16631663
smtpd
16641664
-----
16651665

1666-
Both the :class:`~smtpd.SMTPServer` and :class:`~smtpd.SMTPChannel` classes now
1666+
Both the :class:`!SMTPServer` and :class:`!SMTPChannel` classes now
16671667
accept a *decode_data* keyword argument to determine if the ``DATA`` portion of
16681668
the SMTP transaction is decoded using the ``"utf-8"`` codec or is instead
16691669
provided to the
1670-
:meth:`SMTPServer.process_message() <smtpd.SMTPServer.process_message>`
1670+
:meth:`!SMTPServer.process_message()`
16711671
method as a byte string. The default is ``True`` for backward compatibility
16721672
reasons, but will change to ``False`` in Python 3.6. If *decode_data* is set
16731673
to ``False``, the ``process_message`` method must be prepared to accept keyword
16741674
arguments.
16751675
(Contributed by Maciej Szulik in :issue:`19662`.)
16761676

1677-
The :class:`~smtpd.SMTPServer` class now advertises the ``8BITMIME`` extension
1677+
The :class:`!SMTPServer` class now advertises the ``8BITMIME`` extension
16781678
(:rfc:`6152`) if *decode_data* has been set ``True``. If the client
16791679
specifies ``BODY=8BITMIME`` on the ``MAIL`` command, it is passed to
1680-
:meth:`SMTPServer.process_message() <smtpd.SMTPServer.process_message>`
1680+
:meth:`!SMTPServer.process_message()`
16811681
via the *mail_options* keyword.
16821682
(Contributed by Milan Oberkirch and R. David Murray in :issue:`21795`.)
16831683

1684-
The :class:`~smtpd.SMTPServer` class now also supports the ``SMTPUTF8``
1684+
The :class:`!SMTPServer` class now also supports the ``SMTPUTF8``
16851685
extension (:rfc:`6531`: Internationalized Email). If the client specified
16861686
``SMTPUTF8 BODY=8BITMIME`` on the ``MAIL`` command, they are passed to
1687-
:meth:`SMTPServer.process_message() <smtpd.SMTPServer.process_message>`
1687+
:meth:`!SMTPServer.process_message()`
16881688
via the *mail_options* keyword. It is the responsibility of the
16891689
``process_message`` method to correctly handle the ``SMTPUTF8`` data.
16901690
(Contributed by Milan Oberkirch in :issue:`21725`.)
16911691

16921692
It is now possible to provide, directly or via name resolution, IPv6
1693-
addresses in the :class:`~smtpd.SMTPServer` constructor, and have it
1693+
addresses in the :class:`!SMTPServer` constructor, and have it
16941694
successfully connect. (Contributed by Milan Oberkirch in :issue:`14758`.)
16951695

16961696

@@ -1714,7 +1714,7 @@ support :rfc:`6531` (SMTPUTF8).
17141714
sndhdr
17151715
------
17161716

1717-
The :func:`~sndhdr.what` and :func:`~sndhdr.whathdr` functions now return
1717+
The :func:`!what` and :func:`!whathdr` functions now return
17181718
a :func:`~collections.namedtuple`. (Contributed by Claudiu Popa in
17191719
:issue:`18615`.)
17201720

@@ -2296,9 +2296,9 @@ slated for removal in Python 3.6.
22962296
The :func:`asyncio.async` function is deprecated in favor of
22972297
:func:`~asyncio.ensure_future`.
22982298

2299-
The :mod:`smtpd` module has in the past always decoded the DATA portion of
2299+
The :mod:`!smtpd` module has in the past always decoded the DATA portion of
23002300
email messages using the ``utf-8`` codec. This can now be controlled by the
2301-
new *decode_data* keyword to :class:`~smtpd.SMTPServer`. The default value is
2301+
new *decode_data* keyword to :class:`!SMTPServer`. The default value is
23022302
``True``, but this default is deprecated. Specify the *decode_data* keyword
23032303
with an appropriate value to avoid the deprecation warning.
23042304

Doc/whatsnew/3.6.rst

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1961,14 +1961,14 @@ Deprecated Python modules, functions and methods
19611961
asynchat
19621962
~~~~~~~~
19631963

1964-
The :mod:`asynchat` has been deprecated in favor of :mod:`asyncio`.
1964+
The :mod:`!asynchat` has been deprecated in favor of :mod:`asyncio`.
19651965
(Contributed by Mariatta in :issue:`25002`.)
19661966

19671967

19681968
asyncore
19691969
~~~~~~~~
19701970

1971-
The :mod:`asyncore` has been deprecated in favor of :mod:`asyncio`.
1971+
The :mod:`!asyncore` has been deprecated in favor of :mod:`asyncio`.
19721972
(Contributed by Mariatta in :issue:`25002`.)
19731973

19741974

@@ -2189,7 +2189,7 @@ Changes in the Python API
21892189
:mod:`calendar`, :mod:`!cgi`, :mod:`csv`,
21902190
:mod:`~xml.etree.ElementTree`, :mod:`enum`,
21912191
:mod:`fileinput`, :mod:`ftplib`, :mod:`logging`, :mod:`mailbox`,
2192-
:mod:`mimetypes`, :mod:`optparse`, :mod:`plistlib`, :mod:`smtpd`,
2192+
:mod:`mimetypes`, :mod:`optparse`, :mod:`plistlib`, :mod:`!smtpd`,
21932193
:mod:`subprocess`, :mod:`tarfile`, :mod:`threading` and
21942194
:mod:`wave`. This means they will export new symbols when ``import *``
21952195
is used.
@@ -2219,11 +2219,11 @@ Changes in the Python API
22192219
an error (e.g. ``EBADF``) was reported by the underlying system call.
22202220
(Contributed by Martin Panter in :issue:`26685`.)
22212221

2222-
* The *decode_data* argument for the :class:`smtpd.SMTPChannel` and
2223-
:class:`smtpd.SMTPServer` constructors is now ``False`` by default.
2222+
* The *decode_data* argument for the :class:`!smtpd.SMTPChannel` and
2223+
:class:`!smtpd.SMTPServer` constructors is now ``False`` by default.
22242224
This means that the argument passed to
2225-
:meth:`~smtpd.SMTPServer.process_message` is now a bytes object by
2226-
default, and ``process_message()`` will be passed keyword arguments.
2225+
:meth:`!process_message` is now a bytes object by
2226+
default, and :meth:`!process_message` will be passed keyword arguments.
22272227
Code that has already been updated in accordance with the deprecation
22282228
warning generated by 3.5 will not be affected.
22292229

Doc/whatsnew/3.7.rst

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2304,9 +2304,9 @@ Changes in the Python API
23042304
* The :attr:`struct.Struct.format` type is now :class:`str` instead of
23052305
:class:`bytes`. (Contributed by Victor Stinner in :issue:`21071`.)
23062306

2307-
* :func:`~cgi.parse_multipart` now accepts the *encoding* and *errors*
2307+
* :func:`!cgi.parse_multipart` now accepts the *encoding* and *errors*
23082308
arguments and returns the same results as
2309-
:class:`~FieldStorage`: for non-file fields, the value associated to a key
2309+
:class:`!FieldStorage`: for non-file fields, the value associated to a key
23102310
is a list of strings, not bytes.
23112311
(Contributed by Pierre Quentel in :issue:`29979`.)
23122312

Doc/whatsnew/3.8.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1086,7 +1086,7 @@ pathlib
10861086
contain characters unrepresentable at the OS level.
10871087
(Contributed by Serhiy Storchaka in :issue:`33721`.)
10881088

1089-
Added :meth:`pathlib.Path.link_to()` which creates a hard link pointing
1089+
Added :meth:`!pathlib.Path.link_to()` which creates a hard link pointing
10901090
to a path.
10911091
(Contributed by Joannah Nanjekye in :issue:`26978`)
10921092
Note that ``link_to`` was deprecated in 3.10 and removed in 3.12 in

Doc/whatsnew/3.9.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -931,7 +931,7 @@ Deprecated
931931
* Passing ``None`` as the first argument to the :func:`shlex.split` function
932932
has been deprecated. (Contributed by Zackery Spytz in :issue:`33262`.)
933933

934-
* :func:`smtpd.MailmanProxy` is now deprecated as it is unusable without
934+
* :func:`!smtpd.MailmanProxy` is now deprecated as it is unusable without
935935
an external module, ``mailman``. (Contributed by Samuel Colvin in :issue:`35800`.)
936936

937937
* The :mod:`!lib2to3` module now emits a :exc:`PendingDeprecationWarning`.

Misc/NEWS.d/3.10.0a1.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2527,7 +2527,7 @@ in Python 3.4 and removed in Python 3.5.
25272527
.. nonce: BE7zbu
25282528
.. section: Library
25292529
2530-
Fix `cgi.parse_multipart` without content_length. Patch by Roger Duran
2530+
Fix ``cgi.parse_multipart`` without content_length. Patch by Roger Duran
25312531

25322532
..
25332533

Misc/NEWS.d/3.11.0a1.rst

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -819,7 +819,7 @@ always available when needed. Patch by Mark Shannon.
819819
.. nonce: qKnSqV
820820
.. section: Core and Builtins
821821

822-
The threading debug (:envvar:`PYTHONTHREADDEBUG` environment variable) is
822+
The threading debug (:envvar:`!PYTHONTHREADDEBUG` environment variable) is
823823
deprecated in Python 3.10 and will be removed in Python 3.12. This feature
824824
requires a debug build of Python. Patch by Victor Stinner.
825825

@@ -2808,7 +2808,7 @@ behaves differently than the similar implementation in :mod:`sysconfig`.
28082808
.. nonce: 3hmkWw
28092809
.. section: Library
28102810

2811-
:class:`smtpd.MailmanProxy` is now removed as it is unusable without an
2811+
:class:`!smtpd.MailmanProxy` is now removed as it is unusable without an
28122812
external module, ``mailman``. Patch by Donghee Na.
28132813

28142814
..

Misc/NEWS.d/3.11.0a7.rst

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -717,7 +717,7 @@ Fix :class:`asyncio.Semaphore` re-aquiring FIFO order.
717717
.. nonce: uaEDcI
718718
.. section: Library
719719
720-
The :mod:`asynchat`, :mod:`asyncore` and :mod:`smtpd` modules have been
720+
The :mod:`!asynchat`, :mod:`!asyncore` and :mod:`!smtpd` modules have been
721721
deprecated since at least Python 3.6. Their documentation and deprecation
722722
warnings and have now been updated to note they will removed in Python 3.12
723723
(:pep:`594`).
@@ -1324,7 +1324,7 @@ extensions.
13241324
.. section: Tests
13251325
13261326
A test case for :func:`os.sendfile` is converted from deprecated
1327-
:mod:`asyncore` (see :pep:`594`) to :mod:`asyncio`. Patch by Oleg Iarygin.
1327+
:mod:`!asyncore` (see :pep:`594`) to :mod:`asyncio`. Patch by Oleg Iarygin.
13281328

13291329
..
13301330

Misc/NEWS.d/3.12.0a1.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3617,7 +3617,7 @@ allow access to handlers by name.
36173617
.. nonce: uw6x5z
36183618
.. section: Library
36193619

3620-
The :mod:`smtpd` module was removed per the schedule in :pep:`594`.
3620+
The :mod:`!smtpd` module was removed per the schedule in :pep:`594`.
36213621

36223622
..
36233623

Misc/NEWS.d/3.12.0a2.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -695,7 +695,7 @@ Make sure ``patch.dict()`` can be applied on async functions.
695695
.. nonce: jUpzF3
696696
.. section: Library
697697

698-
Remove modules :mod:`asyncore` and :mod:`asynchat`, which were deprecated by
698+
Remove modules :mod:`!asyncore` and :mod:`!asynchat`, which were deprecated by
699699
:pep:`594`.
700700

701701
..

Misc/NEWS.d/3.8.0a1.rst

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2006,8 +2006,8 @@ Improved support of custom data descriptors in :func:`help` and
20062006
.. nonce: V4kNN3
20072007
.. section: Library
20082008

2009-
The `crypt` module now internally uses the `crypt_r()` library function
2010-
instead of `crypt()` when available.
2009+
The ``crypt`` module now internally uses the ``crypt_r()`` library function
2010+
instead of ``crypt()`` when available.
20112011

20122012
..
20132013

Misc/NEWS.d/3.8.0a4.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -255,7 +255,7 @@ all tags in a namespace. Patch by Stefan Behnel.
255255
.. nonce: Lpm-SI
256256
.. section: Library
257257

258-
`pathlib.path.link_to()` is now implemented. It creates a hard link pointing
258+
``pathlib.path.link_to()`` is now implemented. It creates a hard link pointing
259259
to a path.
260260

261261
..

0 commit comments

Comments
 (0)
0