[Tutor] smtplib with yahoo smtp server
Intercodes
intercodes at gmail.com
Wed Feb 1 10:55:04 CET 2006
Ewald,
First off, thanks for stopping by.
>The connection via the smtplib.SMTP() could be established.
>
I dont think so. I think it fails before the login().
------------------------------------------------------
>>> ex=smtplib.SMTP('smtp.mail.yahoo.com')
Traceback (most recent call last):
File "<stdin>", line 1, in ?
File "/usr/lib/python2.4/smtplib.py", line 241, in __init__
(code, msg) = self.connect(host, port)
File "/usr/lib/python2.4/smtplib.py", line 289, in connect
for res in socket.getaddrinfo(host, port, 0, socket.SOCK_STREAM):
socket.gaierror: (-2, 'Name or service not known')
------------------------------------------------
>>> socket.gethostname()
'linux'
---------------------------------------------
>>> socket.gethostbyname(socket.gethostname())
Traceback (most recent call last):
File "<stdin>", line 1, in ?
socket.gaierror: (-2, 'Name or service not known')
>>>
--------------------------------------------------
linux:/srv/www/htdocs/konnect # nslookup smtp.mail.yahoo.com
Server: 203.145.184.13
Address: 203.145.184.13#53
Non-authoritative answer:
smtp.mail.yahoo.com canonical name = smtp.plus.mail.yahoo.com.
smtp.plus.mail.yahoo.com canonical name =
smtp.plus.mail.yahoo4.akadns.net.
Name: smtp.plus.mail.yahoo4.akadns.net
Address: 216.136.173.18
-----------------------------------------------------
Thank you,
------
Intercodes
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mail.python.org/pipermail/tutor/attachments/20060201/d9538e41/attachment.htm
More information about the Tutor
mailing list