Is it an error in email.Header?
Roman Suzi
rnd at onego.ru
Fri Sep 10 02:01:49 EDT 2004
It seems that
nEy8k?= =?koi8-r?B??=
^
'=' is missing. But is it necessary? MUAs live without it fine...
Sincerely yours, Roman A.Suzi
--
- Petrozavodsk - Karelia - Russia - mailto:rnd at onego.ru -
On Thu, 9 Sep 2004, Roman Suzi wrote:
>
> I was using Python module email.Header to decode headers and encountered
> problems with some of the headers. One example is given below:
>
> Python 2.3.4 (#1, May 27 2004, 15:48:35)
> [GCC 3.2.2 20030222 (Red Hat Linux 3.2.2-5)] on linux2
>
> >>> import email.Header
> >>> email.Header.decode_header('''=?koi8-r?B?Qm9va3MuUnUgLSDOz9fZyiDTwcrULCDOz9fZxSDTy8nEy8k?= =?koi8-r?B??=''')
> Traceback (most recent call last):
> File "<stdin>", line 1, in ?
> File "/var/tmp/python2.3-2.3.4-root/usr/lib/python2.3/email/Header.py",
> line 113, in decode_header
> email.Errors.HeaderParseError
>
> While mailers decode Subject just fine... Is it a case of some
> standard deviation?
>
>
> Sincerely yours, Roman A.Suzi
> --
> - Petrozavodsk - Karelia - Russia - mailto:rnd at onego.ru -
>
> --
> http://mail.python.org/mailman/listinfo/python-list
>
More information about the Python-list
mailing list