Re: email with a non-ascii charset in Python3 ?

2012-08-15 Thread Ben Finney
Steven D'Aprano writes: > On Wed, 15 Aug 2012 17:57:47 +0100, MRAB wrote: > > >> #!/usr/bin/python3 > >> #_*_ coding: latin1 _*_ > >> > > Aw well as the other replies, the "coding" line should be: > > > > #-*- coding: latin1 -*- > > I don't believe that actually matters to Python. It may matter

Re: email with a non-ascii charset in Python3 ?

2012-08-15 Thread Steven D'Aprano
On Wed, 15 Aug 2012 17:57:47 +0100, MRAB wrote: >> #!/usr/bin/python3 >> #_*_ coding: latin1 _*_ >> > Aw well as the other replies, the "coding" line should be: > > #-*- coding: latin1 -*- I don't believe that actually matters to Python. It may matter to Emacs or some other editors, but Python

Re: email with a non-ascii charset in Python3 ?

2012-08-15 Thread MRAB
On 15/08/2012 13:16, Helmut Jarausch wrote: Hi, I'm sorry to ask such a FAQ but still I couldn't find an answer - neither in the docs nor the web. What's wrong with the following script? Many thanks for a hint, Helmut. #!/usr/bin/python3 #_*_ coding: latin1 _*_ Aw well as the other replies

Re: email with a non-ascii charset in Python3 ?

2012-08-15 Thread Helmut Jarausch
On Wed, 15 Aug 2012 14:48:40 +0200, Christian Heimes wrote: > Am 15.08.2012 14:16, schrieb Helmut Jarausch: >> Hi, >> >> I'm sorry to ask such a FAQ but still I couldn't find an answer - >> neither in the docs nor the web. >> >> What's wrong with the following script? >> >> Many thanks for a hi

Re: email with a non-ascii charset in Python3 ?

2012-08-15 Thread Christian Heimes
Am 15.08.2012 14:16, schrieb Helmut Jarausch: > Hi, > > I'm sorry to ask such a FAQ but still I couldn't find an answer - neither in > the docs nor the web. > > What's wrong with the following script? > > Many thanks for a hint, > Helmut. > > #!/usr/bin/python3 > #_*_ coding: latin1 _*_ > > i

email with a non-ascii charset in Python3 ?

2012-08-15 Thread Helmut Jarausch
Hi, I'm sorry to ask such a FAQ but still I couldn't find an answer - neither in the docs nor the web. What's wrong with the following script? Many thanks for a hint, Helmut. #!/usr/bin/python3 #_*_ coding: latin1 _*_ import smtplib from email.message import Message import datetime msg= Mess