gh_pythonlist at gmx.de
Sun Oct 21 00:14:35 CEST 2001
On Sat, Oct 20, 2001 at 11:41:34PM +0200, A wrote:
> I want to use smtplib module for sending emails. Is there any way how
> I can test a return code, generated by this module, to see if an email
> was accepting for delivery, for example?
No, there is no way to do this. But this is a "feature" of SMTP, not of
The only way smtplib is concerned is if the "RCPT TO" command fails with
550 "no such user". Then the sendmail method already returns the address
as not deliverable to. But at least my mailserver (Postfix) doesn't
return a 550 in such cases.
There are some other possibilties, but these will only work in some
relatively rare cases, (finger, SMTP delivery receipts and possibly
others). But all of these are out of the scope of Python's smtplib.
mail: gerhard <at> bigfoot <dot> de registered Linux user #64239
web: http://www.cs.fhm.edu/~ifw00065/ OpenPGP public key id 86AB43C0
public key fingerprint: DEC1 1D02 5743 1159 CD20 A4B6 7B22 6575 86AB 43C0
reduce(lambda x,y:x+y,map(lambda x:chr(ord(x)^42),tuple('zS^BED\nX_FOY\x0b')))
More information about the Python-list