def SendEmail(fromAdd, toAdd, subject, attachfile, htmlText):
         strFrom = fromAdd
         strTo = toAdd
         msg = MIMEText("Test")
         msg["Subject"] = "don't panic"
         msg["From"] = fromAdd
         msg["To"] = toAdd
         s = smtplib.SMTP_SSL("smtp.qq.com", 465)
         s.login('[email protected]', '第三方登录码')
         s.sendmail('[email protected]', '[email protected]', msg.as_string())
         s.quit()



if __name__ == "__main__":
       SendEmail("[email protected]", "[email protected]", "", "hello", "hello world")