Commit 45321f83 authored by lixiaofang's avatar lixiaofang

del --pycache

parent b4870e22
......@@ -13,13 +13,14 @@ my_user6 = "lixiaofang@igengmei.com"
def send_email_tome(stat_data):
try:
msg = MIMEText(stat_data, 'plain', 'utf-8')
msg['From'] = formataddr(["李小芳", my_sender])
msg["To"] = formataddr(["李小芳", my_user6])
msg['Subject'] = str(datetime.date.today()) + "马甲超过次数啦,赶紧看一下"
server = smtplib.SMTP_SSL("smtp.exmail.qq.com", 465)
server.login(my_sender, my_pass)
server.sendmail(my_sender, [my_user6], msg.as_string())
server.quit()
pass
# msg = MIMEText(stat_data, 'plain', 'utf-8')
# msg['From'] = formataddr(["李小芳", my_sender])
# msg["To"] = formataddr(["李小芳", my_user6])
# msg['Subject'] = str(datetime.date.today()) + "马甲超过次数啦,赶紧看一下"
# server = smtplib.SMTP_SSL("smtp.exmail.qq.com", 465)
# server.login(my_sender, my_pass)
# server.sendmail(my_sender, [my_user6], msg.as_string())
# server.quit()
except Exception:
logging.error("catch exception,main:%s" % traceback.format_exc())
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment