I get this error trying to launch brave and it has been broken for me since nix 24.11 seems to only happen on KDE though as launching it on Gnome works fine and I tried it on a NixOS vm running KDE and it works there as well, so this seems to be an issue affecting non-nixOS systems
qt.qpa.plugin: Could not find the Qt platform plugin "wayland" in ""
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, vkkhrdisplay, vnc, xcb.
[0118/100851.470439:ERROR:process_memory_range.cc(75)] read out of range
/nix/store/4xljhb0j5lkpf086mm6f3ny6m53zws57-brave-1.73.104/bin/.brave-wrapped: line 39: 227149 Aborted (core dumped) "$HERE/brave" "$@"
I tried installing kdePackages.qtwayland
, but it didn’t solve the issues sadly
What OS are you running?
Brave is a fork of chrome which is built on chromium and electron, and they are known to be buggy with wayland
Maybe this will help, because i have no problems.
Normal configuration:
environment = {
sessionVariables = {
NIXOS_OZONE_WL = "1"; # Enable wayland for chromium-based apps (VSCode Discord Brave)
};
};
For Home-Manager:
programs.chromium = {
enable = true;
package = pkgs.brave;
extensions = [
"nngceckbapebfimnlniiiahkandclblb" # Bitwarden Passwortmanager
"eimadpbcbfnmbkopoojfekhnkhdbieeh" # Dark Reader
"neebplgakaahbhdphmkckjjcegoiijjo" # Keepa - Amazon Price Tracker
"mbniclmhobmnbdlbpiphghaielnnpgdp" # lightshot
];
};
I am running Arch Linux on my current machine, but I also have another machine running Fedora KDE and the issue is there as well
Unfortunately this won’t solve it for me as the problem is only on non-NixOS, brave launches fine on nixOS
Get a dump of the dmesg and journal for the affected machine so i can take a look
Use pastebin if you run out of characters in the post reply
Sorry, for the late reply haven’t opened the website since I posted, I have managed to fix the issue earlier today by using the NixOS wiki page on QT to debug and installing the pkgs.qt6.full
package and it now works fine.
Still don’t why the issue happened though as requested libraries where present on my system and the brave binary was looking at the correct path of libraries (which is /usr/lib/qt6/plugins/platforms
), but doesn’t see them.
Here is the pastebin link if you are interested in seeing the issue (see line 109 to know what i am talking about) .
Will probably create a github issue to add the wayland libs to qt6-base package, so that we don’t suffer from dependency hell again
.
At least it works now thank you for your help.