【问题标题】:Error with Pyinstaller & PyQt5 "Cannot find existing PyQt5 plugin directories"Pyinstaller 和 PyQt5 出错“找不到现有的 PyQt5 插件目录”
【发布时间】:2018-11-19 07:39:51
【问题描述】:

我使用 Anaconda 5.3.0 和 Python 3.7。

创建了一个应用程序,我想用Pyinstaller创建一个可执行文件,情况是我错过了以下错误:

异常:找不到现有的 PyQt5 插件目录路径 检查: C:/Miniconda3/conda-bld/qt_1535195524645/_h_env/Library/plugins

【问题讨论】:

    标签: python pyqt5 pyinstaller


    【解决方案1】:

    在 anaconda 命令提示符下尝试pip install PyQt5。它为我解决了这个问题。

    【讨论】:

    • 我认为问题更多的是“为什么它不需要 PyQt5 时却要它?”,而不是“我怎样才能满足 PyQt5 的要求?”
    【解决方案2】:

    根据this GitHub error report,主要有两种解决方案:

    • 运行pip install PyQt5安装模块
    • 包含标志 --exclude-module PyQt5 以防止 pyinstaller 尝试包含它

    后者似乎对我有用。

    【讨论】:

      猜你喜欢
      • 2017-02-05
      • 2019-02-21
      • 2022-07-14
      • 1970-01-01
      • 2020-12-03
      • 1970-01-01
      • 2020-01-31
      • 1970-01-01
      • 1970-01-01
      相关资源
      最近更新 更多