Skip to main content
Topic: D-bus, distrobox, flatpaks are faulty (Read 812 times) previous topic - next topic
0 Members and 2 Guests are viewing this topic.

D-bus, distrobox, flatpaks are faulty

I'm using OpenRC.
When i try, for example, running foliate as a flatpak, i get errors like:
Code: [Select]
➜  ~ flatpak run com.github.johnfactotum.Foliate

(com.github.johnfactotum.Foliate:2): Gjs-CRITICAL **: 02:03:05.265: Attempting to run a JS callback during shutdown. This is most likely caused by destroying a Clutter actor or GTK widget with ::destroy signal connected, or using the destroy(), dispose(), or remove() vfuncs. Because it would crash the application, it has been blocked.
The offending callback was ListBoxUpdateHeaderFunc().
== Stack trace for context 0x55ed998dd0d0 ==

But what actually happens is when i try opening a file it just doesn't do anything, only when i close the application it repeatedly prints the above in the terminal.

But when i attempt to run flatpak in a debian distrobox:
Code: [Select]
~ distrobox-create --name flatpak-box2 --image debian:bookworm --additional-packages "flatpak dbus-x11 pulseaudio pavucontrol git curl wget x11-apps" --additional-flags "--tmpfs /run --tmpfs /run/lock --volume /tmp/.X11-unix:/tmp/.X11-unix:rw"
~ distrobox-enter flatpak-box2
~ sudo apt update
~ sudo apt install flatpak
~ sudo flatpak remote-add --if-not-exists flathub https://dl.flathub.org/repo/flathub.flatpakrepo
~ flatpak install com.github.johnfactotum.Foliate
Looking for matches?
Required runtime for com.github.johnfactotum.Foliate/x86_64/stable (runtime/org.gnome.Platform/x86_64/48) found in remote flathub
Do you want to install it? [Y/n]:

com.github.johnfactotum.Foliate permissions:
    ipc    network    fallback-x11    pulseaudio    wayland    x11    dri    file access [1]

    [1] xdg-run/speech-dispatcher:ro


        ID                                                       Branch                 Op             Remote              Download
 1. [?] com.github.johnfactotum.Foliate.Locale                   stable                 i              flathub              218.9?kB / 206.2?kB
 2. [?] org.freedesktop.Platform.GL.default                      24.08                  i              flathub              144.7?MB / 145.0?MB
 3. [?] org.freedesktop.Platform.GL.default                      24.08extra             i              flathub               23.9?MB / 145.0?MB
 4. [?] org.freedesktop.Platform.GL.nvidia-580-76-05             1.4                    i              flathub              321.3?MB / 321.8?MB
 5. [?] org.freedesktop.Platform.openh264                        2.5.1                  i              flathub              914.3?kB / 971.4?kB
 6. [?] org.gnome.Platform.Locale                                48                     i              flathub              253.8?MB / 394.4?MB
 7. [?] org.gnome.Platform                                       48                     i              flathub              422.3?MB / 400.0?MB
 8. [ ] com.github.johnfactotum.Foliate                          stable                 i              flathub             < 11.7?MB

Warning: Failed to get revokefs-fuse socket from system-helper: Unable to connect to system bus
Warning: Unable to connect to system bus
Warning: Failed to get revokefs-fuse socket from system-helper: Unable to connect to system bus
Warning: Unable to connect to system bus
Warning: Failed to get revokefs-fuse socket from system-helper: Unable to connect to system bus
Warning: Unable to connect to system bus
Warning: Failed to get revokefs-fuse socket from system-helper: Unable to connect to system bus
Warning: Unable to connect to system bus
Warning: Failed to get revokefs-fuse socket from system-helper: Unable to connect to system bus
Warning: Unable to connect to system bus
Warning: Failed to get revokefs-fuse socket from system-helper: Unable to connect to system bus
Warning: Unable to connect to system bus
Warning: Failed to get revokefs-fuse socket from system-helper: Unable to connect to system bus
Error: Unable to connect to system bus
error: Failed to install org.gnome.Platform: Unable to connect to system bus


Re: D-bus, distrobox are faulty

Reply #1
Forgot to mention that my distrobox is also having trouble to stop or remove:

~ distrobox-list                            
ID           | NAME                 | STATUS             | IMAGE                        
8ef97f88ae4e | flatpak-box          | Stopping           | docker.io/library/debian:bookworm
8531c3d71bd8 | flatpak-box2         | Up 12 minutes      | docker.io/library/debian:bookworm

~ distrobox-stop flatpak-box2               
Do you really want to stop flatpak-box2? [Y/n]:
WARN[0010] StopSignal SIGTERM failed to stop container flatpak-box2 in 10 seconds, resorting to SIGKILL
Error: given PID did not die within timeout

It's not a big deal because i can just reboot but still it signals a problem on dbus setting i'm not being able to solve on my own (noob)

Re: D-bus, distrobox, flatpaks are faulty

Reply #2
Both of your issues are known. For Distrobox, the developer says the fix to make installing Flatpaks within it work is likely to cause issues with other programs, and the Foliate log spam happens on other distros (even systemd ones) too.

Tbh, it's pretty weird to run one container solution inside another.

 

Re: D-bus, distrobox, flatpaks are faulty

Reply #3
It was just to illustrate dbus related problems, i fixed my foliate (ad other flatpaks) problem for instance when i installed xdg-desktop-portal-gtk , killed the xdg processes and relogged. But i still have my $DBUS_SESSION_BUS_ADDRESS pointing to a fallback in /tmp, not sure if this is expected in default artix setup:

➜  ~ echo $DBUS_SESSION_BUS_ADDRESS                    
unix:path=/tmp/dbus-7s...

Re: D-bus, distrobox, flatpaks are faulty

Reply #4
It was just to illustrate dbus related problems

None of these problems were related to how D-Bus was setup. The first (missing file selector) was due to your system missing an XDG desktop portal with file picker support, and Distrobox intentionally does not expose the system bus inside containers. Both of these could've happened on, e.g. Arch or a minimal install of Debian.

Quote
But i still have my $DBUS_SESSION_BUS_ADDRESS pointing to a fallback in /tmp, not sure if this is expected in default artix setup:

➜  ~ echo $DBUS_SESSION_BUS_ADDRESS                    
unix:path=/tmp/dbus-7s...

This is expected. Unless you install user services support, D-Bus is spawned by your GUI and listens on a random location.