]> git.ipfire.org Git - thirdparty/Python/cpython.git/commitdiff
gh-101100: Fix sphinx warnings in `zipapp` and `zipfile` modules (GH-102526)
authorMiss Islington (bot) <31488909+miss-islington@users.noreply.github.com>
Wed, 8 Mar 2023 08:30:44 +0000 (00:30 -0800)
committerGitHub <noreply@github.com>
Wed, 8 Mar 2023 08:30:44 +0000 (00:30 -0800)
(cherry picked from commit 1f557f94c2ee98c2a43bd090a7bf3f39a22ed874)

Co-authored-by: Nikita Sobolev <mail@sobolevn.me>
Doc/library/zipapp.rst
Doc/library/zipfile.rst

index fb40a2b3e964e4d52124d64134451a023dc4465c..981020b13cd988f0281c056c2ce53f67d989220d 100644 (file)
@@ -215,7 +215,7 @@ using the :func:`create_archive` function::
    >>> import zipapp
    >>> zipapp.create_archive('old_archive.pyz', 'new_archive.pyz', '/usr/bin/python3')
 
-To update the file in place, do the replacement in memory using a :class:`BytesIO`
+To update the file in place, do the replacement in memory using a :class:`~io.BytesIO`
 object, and then overwrite the source afterwards.  Note that there is a risk
 when overwriting a file in place that an error will result in the loss of
 the original file.  This code does not protect against such errors, but
index 9ad0a979e498b6d88da9d473248e0f7ef24ab35b..9e8e9c3cc20541207acb167aee92d802344c76f5 100644 (file)
@@ -288,7 +288,7 @@ ZipFile Objects
    (``ZipExtFile``) is read-only and provides the following methods:
    :meth:`~io.BufferedIOBase.read`, :meth:`~io.IOBase.readline`,
    :meth:`~io.IOBase.readlines`, :meth:`~io.IOBase.seek`,
-   :meth:`~io.IOBase.tell`, :meth:`__iter__`, :meth:`~iterator.__next__`.
+   :meth:`~io.IOBase.tell`, :meth:`~container.__iter__`, :meth:`~iterator.__next__`.
    These objects can operate independently of the ZipFile.
 
    With ``mode='w'``, a writable file handle is returned, which supports the