Mar 3

The following modules appear to be missing -python的py2exe编译的问题 不指定

adminleon , 19:19 , python , 评论(0) , 引用(0) , 阅读(74) , Via 本站原创 | |


   昨天晚上在window用py2exe编译python写的程序,由于第一次用,好多不解,当编译出现The following modules appear to be missing错误时,就唔知怎样处理了, 以下为错误信息:

The following modules appear to be missing
['DateTime', '_ssl', 'chardet', 'chardet.constants', 'cjkcodecs.aliases', 'iconv_codec', 'mx.DateTime', 'mx.Tidy', 'tidy']

在网上google后,才知道要在配置文件动手脚,以下我的配置文件

# setup.py
from distutils.core import setup
      
setup(console=["getrssgb.py"],
options = {'py2exe': {'excludes': ['DateTime','_ssl','chardet', 'chardet.constants', 'cjkcodecs.aliases', 'iconv_codec', 'mx.DateTime', 'mx.Tidy', 'tidy']}}
)  

这样编译就没问题了.

Tags: , , , , , ,
发表评论
表情
emotemotemotemotemot
emotemotemotemotemot
emotemotemotemotemot
emotemotemotemotemot
emotemotemotemotemot
打开HTML
打开UBB
打开表情
隐藏
记住我
昵称   密码   游客无需密码
网址   电邮   [注册]