[Tutor] smtplib broken in python 2.3?

Baker.Michael.B Michael.Baker at IGT.com
Thu Mar 11 13:09:23 EST 2004

that did the trick. what an obvious solution - i had forgotten that i named
my py file email.py. thanks

Michael Baker

>Date: Wed, 10 Mar 2004 21:25:32 +0100
>From: sigurd at 12move.de ( Karl Pfl?sterer )
>Subject: Re: [Tutor] smtplib broken in python 2.3?
>To: tutor at python.org
>Message-ID: <m33c8gpi8z.fsf at hamster.pflaesterer.de>
>Content-Type: text/plain; charset=us-ascii

>On 10 Mar 2004, Baker.Michael.B <- Michael.Baker at IGT.com wrote:
>> ok in 2.2, but fail in 2.3:

>> Traceback (most recent call last):
>>   File "C:/Python23/email.py", line 1, in -toplevel-
>>     from smtplib import *
>>   File "C:\Python23\lib\smtplib.py", line 49, in -toplevel-
>>     from email.base64MIME import encode as encode_base64

>>   File "C:/Python23\email.py", line 19, in -toplevel-

>You gave your file the same name as a module which should be imported
(actually it's the name of the directory the files for the email package
>live in).  That will cause problems (maybe in 2.4 it would run again if the
new Pep from Aahz according import gets included).

>> what am i missing??? thanks in advance :)

>Give your file another name and try it again.

>   Karl
>Please do *not* send copies of replies to me.
>I read the list

More information about the Tutor mailing list