R. David Murray added the comment: Ah, yes, that would do it. EmailMessage should definitely throw an error if it gets compat32 as a policy, that would have told you what you were doing "wrong".
What you want to be doing is: msg = message_from_string(mystring, policy=default) That will get you an EmailMessage object. Note, however, that you almost never want message_from_string, because real email messages are bytes objects, not strings. string only works if your message is ASCII only. (There's an open issue about documenting this properly...and a big doc revision in the offing.) ---------- _______________________________________ Python tracker <rep...@bugs.python.org> <http://bugs.python.org/issue25640> _______________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com