trigg / DiscordOverlayLinux

A QT/X11 based Discord overlay
https://github.com/trigg/DiscordOverlayLinux
Other
203 stars 10 forks source link

README update request + qt.qpa.plugin: Could not load the Qt platform plugin "xcb" #61

Open ls-1N opened 3 years ago

ls-1N commented 3 years ago

This is how I installed dependencies and the project on Kubuntu 16.04:

``` sudo apt install python3-pip ``` ``` sudo -H pip3 install --upgrade pip ``` ``` sudo -H pip3 install PyQtWebEngine ``` ``` git clone https://github.com/trigg/DiscordOverlayLinux.git ``` ``` cd DiscordOverlayLinux/ ``` ``` sudo -H pip3 install . ```

But when running the project, (via .desktop file or from CLI (example below)), I got this error:

$ discord-overlay
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)

Didn't find the core dump. But found instructions to get more debug info with the flag QT_DEBUG_PLUGINS=1. Long debug output:

``` $ QT_DEBUG_PLUGINS=1 discord-overlay QFactoryLoader::QFactoryLoader() checking directory path "/home/beSuspiciousOfWhatYouBelieve/.local/lib/python3.5/site-packages/PyQt5/Qt/plugins/platforms" ... QFactoryLoader::QFactoryLoader() looking at "/home/beSuspiciousOfWhatYouBelieve/.local/lib/python3.5/site-packages/PyQt5/Qt/plugins/platforms/libqeglfs.so" Found metadata in lib /home/beSuspiciousOfWhatYouBelieve/.local/lib/python3.5/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/beSuspiciousOfWhatYouBelieve/.local/lib/python3.5/site-packages/PyQt5/Qt/plugins/platforms/libqlinuxfb.so" Found metadata in lib /home/beSuspiciousOfWhatYouBelieve/.local/lib/python3.5/site-packages/PyQt5/Qt/plugins/platforms/libqlinuxfb.so, metadata= { "IID": "org.qt-project.Qt.QPA.QPlatformIntegrationFactoryInterface.5.3", "MetaData": { "Keys": [ "linuxfb" ] }, "archreq": 0, "className": "QLinuxFbIntegrationPlugin", "debug": false, "version": 331520 } Got keys from plugin meta data ("linuxfb") QFactoryLoader::QFactoryLoader() looking at "/home/beSuspiciousOfWhatYouBelieve/.local/lib/python3.5/site-packages/PyQt5/Qt/plugins/platforms/libqminimal.so" Found metadata in lib /home/beSuspiciousOfWhatYouBelieve/.local/lib/python3.5/site-packages/PyQt5/Qt/plugins/platforms/libqminimal.so, metadata= { "IID": "org.qt-project.Qt.QPA.QPlatformIntegrationFactoryInterface.5.3", "MetaData": { "Keys": [ "minimal" ] }, "archreq": 0, "className": "QMinimalIntegrationPlugin", "debug": false, "version": 331520 } Got keys from plugin meta data ("minimal") QFactoryLoader::QFactoryLoader() looking at "/home/beSuspiciousOfWhatYouBelieve/.local/lib/python3.5/site-packages/PyQt5/Qt/plugins/platforms/libqminimalegl.so" Found metadata in lib /home/beSuspiciousOfWhatYouBelieve/.local/lib/python3.5/site-packages/PyQt5/Qt/plugins/platforms/libqminimalegl.so, metadata= { "IID": "org.qt-project.Qt.QPA.QPlatformIntegrationFactoryInterface.5.3", "MetaData": { "Keys": [ "minimalegl" ] }, "archreq": 0, "className": "QMinimalEglIntegrationPlugin", "debug": false, "version": 331520 } Got keys from plugin meta data ("minimalegl") QFactoryLoader::QFactoryLoader() looking at "/home/beSuspiciousOfWhatYouBelieve/.local/lib/python3.5/site-packages/PyQt5/Qt/plugins/platforms/libqoffscreen.so" Found metadata in lib /home/beSuspiciousOfWhatYouBelieve/.local/lib/python3.5/site-packages/PyQt5/Qt/plugins/platforms/libqoffscreen.so, metadata= { "IID": "org.qt-project.Qt.QPA.QPlatformIntegrationFactoryInterface.5.3", "MetaData": { "Keys": [ "offscreen" ] }, "archreq": 0, "className": "QOffscreenIntegrationPlugin", "debug": false, "version": 331520 } Got keys from plugin meta data ("offscreen") QFactoryLoader::QFactoryLoader() looking at "/home/beSuspiciousOfWhatYouBelieve/.local/lib/python3.5/site-packages/PyQt5/Qt/plugins/platforms/libqvnc.so" Found metadata in lib /home/beSuspiciousOfWhatYouBelieve/.local/lib/python3.5/site-packages/PyQt5/Qt/plugins/platforms/libqvnc.so, metadata= { "IID": "org.qt-project.Qt.QPA.QPlatformIntegrationFactoryInterface.5.3", "MetaData": { "Keys": [ "vnc" ] }, "archreq": 0, "className": "QVncIntegrationPlugin", "debug": false, "version": 331520 } Got keys from plugin meta data ("vnc") QFactoryLoader::QFactoryLoader() looking at "/home/beSuspiciousOfWhatYouBelieve/.local/lib/python3.5/site-packages/PyQt5/Qt/plugins/platforms/libqwayland-egl.so" Found metadata in lib /home/beSuspiciousOfWhatYouBelieve/.local/lib/python3.5/site-packages/PyQt5/Qt/plugins/platforms/libqwayland-egl.so, metadata= { "IID": "org.qt-project.Qt.QPA.QPlatformIntegrationFactoryInterface.5.3", "MetaData": { "Keys": [ "wayland-egl" ] }, "archreq": 0, "className": "QWaylandEglPlatformIntegrationPlugin", "debug": false, "version": 331520 } Got keys from plugin meta data ("wayland-egl") QFactoryLoader::QFactoryLoader() looking at "/home/beSuspiciousOfWhatYouBelieve/.local/lib/python3.5/site-packages/PyQt5/Qt/plugins/platforms/libqwayland-generic.so" Found metadata in lib /home/beSuspiciousOfWhatYouBelieve/.local/lib/python3.5/site-packages/PyQt5/Qt/plugins/platforms/libqwayland-generic.so, metadata= { "IID": "org.qt-project.Qt.QPA.QPlatformIntegrationFactoryInterface.5.3", "MetaData": { "Keys": [ "wayland" ] }, "archreq": 0, "className": "QWaylandIntegrationPlugin", "debug": false, "version": 331520 } Got keys from plugin meta data ("wayland") QFactoryLoader::QFactoryLoader() looking at "/home/beSuspiciousOfWhatYouBelieve/.local/lib/python3.5/site-packages/PyQt5/Qt/plugins/platforms/libqwayland-xcomposite-egl.so" Found metadata in lib /home/beSuspiciousOfWhatYouBelieve/.local/lib/python3.5/site-packages/PyQt5/Qt/plugins/platforms/libqwayland-xcomposite-egl.so, metadata= { "IID": "org.qt-project.Qt.QPA.QPlatformIntegrationFactoryInterface.5.3", "MetaData": { "Keys": [ "wayland-xcomposite-egl" ] }, "archreq": 0, "className": "QWaylandXCompositeEglPlatformIntegrationPlugin", "debug": false, "version": 331520 } Got keys from plugin meta data ("wayland-xcomposite-egl") QFactoryLoader::QFactoryLoader() looking at "/home/beSuspiciousOfWhatYouBelieve/.local/lib/python3.5/site-packages/PyQt5/Qt/plugins/platforms/libqwayland-xcomposite-glx.so" Found metadata in lib /home/beSuspiciousOfWhatYouBelieve/.local/lib/python3.5/site-packages/PyQt5/Qt/plugins/platforms/libqwayland-xcomposite-glx.so, metadata= { "IID": "org.qt-project.Qt.QPA.QPlatformIntegrationFactoryInterface.5.3", "MetaData": { "Keys": [ "wayland-xcomposite-glx" ] }, "archreq": 0, "className": "QWaylandXCompositeGlxPlatformIntegrationPlugin", "debug": false, "version": 331520 } Got keys from plugin meta data ("wayland-xcomposite-glx") QFactoryLoader::QFactoryLoader() looking at "/home/beSuspiciousOfWhatYouBelieve/.local/lib/python3.5/site-packages/PyQt5/Qt/plugins/platforms/libqwebgl.so" Found metadata in lib /home/beSuspiciousOfWhatYouBelieve/.local/lib/python3.5/site-packages/PyQt5/Qt/plugins/platforms/libqwebgl.so, metadata= { "IID": "org.qt-project.Qt.QPA.QPlatformIntegrationFactoryInterface.5.3", "MetaData": { "Keys": [ "webgl" ] }, "archreq": 0, "className": "QWebGLIntegrationPlugin", "debug": false, "version": 331520 } Got keys from plugin meta data ("webgl") QFactoryLoader::QFactoryLoader() looking at "/home/beSuspiciousOfWhatYouBelieve/.local/lib/python3.5/site-packages/PyQt5/Qt/plugins/platforms/libqxcb.so" Found metadata in lib /home/beSuspiciousOfWhatYouBelieve/.local/lib/python3.5/site-packages/PyQt5/Qt/plugins/platforms/libqxcb.so, metadata= { "IID": "org.qt-project.Qt.QPA.QPlatformIntegrationFactoryInterface.5.3", "MetaData": { "Keys": [ "xcb" ] }, "archreq": 0, "className": "QXcbIntegrationPlugin", "debug": false, "version": 331520 } Got keys from plugin meta data ("xcb") QFactoryLoader::QFactoryLoader() checking directory path "/usr/bin/platforms" ... Cannot load library /home/beSuspiciousOfWhatYouBelieve/.local/lib/python3.5/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/beSuspiciousOfWhatYouBelieve/.local/lib/python3.5/site-packages/PyQt5/Qt/plugins/platforms/libqxcb.so" : "Cannot load library /home/beSuspiciousOfWhatYouBelieve/.local/lib/python3.5/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) ```

