Reading EmailMessage from file

Roel Schroeven roel at roelschroeven.net
Mon Jul 16 18:06:38 EDT 2018


Skip Montanaro schreef op 16/07/2018 3:31:
> So, problem solved. The example I originally referred to clearly
> requires the caller know the encoding of the input file. When you
> don't know the encoding, you need bytes. The BytesParser gave me that.
> 
> Also, I must admit to having not completely read the examples page,
> where it described use of the BytesParser class a bit further down the
> page, but I stopped when the simple example failed for me.

I've been there too some time ago.

I Was going to complain about it here (or rather ask for a better way to 
do it); in order to do that, I did a bit more research than I had 
apparently done the first time around, and discovered the right way to 
create an email message from raw bytes.


-- 
"Honest criticism is hard to take, particularly from a relative, a
friend, an acquaintance, or a stranger."
         -- Franklin P. Jones

Roel Schroeven



More information about the Python-list mailing list