[issue4661] email.parser: impossible to read messages encoded in a different encoding

R. David Murray report at bugs.python.org
Fri Oct 8 14:16:02 CEST 2010


R. David Murray <rdmurray at bitdance.com> added the comment:

Even if smtplib accepted bytes (it currently does not), *Generator* is still producing unicode, and should produce valid unicode and still insofar as possible preserve the meaning of the original message.  This means unicode acts as if it is an SMTP server that does not support the 8bit capability, so we must convert to 7bit clean CTEs.

If smtplib later grows the ability to accept bytes, BytesGenerator can be used to feed it.  I've clarified that BytesGenerator does not do the 7bit transform, and made some other doc tweaks.

----------
Added file: http://bugs.python.org/file19160/email_parse_bytes8.diff

_______________________________________
Python tracker <report at bugs.python.org>
<http://bugs.python.org/issue4661>
_______________________________________


More information about the Python-bugs-list mailing list