Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit 69ebfe4

Browse files
committed
#11780: document that email.encoders throw TypeError on multipart messages.
1 parent 969b8da commit 69ebfe4

1 file changed

Lines changed: 4 additions & 0 deletions

File tree

Doc/library/email.encoders.rst

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,10 @@ exactly one argument, the message object to encode. They usually extract the
1818
payload, encode it, and reset the payload to this newly encoded value. They
1919
should also set the :mailheader:`Content-Transfer-Encoding` header as appropriate.
2020

21+
Note that these functions are not meaningful for a multipart message. They
22+
must be applied to individual subparts instead, and will throw a
23+
:exc:`TypeError` if passed a message whose type is multipart.
24+
2125
Here are the encoding functions provided:
2226

2327

0 commit comments

Comments
 (0)