ubuntu新安装gnome-desktop后运行pyside6/pyqt5程序报错

bash 复制代码
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: offscreen, vkkhrdisplay, eglfs, wayland, linuxfb, vnc, minimalegl, xcb, wayland-egl, minimal.

解决方案:

bash 复制代码
~$ export QT_DEBUG_PLUGINS=1
~$ sudo apt-get install libxcb* libxkbcommon*
相关推荐
WL_Aurora4 分钟前
Python 算法基础篇之链表
python·算法·链表
计算机安禾6 分钟前
【Linux从入门到精通】第49篇:服务器故障排查终极指南——思路决定出路
linux·运维·服务器
古月-一个C++方向的小白7 分钟前
Linux——初识文件
linux·运维·服务器
曲幽10 分钟前
FastAPI 少有人提的实用技巧:把 Depends 依赖提到路由层,代码少写60%
python·fastapi·web·routes·depends·prefix·apiroute
qiaozhangchi13 分钟前
求解器学习笔记
笔记·python·学习
北山有鸟25 分钟前
编译香橙派内核
linux·运维·服务器
小此方32 分钟前
Re:Linux系统篇(八)权限篇 ·三:深度解析从 umask 位运算到粘滞位的“权力锁”
linux·运维·服务器
kexnjdcncnxjs42 分钟前
Redis如何记录每一次写操作_开启AOF持久化机制实现命令级追加记录
jvm·数据库·python
程序媛徐师姐1 小时前
Python基于Django的小区果蔬预定系统【附源码、文档说明】
python·django·小区果蔬预定系统·果蔬预定·python小区果蔬预定系统·小区果蔬预定·python果蔬预定系统