cannot import: from email.message import EmailMessage | Sololearn: Learn to code for FREE!
Nouvelle formation ! Tous les codeurs devraient apprendre l'IA générative !
Essayez une leçon gratuite
0

cannot import: from email.message import EmailMessage

I wrote a python script in sublime text to send emails but I can't seem to import EmailMessage. I have the latest python installed. I figured its because maybe python2.7 is being run instead of python3, so is there a way to point my script to python3? I've used the command: alias python=python3 and #!/usr/bin/python3 but still no luck.

23rd Oct 2019, 4:30 PM
David
David - avatar
1 Réponse
0
Thank you for answering Mirielle🐶 [Inactive] you were right. I didnt have it installed
2nd Nov 2019, 11:04 PM
David
David - avatar