使用nuitka打包pyqt5后,运行exe时报错
报错如下:
qt.qpa.plugin: Could not find the Qt platform plugin "windows" in ""
This application failed to start because no Qt platform plugin could be initialized. Reinstalling the application may fix this problem.
原因分析
这是由于打包后,pyqt5无法找到插件plugin 导致的。
解决方法
1、先找到虚拟环境中的Pyqt5,比如我的:
D:\job\gs\venv\das38\Lib\site-packages\PyQt5
2、把Qt5文件夹复制到打包好后的PyQt5文件夹中
亲测有效,如果能够解决你遇到的问题,请帮忙点个赞,顺便收藏下 ·_·