-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1
Wichert Akkerman wrote: | It's been a month since I posted this; can I safely assume nobody knows | the answer or is it just not possible?
I never saw your original message sorry.
There is code that will correctly encode and decode email addresses at http://stuartbishop.net/Software/EmailAddress. It handles the case you mention, as well as handling Unicode domain names if you should ever actually see one.
|>I am trying to figure out how to use an 'internationaled' To-header but |>not succeeding so far. The basic documented approach does not work: |> |> |>>>>mail["From"]=email.Header.Header(, "utf-8") |>>>>print mail.as_string() |> |>[...] |>From: =?utf-8?b?dMODwrhzdGk=?= |> |>this is not allowed by the RFCs: the address must not be encoded. Using |>quoted-printable would fix this but I can not find any documentation |>as to how to do that. |> |>All current documentation mentions that specifying encoders is |>deprecated, but without setting them the email module seems to insist on |>using base64 encoding. |> |>Wichert.
- -- Stuart Bishop <[EMAIL PROTECTED]> http://www.stuartbishop.net/ -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.2.5 (GNU/Linux)
iD8DBQFB28eQAfqZj7rGN0oRAmg3AJ90ZLjurHATcW2qaGDk/eU6AALvpACgi7tr gUOlaVn/ArH40aj/YKJhS4k= =Soir -----END PGP SIGNATURE----- _______________________________________________ Email-SIG mailing list [email protected] Your options: http://mail.python.org/mailman/options/email-sig/archive%40mail-archive.com
