wwmm / easyeffects

Limiter, compressor, convolver, equalizer and auto volume and many other plugins for PipeWire applications
GNU General Public License v3.0
6.16k stars 265 forks source link

Flatpak: "Launch Service at System Startup" and "Shutdown on Window Closing" toggles don't work #2869

Open amsyarzero opened 5 months ago

amsyarzero commented 5 months ago

EasyEffects Version

7.1.3

What package are you using?

Flatpak (Flathub)

Distribution

Arch Linux

Describe the bug

I cannot seem to enable Launch Service and disable Shutdown on Window Closing, no matter what. This issue is very similar to #2426.

System specs

OS: Arch Linux x86_64
Host: HP Pavilion Gaming Laptop 15-dk0xxx
Kernel: 6.7.1-arch1-1
Packages: 688 (pacman), 30 (flatpak)
Shell: bash 5.2.26
WM: LeftWM
CPU: Intel i7-9750H (12) @ 4.500GHz
GPU: Intel CoffeeLake-H GT2 [UHD Graphics 630]
GPU: NVIDIA GeForce GTX 1650 Mobile / Max-Q
Memory: 4350MiB / 15836MiB

Backends used

# leftwm-portals.conf
[preferred]
# use gtk for every portal interface
default=gtk

Autostart file

[Desktop Entry]
Type=Application
Name=EasyEffects
Comment=EasyEffects background service
Exec=nohup flatpak run --command=easyeffects com.github.wwmm.easyeffects --gapplication-service
X-Flatpak=com.github.wwmm.easyeffects

Fixes tried

Fixes Result
Reinstalling both backends Problem persists
Installing xdg-desktop-portal-gnome to provide Background portal in leftwm-portals.conf Problem persists
Reinstalling EasyEffects Problem persists
Restarting computer after reinstalling Problem persists
Putting an autostart file Opens on launch minimized, but re-opening and closing causes problem to come back (as detailed here in #1668)
Running flatpak permission-reset com.github.wwmm.easyeffects Problem persists

Expected Behavior

Debug Log

Debug Log
```bash (easyeffects:2): easyeffects-WARNING **: 17:03:58.761: libportal.cpp:70 Background access has been denied (easyeffects:2): easyeffects-WARNING **: 17:03:58.762: libportal.cpp:71 Please allow Easy Effects to ask again with flatpak permission-reset com.github.wwmm.easyeffects (easyeffects:2): easyeffects-WARNING **: 17:03:58.784: libportal.cpp:84 due to error, setting autostart state and switch to false (easyeffects:2): easyeffects-WARNING **: 17:04:08.736: libportal.cpp:70 Background access has been denied (easyeffects:2): easyeffects-WARNING **: 17:04:08.736: libportal.cpp:71 Please allow Easy Effects to ask again with flatpak permission-reset com.github.wwmm.easyeffects (easyeffects:2): easyeffects-WARNING **: 17:04:08.755: libportal.cpp:95 due to error, setting shutdown on window close state and switch to true ```

Additional Information

For some reason, when I run flatpak permission-show on any app (including EasyEffects), nothing shows up.

amsyarzero commented 5 months ago

I've discovered that this issue may be with my Flatpak setup in general rather than EasyEffects, as trying to enable scheduled backups in Pika Backup (Flatpak) throws a similar error. Pika Backup showing that the background portal does not exist.

I'll try re-installing xdg-desktop-portal-gnome and see if it can provide background access.

UPDATE: Installing xdg-desktop-portal-gnome doesn't work. This is even after including it in leftwm-portals.conf:

# leftwm-portals.conf
[preferred]
# use gtk for every portal interface
default=gtk
# use gnome for background
org.freedesktop.impl.portal.Background=gnome
wwmm commented 5 months ago

Does flatpak permission-reset com.github.wwmm.easyeffects change anything?

wwmm commented 5 months ago

I've discovered that this issue may be with my Flatpak setup in general rather than EasyEffects, as trying to enable scheduled backups in Pika Backup (Flatpak) throws a similar error.

I see. @vchernin is this still working on your computer? I wonder if the change in the dbus server recently could be somehow related to the error messages in the image.

violetmage commented 5 months ago

you can use busctl (cli), bustle (flatpak), or dspy (flatpak) to look at what exists / what's happening on your dbus.

My guess is that either the background portal failed to install, or failed to register with your dbus server.

violetmage commented 5 months ago

you could also just try the Door Knocker or ASHPD Demo flatpaks, which are simple test apps for the various portals.

amsyarzero commented 5 months ago

Does flatpak permission-reset com.github.wwmm.easyeffects change anything?

@wwmm Thank you for the suggestion. Unfortunately, the problem still persists. I'll add it to the Fixes Tried section in my original post.

amsyarzero commented 5 months ago

Thank you for the suggestion, @violetmage .

you can use busctl (cli), bustle (flatpak), or dspy (flatpak) to look at what exists / what's happening on your dbus.

My guess is that either the background portal failed to install, or failed to register with your dbus server.

Using Bustle, here's what happens when I try to choose Launch Service at System Startup or Shutdown on Window Closing in EasyEffects. Bustle showing that the Background portal doesn't exist on my setup.

Meanwhile, with ASHPD Demo, the Background portal test fails to run. ASHPD Demo showing that the Background portal test fails.

jaum20 commented 4 months ago

any update on this? I have the same problem

FairplexVR commented 3 months ago

Does flatpak permission-reset com.github.wwmm.easyeffects change anything?

Worked for me, but required a reboot to get the permission request again