From 2ea1efea4c385b93a727180cdd4fb5eb633c5873 Mon Sep 17 00:00:00 2001 From: jiahua wang Date: Sun, 28 Nov 2021 18:13:59 +0800 Subject: [PATCH 1/3] bpo-28445: Fix wrong documentation for GzipFile.peek --- Doc/library/gzip.rst | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/Doc/library/gzip.rst b/Doc/library/gzip.rst index 8cea2649ee6cb6..3557767fc98033 100644 --- a/Doc/library/gzip.rst +++ b/Doc/library/gzip.rst @@ -120,9 +120,8 @@ The module defines the following items: .. method:: peek(n) Read *n* uncompressed bytes without advancing the file position. - At most one single read on the compressed stream is done to satisfy - the call. The number of bytes returned may be more or less than - requested. + Read on the compressed stream is done to satisfythe call. The + number of bytes returned may be more or less than requested. .. note:: While calling :meth:`peek` does not change the file position of the :class:`GzipFile`, it may change the position of the underlying From 32b49e60381b703683990a5e48979f8f06f4bd50 Mon Sep 17 00:00:00 2001 From: jiahua wang Date: Sun, 28 Nov 2021 19:18:28 +0800 Subject: [PATCH 2/3] Fix a typo --- Doc/library/gzip.rst | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Doc/library/gzip.rst b/Doc/library/gzip.rst index 3557767fc98033..3622425a048cfc 100644 --- a/Doc/library/gzip.rst +++ b/Doc/library/gzip.rst @@ -120,7 +120,7 @@ The module defines the following items: .. method:: peek(n) Read *n* uncompressed bytes without advancing the file position. - Read on the compressed stream is done to satisfythe call. The + Read on the compressed stream is done to satisfy the call. The number of bytes returned may be more or less than requested. .. note:: While calling :meth:`peek` does not change the file position of From 5f8e5733b831c0bf846df4d6504ed9f98857f575 Mon Sep 17 00:00:00 2001 From: 180909 <734461790@qq.com> Date: Mon, 31 Oct 2022 09:47:14 +0800 Subject: [PATCH 3/3] Remove useless sentence. --- Doc/library/gzip.rst | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/Doc/library/gzip.rst b/Doc/library/gzip.rst index e3148aad17a309..9c61962134abcf 100644 --- a/Doc/library/gzip.rst +++ b/Doc/library/gzip.rst @@ -120,8 +120,7 @@ The module defines the following items: .. method:: peek(n) Read *n* uncompressed bytes without advancing the file position. - Read on the compressed stream is done to satisfy the call. The - number of bytes returned may be more or less than requested. + The number of bytes returned may be more or less than requested. .. note:: While calling :meth:`peek` does not change the file position of the :class:`GzipFile`, it may change the position of the underlying