如何解决无法加载Qt平台插件“ Ubuntu 20.04”
我有一个python脚本,试图在新安装的ubuntu 20.04上运行,但出现错误,找不到任何解决方案。 我尝试输入调试命令 export QT_DEBUG_PLUGINS = 1 ,然后尝试通过 python3 ImageCompressor.py 运行脚本>这就是我之后得到的(我仍然不明白这是什么错误):
QFactoryLoader::QFactoryLoader() checking directory path "/home/my_user_name/.local/lib/python3.8/site-packages/PyQt5/Qt/plugins/platforms" ...
QFactoryLoader::QFactoryLoader() looking at "/home/my_user_name/.local/lib/python3.8/site-packages/PyQt5/Qt/plugins/platforms/libqeglfs.so"
Found metadata in lib /home/my_user_name/.local/lib/python3.8/site-packages/PyQt5/Qt/plugins/platforms/libqeglfs.so,metadata=
{
"IID": "org.qt-project.Qt.QPA.QPlatformIntegrationFactoryInterface.5.3","MetaData": {
"Keys": [
"eglfs"
]
},"archreq": 0,"className": "QEglFSIntegrationPlugin","debug": false,"version": 331520
}
Got keys from plugin meta data ("eglfs")
QFactoryLoader::QFactoryLoader() looking at "/home/my_user_name/.local/lib/python3.8/site-packages/PyQt5/Qt/plugins/platforms/libqlinuxfb.so"
Found metadata in lib /home/my_user_name/.local/lib/python3.8/site-packages/PyQt5/Qt/plugins/platforms/libqlinuxfb.so,"MetaData": {
"Keys": [
"linuxfb"
]
},"className": "QLinuxFbIntegrationPlugin","version": 331520
}
Got keys from plugin meta data ("linuxfb")
QFactoryLoader::QFactoryLoader() looking at "/home/my_user_name/.local/lib/python3.8/site-packages/PyQt5/Qt/plugins/platforms/libqminimal.so"
Found metadata in lib /home/my_user_name/.local/lib/python3.8/site-packages/PyQt5/Qt/plugins/platforms/libqminimal.so,"MetaData": {
"Keys": [
"minimal"
]
},"className": "QMinimalIntegrationPlugin","version": 331520
}
Got keys from plugin meta data ("minimal")
QFactoryLoader::QFactoryLoader() looking at "/home/my_user_name/.local/lib/python3.8/site-packages/PyQt5/Qt/plugins/platforms/libqminimalegl.so"
Found metadata in lib /home/my_user_name/.local/lib/python3.8/site-packages/PyQt5/Qt/plugins/platforms/libqminimalegl.so,"MetaData": {
"Keys": [
"minimalegl"
]
},"className": "QMinimalEglIntegrationPlugin","version": 331520
}
Got keys from plugin meta data ("minimalegl")
QFactoryLoader::QFactoryLoader() looking at "/home/my_user_name/.local/lib/python3.8/site-packages/PyQt5/Qt/plugins/platforms/libqoffscreen.so"
Found metadata in lib /home/my_user_name/.local/lib/python3.8/site-packages/PyQt5/Qt/plugins/platforms/libqoffscreen.so,"MetaData": {
"Keys": [
"offscreen"
]
},"className": "QOffscreenIntegrationPlugin","version": 331520
}
Got keys from plugin meta data ("offscreen")
QFactoryLoader::QFactoryLoader() looking at "/home/my_user_name/.local/lib/python3.8/site-packages/PyQt5/Qt/plugins/platforms/libqvnc.so"
Found metadata in lib /home/my_user_name/.local/lib/python3.8/site-packages/PyQt5/Qt/plugins/platforms/libqvnc.so,"MetaData": {
"Keys": [
"vnc"
]
},"className": "QVncIntegrationPlugin","version": 331520
}
Got keys from plugin meta data ("vnc")
QFactoryLoader::QFactoryLoader() looking at "/home/my_user_name/.local/lib/python3.8/site-packages/PyQt5/Qt/plugins/platforms/libqwayland-egl.so"
Found metadata in lib /home/my_user_name/.local/lib/python3.8/site-packages/PyQt5/Qt/plugins/platforms/libqwayland-egl.so,"MetaData": {
"Keys": [
"wayland-egl"
]
},"className": "QWaylandEglPlatformIntegrationPlugin","version": 331520
}
Got keys from plugin meta data ("wayland-egl")
QFactoryLoader::QFactoryLoader() looking at "/home/my_user_name/.local/lib/python3.8/site-packages/PyQt5/Qt/plugins/platforms/libqwayland-generic.so"
Found metadata in lib /home/my_user_name/.local/lib/python3.8/site-packages/PyQt5/Qt/plugins/platforms/libqwayland-generic.so,"MetaData": {
"Keys": [
"wayland"
]
},"className": "QWaylandIntegrationPlugin","version": 331520
}
Got keys from plugin meta data ("wayland")
QFactoryLoader::QFactoryLoader() looking at "/home/my_user_name/.local/lib/python3.8/site-packages/PyQt5/Qt/plugins/platforms/libqwayland-xcomposite-egl.so"
Found metadata in lib /home/my_user_name/.local/lib/python3.8/site-packages/PyQt5/Qt/plugins/platforms/libqwayland-xcomposite-egl.so,"MetaData": {
"Keys": [
"wayland-xcomposite-egl"
]
},"className": "QWaylandXCompositeEglPlatformIntegrationPlugin","version": 331520
}
Got keys from plugin meta data ("wayland-xcomposite-egl")
QFactoryLoader::QFactoryLoader() looking at "/home/my_user_name/.local/lib/python3.8/site-packages/PyQt5/Qt/plugins/platforms/libqwayland-xcomposite-glx.so"
Found metadata in lib /home/my_user_name/.local/lib/python3.8/site-packages/PyQt5/Qt/plugins/platforms/libqwayland-xcomposite-glx.so,"MetaData": {
"Keys": [
"wayland-xcomposite-glx"
]
},"className": "QWaylandXCompositeGlxPlatformIntegrationPlugin","version": 331520
}
Got keys from plugin meta data ("wayland-xcomposite-glx")
QFactoryLoader::QFactoryLoader() looking at "/home/my_user_name/.local/lib/python3.8/site-packages/PyQt5/Qt/plugins/platforms/libqwebgl.so"
Found metadata in lib /home/my_user_name/.local/lib/python3.8/site-packages/PyQt5/Qt/plugins/platforms/libqwebgl.so,"MetaData": {
"Keys": [
"webgl"
]
},"className": "QWebGLIntegrationPlugin","version": 331520
}
Got keys from plugin meta data ("webgl")
QFactoryLoader::QFactoryLoader() looking at "/home/my_user_name/.local/lib/python3.8/site-packages/PyQt5/Qt/plugins/platforms/libqxcb.so"
Found metadata in lib /home/my_user_name/.local/lib/python3.8/site-packages/PyQt5/Qt/plugins/platforms/libqxcb.so,"MetaData": {
"Keys": [
"xcb"
]
},"className": "QXcbIntegrationPlugin","version": 331520
}
Got keys from plugin meta data ("xcb")
QFactoryLoader::QFactoryLoader() checking directory path "/usr/bin/platforms" ...
Cannot load library /home/my_user_name/.local/lib/python3.8/site-packages/PyQt5/Qt/plugins/platforms/libqxcb.so: (libxcb-xinerama.so.0: cannot open shared object file: No such file or directory)
QLibraryPrivate::loadPlugin failed on "/home/my_user_name/.local/lib/python3.8/site-packages/PyQt5/Qt/plugins/platforms/libqxcb.so" : "Cannot load library /home/my_user_name/.local/lib/python3.8/site-packages/PyQt5/Qt/plugins/platforms/libqxcb.so: (libxcb-xinerama.so.0: cannot open shared object file: No such file or directory)"
qt.qpa.plugin: Could not load the Qt platform plugin "xcb" 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: eglfs,linuxfb,minimal,minimalegl,offscreen,vnc,wayland-egl,wayland,wayland-xcomposite-egl,wayland-xcomposite-glx,webgl,xcb.
Aborted (core dumped)
关于这个问题,您能帮我什么忙吗?我是Linux的新手,对此错误我一无所知。 谢谢。
版权声明:本文内容由互联网用户自发贡献,该文观点与技术仅代表作者本人。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌侵权/违法违规的内容, 请发送邮件至 dio@foxmail.com 举报,一经查实,本站将立刻删除。