[issue17505] [doc] email.header.Header.__unicode__ does not decode header

Vidhya report at bugs.python.org
Mon Feb 28 20:11:45 EST 2022


Vidhya <vidhya.friend at gmail.com> added the comment:

[Entry level contributor seeking guidance] If this is still open, I like to work on this.

Also, planning to add the following(if no PR yet created) at make_header API at https://docs.python.org/3/library/email.header.html :

To get unicode strings use the API as shown below:
 unicode(make_header(decode_header('=?gb2312?b?1eLKx9bQzsSy4srUo6E=?=')))

If email policy parameter is set as 'policy.default' then the default policy, for that Python version, is used for header encoding and decoding. 

Please correct me if anything wrong.

----------
nosy: +vidhya

_______________________________________
Python tracker <report at bugs.python.org>
<https://bugs.python.org/issue17505>
_______________________________________


More information about the Python-bugs-list mailing list