美文网首页
使用PySide2时遇到了qt.qpa.plugin: Coul

使用PySide2时遇到了qt.qpa.plugin: Coul

作者: MagicoePaper | 来源:发表于2020-01-15 14:08 被阅读0次

使用了PySide2替换PyQT5. 所以系统里同时安装了pyqt和pyside2.

遇到了如下问题,见截图

qt.qpa.plugin: Could not load the Qt platform plugin "windows" in "" even though it was found.
This application failed to start because no Qt platform plugin could be initialized. Reinstalling the application may fix this problem.

Available platform plugins are: direct2d, minimal, offscreen, windows.
image.png

解决办法参考了
https://stackoverflow.com/questions/41994485/error-could-not-find-or-load-the-qt-platform-plugin-windows-while-using-matplo

将如下文件

\Anaconda3\Lib\site-packages\PySide2\plugins\platforms\qminimal.dll
\Anaconda3\Lib\site-packages\PySide2\plugins\platforms\qoffscreen.dll
\Anaconda3\Lib\site-packages\PySide2\plugins\platforms\qwindows.dll

复制到这个文件夹即可
\Anaconda3\Library\plugins\platforms\

圆满解决

相关文章

网友评论

      本文标题:使用PySide2时遇到了qt.qpa.plugin: Coul

      本文链接:https://www.haomeiwen.com/subject/dtstzctx.html