From 120716773f3d4d7e534e64e196380502d5c76121 Mon Sep 17 00:00:00 2001 From: RanKKI Date: Tue, 7 Jan 2025 12:59:20 +1100 Subject: [PATCH 1/5] docs(email): header's defects are not included in message's defects --- Doc/library/email.compat32-message.rst | 8 +++++--- Doc/library/email.message.rst | 9 +++++---- 2 files changed, 10 insertions(+), 7 deletions(-) diff --git a/Doc/library/email.compat32-message.rst b/Doc/library/email.compat32-message.rst index 4285c436e8da80..3fa1a46f17082d 100644 --- a/Doc/library/email.compat32-message.rst +++ b/Doc/library/email.compat32-message.rst @@ -755,6 +755,8 @@ Here are the methods of the :class:`Message` class: .. attribute:: defects - The *defects* attribute contains a list of all the problems found when - parsing this message. See :mod:`email.errors` for a detailed description - of the possible parsing defects. + The *defects* attribute contains a list of problems found when parsing + this message, excluding defects in message headers, as they are parsed + and detected only when accessed. See :mod:`email.errors` for a detailed + description of the possible parsing defects and + :attr:`BaseHeader.defects` for defects in headers. diff --git a/Doc/library/email.message.rst b/Doc/library/email.message.rst index 71d6e321f387bc..c7d4d34a81a60a 100644 --- a/Doc/library/email.message.rst +++ b/Doc/library/email.message.rst @@ -731,10 +731,11 @@ message objects. .. attribute:: defects - The *defects* attribute contains a list of all the problems found when - parsing this message. See :mod:`email.errors` for a detailed description - of the possible parsing defects. - + The *defects* attribute contains a list of problems found when parsing + this message, excluding defects in message headers, as they are parsed + and detected only when accessed. See :mod:`email.errors` for a detailed + description of the possible parsing defects and + :attr:`BaseHeader.defects` for defects in headers. .. class:: MIMEPart(policy=default) From 4b2cbf0f27c5ffb4e4fb5b87c7f507c0c97e724f Mon Sep 17 00:00:00 2001 From: RanKKI Date: Tue, 7 Jan 2025 13:12:23 +1100 Subject: [PATCH 2/5] chore: wrap --- Doc/library/email.compat32-message.rst | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/Doc/library/email.compat32-message.rst b/Doc/library/email.compat32-message.rst index 3fa1a46f17082d..c7308d6de727c5 100644 --- a/Doc/library/email.compat32-message.rst +++ b/Doc/library/email.compat32-message.rst @@ -759,4 +759,5 @@ Here are the methods of the :class:`Message` class: this message, excluding defects in message headers, as they are parsed and detected only when accessed. See :mod:`email.errors` for a detailed description of the possible parsing defects and - :attr:`BaseHeader.defects` for defects in headers. + :attr:`BaseHeader.defects` for + defects in headers. From 344f76986c38e6393822a41eb8beb54d9da1ef2d Mon Sep 17 00:00:00 2001 From: RanKKI Date: Tue, 7 Jan 2025 13:13:37 +1100 Subject: [PATCH 3/5] chore: wrap --- Doc/library/email.message.rst | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/Doc/library/email.message.rst b/Doc/library/email.message.rst index c7d4d34a81a60a..13635c7251a2a0 100644 --- a/Doc/library/email.message.rst +++ b/Doc/library/email.message.rst @@ -735,7 +735,8 @@ message objects. this message, excluding defects in message headers, as they are parsed and detected only when accessed. See :mod:`email.errors` for a detailed description of the possible parsing defects and - :attr:`BaseHeader.defects` for defects in headers. + :attr:`BaseHeader.defects` for + defects in headers. .. class:: MIMEPart(policy=default) From a3dc76b72a84e5276bce6b8bafb306cd3b602393 Mon Sep 17 00:00:00 2001 From: RanKKI Date: Tue, 7 Jan 2025 22:56:05 +1100 Subject: [PATCH 4/5] Update Doc/library/email.compat32-message.rst MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Co-authored-by: Bénédikt Tran <10796600+picnixz@users.noreply.github.com> --- Doc/library/email.compat32-message.rst | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/Doc/library/email.compat32-message.rst b/Doc/library/email.compat32-message.rst index c7308d6de727c5..57773093f9bef3 100644 --- a/Doc/library/email.compat32-message.rst +++ b/Doc/library/email.compat32-message.rst @@ -758,6 +758,5 @@ Here are the methods of the :class:`Message` class: The *defects* attribute contains a list of problems found when parsing this message, excluding defects in message headers, as they are parsed and detected only when accessed. See :mod:`email.errors` for a detailed - description of the possible parsing defects and - :attr:`BaseHeader.defects` for - defects in headers. + description of the possible parsing defects and :attr:`BaseHeader.defects + ` for defects in headers. From cbb3143164e4175ed49048acd3e4538d4e3437ed Mon Sep 17 00:00:00 2001 From: RanKKI Date: Tue, 7 Jan 2025 22:56:11 +1100 Subject: [PATCH 5/5] Update Doc/library/email.message.rst MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Co-authored-by: Bénédikt Tran <10796600+picnixz@users.noreply.github.com> --- Doc/library/email.message.rst | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/Doc/library/email.message.rst b/Doc/library/email.message.rst index 13635c7251a2a0..8abed3d8e4ba3f 100644 --- a/Doc/library/email.message.rst +++ b/Doc/library/email.message.rst @@ -734,9 +734,8 @@ message objects. The *defects* attribute contains a list of problems found when parsing this message, excluding defects in message headers, as they are parsed and detected only when accessed. See :mod:`email.errors` for a detailed - description of the possible parsing defects and - :attr:`BaseHeader.defects` for - defects in headers. + description of the possible parsing defects and :attr:`BaseHeader.defects + ` for defects in headers. .. class:: MIMEPart(policy=default)