python - PyQt5 "xcb"未找到

标签 python qt pyqt5 archlinux

我使用 Qt 设计器创建了一个应用程序。当我启动我的应用程序时,它抛出此错误:

This application failed to start because it could not find or load the Qt platform plugin "xcb"
in "".

Reinstalling the application may fix this problem.
Aborted (core dumped)

抛出错误,然后程序执行此行:

app = QtWidgets.QApplication(sys.argv)

这看起来好像缺少一些依赖项。 如何解决这个问题?

我尝试重新安装libxcb,但这没有帮助。

P.S.:我使用的是 manjaro linux 和 python 3.5.2

P.P.S.:我收到此错误,然后尝试启动 ipython qtconsole

最佳答案

问题在于我使用 sudo 安装了 anaconda,并且使用 sudo 一切正常。我在没有 sudo 的情况下重新安装了 anaconda,现在一切正常

关于python - PyQt5 "xcb"未找到,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/41902192/

相关文章:

python - 如何录制在 Xvfb 上运行的 Selenium 测试视频?

python - 将两个不同 dtype 的 numpy 数组组合成一个结构化数组

python - 如何从Python3脚本运行Gradle

windows - 模糊的 Qt 快速文本

python - 将一个或多个文件拖放到 QListWidget 或 QLineEdit 中

python - 为什么 QWebEngineUrlRequestInterceptor 在 app.quit() 之后仍然存在

c++ - 在 Python 中制作 Qt/C++ 原型(prototype)

linux - 我怎样才能在 linux 中使用 qt 将窗口带到顶部?

python - 单击菜单并打开新窗口

c++ - qt程序中strstr的奇怪行为