1
編譯時,我有一個Python腳本,的Python:錯誤與py2exe
import email
import email.mime.application
...
msg = email.mime.Multipart.MIMEMultipart()
msg['Subject'] = 'test'
msg['From'] = '[email protected]'
msg['To'] = '[email protected]'
body = email.mime.Text.MIMEText("""test""")
....
在Python腳本運行以及發送電子郵件, 但在我與py2exe編譯它,我得到這個錯誤
Traceback (most recent call last):
File "mail.py", line 13, in <module>
File "email\__init__.pyc", line 79, in __getattr__
ImportError: No module named multipart
在py2exe編譯日誌我看到這則消息
...
The following modules appear to be missing
['_scproxy', 'email.MIMEBase', 'email.MIMEMultipart', 'email.MIMEText']
....
任何想法如何解決這個問題? 謝謝
只要安裝使用PIP或easy_install的 – ForceBru 2015-03-03 11:03:39
我新的Python缺少的模塊,我安裝了點子,下一步該怎麼做看看?什麼是語法來安裝缺少的模塊 – Roco20099 2015-03-03 11:19:17
'pip安裝模塊' – ForceBru 2015-03-03 11:20:36