flatpak crash, file access
the flatpak version crashes on attempting to use a folder or file system after clicking file or folder button and skipping through dialogue. i've even made it go into windowed mode and the same thing happens, i tried dragging and dropping and that doesn't work either so there's no workaround that i know of.
Operating System: EndeavourOS KDE Plasma Version: 6.2.5 KDE Frameworks Version: 6.10.0 Qt Version: 6.8.2 Kernel Version: 6.11.8-x64v2-xanmod1-1 (64-bit) Graphics Platform: X11 Processors: 4 × Intel® Core™ i5-6600K CPU @ 3.50GHz Memory: 15.6 GiB of RAM Graphics Processor: NVIDIA GeForce GT 1030/PCIe/SSE2 Manufacturer: Dell Inc. Product Name: Inspiron 3650 System Version: X00
Can confirm, same issue. Am on Arch Linux, KDE Plasma too. The installer always closes itself no matter what, after clicking either file or folder buttons. I tried giving permission to access user files, no dice. Log below.
flatpak run --branch=master --arch=x86_64 --command=/app/bin/UnleashedRecomp io.github.hedge_dev.unleashedrecomp
[*] OS doesn't support registry
[*] SDL video driver: "x11"
Gtk-Message: 08:24:38.893: Failed to load module "xapp-gtk3-module"
Gtk-Message: 08:24:38.893: Failed to load module "canberra-gtk-module"
(UnleashedRecomp:2): Gdk-WARNING **: 08:24:45.034: The program 'UnleashedRecomp' received an X Window System error.
This probably reflects a bug in the program.
The error was 'BadAccess (attempt to access private resource denied)'.
(Details: serial 184 error_code 10 request_code 130 (MIT-SHM) minor_code 1)
(Note to programmers: normally, X errors are reported asynchronously;
that is, you will receive the error a while after causing it.
To debug your program, run it with the GDK_SYNCHRONIZE environment
variable to change this behavior. You can then get a meaningful
backtrace from your debugger if you break on the gdk_x_error() function.)
For the time being, workaround is building it yourself as native release. You get the gimped GTK file picker and it's not complying to the DE's own inbuilt one, but better that than nothing.
After a bit of testing in a fresh linux installation, it seems the issue is something that has to do with Wayland. At least In my case... or with some strange interaction with gtk. Instead of working with a native release, I ended up just temporarily switch to a Xorg session. This allowed the file picker to work correctly.
The native releases use a x11 backend by default so they are not affected (unless you launch them with the --sdl-video-driver wayland option)
Side note to this: UnleashedRecomp should probably be compiled with support for xdg-desktop-portal instead of relying on the gtk file chooser. This is not only what is usually recommended for desktop integration and sandboxing reasons https://docs.flatpak.org/en/latest/desktop-integration.html#portals But it would probably solve this issue because the system would then use its native file chooser dialog.
In most releases for the native file dialog library it's probably just a matter of passing -DNFD_PORTAL=ON to cmake.