【发布时间】:2017-04-23 20:40:05
【问题描述】:
当我在 virtual_env 中编译时发生错误。如果在没有 virtual_env 的情况下编译,它可以工作。包安装在与一般环境中的virtual_env相同。如果编译程序“hello world”,一切正常。但如果添加“扭曲”的包,则会出现错误。
pyinstaller - 3.2
Python 2.7.12
安装工具 30.2.0
平台:Linux-4.4.0-53-generic-x86_64-with-Ubuntu-16.04-xenial
项目本身需要包
导入 json,ctypes,logging.handlers,os,sqlite3,pyudev,
子进程、系统、线程、时间、日期时间、多处理
从 twisted.internet 导入反应器,任务
从 twisted.internet.defer 导入 inlineCallbacks,returnValue
从 autobahn.twisted.wamp 导入 ApplicationSession, ApplicationRunner
从 autobahn.twisted.websocket 导入 WebSocketServerProtocol, WebSocketServerFactory
从 autobahn.wamp.exception 导入 ApplicationError
从 websocket_server 导入 WebsocketServer
17428 信息:正在加载模块挂钩“hook-encodings.py”...
17817 信息:加载模块挂钩“hook-xml.dom.domreg.py”...
17817 信息:加载模块挂钩“hook-pkg_resources.py”...
18077 INFO:处理预安全导入模块挂钩 win32com 回溯(最近一次通话最后一次):
文件“”,第 2 行,在 ImportError:没有名为 win32com 的模块 18198 INFO:处理预安全导入模块挂钩 win32com 回溯(最近一次通话最后一次):
文件“”,第 2 行,在 ImportError:没有名为 win32com 的模块 18317 INFO:处理预安全导入模块挂钩 win32com 回溯(最近一次通话最后一次):
文件“”,第 2 行,在 ImportError:没有名为 win32com 的模块 18451 INFO:处理预安全导入模块挂钩 win32com 回溯(最近一次通话最后一次):
文件“”,第 2 行,在 ImportError:没有名为 win32com 的模块 18885 信息:加载模块挂钩“hook-nacl.py”...
18914 信息:加载模块挂钩“hook-cryptography.py”...
18973 信息:加载模块挂钩“hook-sqlite3.py”...
程序启动时:
ImportError: 没有名为 zope.interface 的模块 执行脚本 pyi_rth_twisted 失败
但是这个模块我是单独安装在环境和一般的。我尝试使用不同版本的 pyinstaller、setuptools、zope.interface。结果,仍然存在这个错误
【问题讨论】:
标签: linux python-2.7 twisted pyinstaller win32com