【发布时间】:2021-03-03 08:37:09
【问题描述】:
我使用 PyQt5、cv2、PIL 等。
pyinstaller 运行后,exe 文件没有包含它们。
错误名称是“ModuleNotFoundError: No module named 'cv2'”。(还有 PyQt5、PIL...)
然后我将规范文件修复为“hiddenimports=['PyQt5', 'PIL']”,但它也不起作用。
我的python版本是3.7。(使用pycharm。) Pyinstaller 是 3.5、4.2、5.0dev
如何解决这个错误?
我只使用pycharm安装模块。
【问题讨论】:
标签: pyinstaller