timothycrosley / streamdeck-ui

A Linux compatible UI for the Elgato Stream Deck.
https://timothycrosley.github.io/streamdeck-ui/
MIT License
1.12k stars 240 forks source link

[SOLVED] Installation in Ubuntu 23.04 Lunar Lobster: Could not load the Qt platform plugin "xcb" in "" even though it was found #327

Open yktoo opened 1 year ago

yktoo commented 1 year ago

First off, as reported in #323, in order to circumvent pip protection in Ubuntu 23.04, I had to install Streamdeck passing the --break-system-packages flag:

pip3 install --user streamdeck_ui --break-system-packages

The next problem was the error reported upon start:

$ streamdeck 
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: vnc, offscreen, minimal, wayland, minimalegl, wayland-egl, xcb, eglfs, vkkhrdisplay, linuxfb.

Aborted

Solution

I figured out that libxcb-cursor.so.0 was missing by running:

ldd $HOME/.local/lib/python3.11/site-packages/PySide6/Qt/plugins/platforms/libqxcb.so

In order to fix that you run:

sudo apt install libxcb-cursor0

And now Streamdeck starts just fine. Hope that helps someone facing that issue.

I think it's also worthwhile to update the docs.

desrod commented 1 year ago

Duplicate of https://github.com/timothycrosley/streamdeck-ui/issues/320

tdcam commented 1 year ago

For Fedora, the answer here is:

sudo dnf install xcb-util-cursor

Once I did that, and ran

pip install pillow --upgrade

Everything works now. Thanks!

dodgyrabbit commented 1 year ago

Just posting here in case it helps someone:

--break-system-packages

This is not recommended (although it does work). Looks like the Ubuntu way is to create a venv for anything that is not installed via apt. I.e. unless it's installed as apt install python3-xxx you should be installing it via a virtual environment.

You can read in all the gory details.

Also I managed to reproduce this:

Could not load the Qt platform plugin "xcb"

At least on Ubuntu, it only happens if you are logging on as XOrg. On Wayland everything works. The solution is to install libxcb-cursor0 on Ubuntu and xcb-util-cursor on Fedora as suggested.

coolapso commented 1 year ago

hi, this project seems to be stale and a new fork as been made with the intention of replacing this one.

if this still an issue please reopen it at: https://github.com/streamdeck-linux-gui/streamdeck-linux-gui