xdg-desktop-portal-gtk
xdg-desktop-portal-gtk copied to clipboard
org.freedesktop.portal.Background interface completely missing
Issue: org.freedesktop.portal.Background interface does not seem to exist with this backend.
Hi. I run Debian Trixie on an AMD64 system with XFCE4. I ran into an issue with a Flatpak program called Emote that was failing to start due to, as the thread later came to the conclusion, a failure to set itself up as a background task due to issues with the Freedesktop API. (See tom-james-watson/Emote#117. While messing around, I saw that the org.freedesktop.portal.Background object was missing from the org.freedesktop.portal.Desktop bus and could not get it to work. After testing in Arch and Fedora VMs, and later the Debian host, I found that installing xdg-desktop-portal-gnome solved the problem, initiating org.freedesktop.portal.Background and allowing the application to start.
Thus, this leads me to conclude that something is missing or wrong in this repository that leads the background interface to not initiate. I think this may have existed since 2020 with issue #296.
This repo does have the portal if you build with --enable-background
. However the reason it was disabled by default is because it was specific to GNOME-Shell and was moved to -gnome
.
The portal requires desktop integration to be really useful so it belongs in those implementations.
I ran into an issue with a Flatpak program called Emote that was failing to start
I would expect it to return an error instead of hanging. But I think that would be a bug for xdg-desktop-portal
itself?
It doesn't hang; It returns what at first glance seems like a type error, but upon further inspection is because of the lack of the Background interface. I wonder if a fallback could be written, either in this or xdg-desktop-portal, for desktops that don't support the interface to instead create a .desktop entry in ~/.config/autostart. Should I start a different bug report upstream?
You should install the appropriate backend for your desktop environment. It is not a bug that the non-desktop-specific -gtk
backend doesn't know your desktop environment's preferred way to set the background.
I wonder if a fallback could be written, either in this or xdg-desktop-portal, for desktops that don't support the interface to instead create a .desktop entry in ~/.config/autostart
I don't think we should get into writing fallback implementations that will "fight" with whatever mechanism your desktop environment wants to use to manage the background.