diff options
| author | Gregory P. Smith <greg@krypto.org> | 2013-03-19 15:25:46 -0700 |
|---|---|---|
| committer | Gregory P. Smith <greg@krypto.org> | 2013-03-19 15:25:46 -0700 |
| commit | 4effb670049930e905ef8473592fc675b6fdedc1 (patch) | |
| tree | d9998aaf96add9ab043cb84a83fdd5e0ecc7b93d | |
| parent | f6971804318e4645f34511d3116f51af2d42ca77 (diff) | |
| parent | 432a48a0c8b157fe09ed9cc09cd47754f0ef7eac (diff) | |
| download | cpython-git-4effb670049930e905ef8473592fc675b6fdedc1.tar.gz | |
merge heads
| -rw-r--r-- | Doc/library/email.mime.rst | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/Doc/library/email.mime.rst b/Doc/library/email.mime.rst index db5584c905..acaba1ce40 100644 --- a/Doc/library/email.mime.rst +++ b/Doc/library/email.mime.rst @@ -187,3 +187,13 @@ Here are the classes: :class:`~email.mime.nonmultipart.MIMENonMultipart` constructor; it defaults to ``us-ascii`` if the string contains only ``ascii`` codepoints, and ``utf-8`` otherwise. + + Unless the ``_charset`` parameter is explicitly set to ``None``, the + MIMEText object created will have both a :mailheader:`Content-Type` header + with a ``charset`` parameter, and a :mailheader:`Content-Transfer-Endcoding` + header. This means that a subsequent ``set_payload`` call will not result + in an encoded payload, even if a charset is passed in the ``set_payload`` + command. You can "reset" this behavior by deleting the + ``Content-Transfer-Encoding`` header, after which a ``set_payload`` call + will automatically encode the new payload (and add a new + :mailheader:`Content-Transfer-Encoding` header). |
