Skip to content

Commit 2c3906b

Browse files
authored
gh-101100: Silence Sphinx warnings when ntpath or posixpath are referenced (#112833)
1 parent 64d8b4c commit 2c3906b

File tree

4 files changed

+8
-5
lines changed

4 files changed

+8
-5
lines changed

Doc/conf.py

+4
Original file line numberDiff line numberDiff line change
@@ -166,6 +166,10 @@
166166
# Deprecated function that was never documented:
167167
('py:func', 'getargspec'),
168168
('py:func', 'inspect.getargspec'),
169+
# Undocumented modules that users shouldn't have to worry about
170+
# (implementation details of `os.path`):
171+
('py:mod', 'ntpath'),
172+
('py:mod', 'posixpath'),
169173
]
170174

171175
# Temporary undocumented names.

Doc/library/pathlib.rst

+1-1
Original file line numberDiff line numberDiff line change
@@ -306,7 +306,7 @@ Pure paths provide the following methods and properties:
306306
.. attribute:: PurePath.pathmod
307307

308308
The implementation of the :mod:`os.path` module used for low-level path
309-
operations: either ``posixpath`` or ``ntpath``.
309+
operations: either :mod:`posixpath` or :mod:`ntpath`.
310310

311311
.. versionadded:: 3.13
312312

Doc/tools/.nitignore

-1
Original file line numberDiff line numberDiff line change
@@ -72,7 +72,6 @@ Doc/library/multiprocessing.rst
7272
Doc/library/multiprocessing.shared_memory.rst
7373
Doc/library/numbers.rst
7474
Doc/library/optparse.rst
75-
Doc/library/os.path.rst
7675
Doc/library/os.rst
7776
Doc/library/pickle.rst
7877
Doc/library/pickletools.rst

Doc/whatsnew/3.7.rst

+3-3
Original file line numberDiff line numberDiff line change
@@ -2144,9 +2144,9 @@ The following features and APIs have been removed from Python 3.7:
21442144
* Removed support of the *exclude* argument in :meth:`tarfile.TarFile.add`.
21452145
It was deprecated in Python 2.7 and 3.2. Use the *filter* argument instead.
21462146

2147-
* The ``splitunc()`` function in the :mod:`ntpath` module was deprecated in
2148-
Python 3.1, and has now been removed. Use the :func:`~os.path.splitdrive`
2149-
function instead.
2147+
* The :func:`!ntpath.splitunc` function was deprecated in
2148+
Python 3.1, and has now been removed. Use :func:`~os.path.splitdrive`
2149+
instead.
21502150

21512151
* :func:`collections.namedtuple` no longer supports the *verbose* parameter
21522152
or ``_source`` attribute which showed the generated source code for the

0 commit comments

Comments
 (0)