estoy peleandome con un servidor de correo en python3 pero no veo donde esta el error, ¿me echais una mano?
Código:
Gracias foreros,import smtplib PASS='.........' sender = '[email protected]' receivers = ['[email protected]'] message = """From: From Person <[email protected]> To: To Person <[email protected]> Subject: SMTP e-mail test This is a test e-mail message. """ try: smtpObj = smtplib.SMTP_SSL('smtp.mail.yahoo.com', 465) smtp.login(sender, PASS) smtpObj.sendmail(sender, receivers, message) print("Successfully sent email") smtp.quit() except smtplib.SMTPException: print("Error: unable to send email")
Feliz año¡¡¡¡