Skip to content

Commit 5eee2a9

Browse files
authored
Update email.headerregistry.rst docs to reflect required parse_tree kwarg
1 parent 91e6a58 commit 5eee2a9

File tree

1 file changed

+4
-3
lines changed

1 file changed

+4
-3
lines changed

Doc/library/email.headerregistry.rst

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -96,9 +96,10 @@ headers.
9696
``kwds`` is a dictionary containing one pre-initialized key, ``defects``.
9797
``defects`` is an empty list. The parse method should append any detected
9898
defects to this list. On return, the ``kwds`` dictionary *must* contain
99-
values for at least the keys ``decoded`` and ``defects``. ``decoded``
100-
should be the string value for the header (that is, the header value fully
101-
decoded to unicode). The parse method should assume that *string* may
99+
values for at least the keys ``decoded``, ``defects`` and ``parse_tree``.
100+
``decoded`` should be the string value for the header (that is, the header
101+
value fully decoded to unicode). ``parse_tree`` is set to the parse tree obtained
102+
from parsing the header. The parse method should assume that *string* may
102103
contain content-transfer-encoded parts, but should correctly handle all valid
103104
unicode characters as well so that it can parse un-encoded header values.
104105

0 commit comments

Comments
 (0)