I could run the project fine after:

sudo apt install libxcb-xinerama0

Question 1:

Should libxcb-xinerama0 also be dependency in README.md? Is it Ubuntu specific? Is it Ubuntu 16.04 LTS specific?

Question 2:

Should I make a pull request to add these properly formatted Ubuntu-specific instruction (pip3 and all; can be hidden under "details" maybe) to the README.md?

I believe this will both make it easier for many people to use your software AND it will reduce the number of support requests, since they will have super clear instructions what to do. I can also test it on Ubuntu 18.04 LTS before making such a pull request.

midget3111 commented 3 years ago

Interesting, I haven't come across that one before. It is most likely due to using 16.04 Would you be able to try on 20.04 and see if you have the same error?

ls-1N commented 3 years ago

It is very convenient for me to test it on Kubuntu 18.04.

Do you think I would get the same test results if I don't install a distro, but simply boot it from a live USB drive (without any persistence)? Then I wouldn't mind trying Kubuntu 20.04 or some other Ubuntu-based 20.04-s. On the other hand if I actually need to install the distro on a device, then I would need to find the time and motivation for an hour or two just to test this.

midget3111 commented 3 years ago

I imagine a live USB should be just as good! Would also be interested in your 18.04 results.

ls-1N commented 3 years ago

libxcb-xinerama0 was not needed for my (dirty) Kubuntu 18.04. (The previously mentioned Kubuntu 16.04 distro was also dirty - not fresh out of the box and has a lot of various software and customizations). So I guess the answer to my first question is probably "no" - most people can find the solution in this opening post if they have that same issue. I can still try the Ubuntu 20.04 at some point as well, but more likely than not, this is a 16.04 issue.

midget3111 commented 3 years ago

Thanks for testing either way! We're now encouraging people to use https://github.com/trigg/Discover instead. It is much cleaner, doesn't rely on the streamkit and is much less heavy on resource usage!

ls-1N commented 3 years ago

Ah! Glad you updated the readme right away as well so less effort spread between the projects. I will try it out one of these days...