[issue10686] email.Generator should use unknown-8bit encoded words for headers with 8 bit data

R. David Murray report at bugs.python.org
Fri Jan 7 13:37:19 CET 2011


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

Well, unknown-8bit is registered as a charset with IANA.  It is registered specifically for use in message bodies, but as a registered charset it "should" be acceptable in headers as well.  There is no similar registration for just 'unknown', but it sounds like mailers may be more likely to accept it if it exists in the wild.

I'm hoping to fix this before the RC (which is tomorrow, which means fixing it today), so your suggestion of making the 'unknown charset' token configurable is a good one.  I'm not so worried about providing a way to reject such headers, since this incarnation of email makes a point of not throwing errors on parsing, and if you read binary messages with unknown bytes the best thing to do is generate the outgoing message with BytesGenerator, in which case you get the unknown bytes back without the rfc2047 munging.

----------

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


More information about the Python-bugs-list mailing list