Skip to content

gh-128568: fix documentation of email.Message.defects #128569

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 5 commits into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 5 additions & 3 deletions Doc/library/email.compat32-message.rst
Original file line number Diff line number Diff line change
Expand Up @@ -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
<email.headerregistry.BaseHeader.defects>` for defects in headers.
9 changes: 5 additions & 4 deletions Doc/library/email.message.rst
Original file line number Diff line number Diff line change
Expand Up @@ -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
<email.headerregistry.BaseHeader.defects>` for defects in headers.

.. class:: MIMEPart(policy=default)

Expand Down
Loading