logging.error("Couldn't send mail using the sendmail method: %s" % e)
try:
connection.quit()
logging.error("Couldn't send mail using the sendmail method: %s" % e)
try:
connection.quit()
- connection = None
- except Exception:
+ except Exception, e:
+ logging.error(e)
+ finally:
connection = None
try:
connection.quit()
connection = None
try:
connection.quit()
+ except AttributeError:
+ pass
except socket.sslerror:
connection.close()
except Exception, e:
except socket.sslerror:
connection.close()
except Exception, e: