]> granicus.if.org Git - python/commit
#1368247: make set_charset/MIMEText automatically encode unicode _payload.
authorR. David Murray <rdmurray@bitdance.com>
Wed, 2 Jun 2010 22:03:15 +0000 (22:03 +0000)
committerR. David Murray <rdmurray@bitdance.com>
Wed, 2 Jun 2010 22:03:15 +0000 (22:03 +0000)
commit52dcd4590652e3c6f57a94fb57a5522880b7d72b
treed8361501f980bff3a999186ff2ac1a961584e9c8
parentc395545a4ab4b4760c0472af74f526f405389864
#1368247: make set_charset/MIMEText automatically encode unicode _payload.

Fixes (mysterious, to the end user) UnicodeErrors when using utf-8 as
the charset and unicode as the _text argument.  Also makes the way in
which unicode gets encoded to quoted printable for other charsets more
sane (it only worked by accident previously).  The _payload now is encoded
to the charset.output_charset if it is unicode.
Doc/library/email.message.rst
Doc/library/email.mime.rst
Lib/email/message.py
Lib/email/test/test_email.py
Misc/NEWS