Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Flatpak/Wayland] Failed to connect to the bus - Anytype does not start #1122

Open
3 tasks done
SHU-red opened this issue Jan 1, 2025 · 1 comment
Open
3 tasks done
Labels
bug Something isn't working

Comments

@SHU-red
Copy link

SHU-red commented Jan 1, 2025

Have you read a contributing guide?

  • I have read CONTRIBUTING.md
  • I have searched the existing issues and didn't find any that were similar
  • I have considered creating a pull request with fixes instead of a bug report and want to proceed

Current Behavior

  • Anytype installed on Fedora 41/Wayland/Hyprland using Flathub does not start the application
  • Seems to be related to Wayland (see terminal commands below)
  • flatpak run io.anytype.anytype does not work
  • flatpak run --socket=wayland io.anytype.anytype does work

Expected Behavior

Installing Flathub appication and afterwards starting from application launcher should start the app

Steps To Reproduce

  1. Install anytype via flatpak install flathub anytype
  2. Try to launch anytype from application launcher

Environment

> ~ fastfetch                                                                                                                   17:04:54
             .',;::::;,'.                 shured@fedora
         .';:cccccccccccc:;,.             -------------
      .;cccccccccccccccccccccc;.          OS: Fedora Linux 41 (Workstation Edition) x86_64
    .:cccccccccccccccccccccccccc:.        Host: MS-7E27 (1.0)
  .;ccccccccccccc;.:dddl:.;ccccccc;.      Kernel: Linux 6.12.6-200.fc41.x86_64
 .:ccccccccccccc;OWMKOOXMWd;ccccccc:.     Uptime: 1 day, 6 hours, 55 mins
.:ccccccccccccc;KMMc;cc;xMMc;ccccccc:.    Packages: 2740 (rpm), 30 (flatpak), 6 (snap), 52 (brew)
,cccccccccccccc;MMM.;cc;;WW:;cccccccc,    Shell: fish 3.7.0
:cccccccccccccc;MMM.;cccccccccccccccc:    Display (LG ULTRAWIDE): 3440x1440 @ 50 Hz in 34" [External]
:ccccccc;oxOOOo;MMM000k.;cccccccccccc:    WM: Hyprland (Wayland)
cccccc;0MMKxdd:;MMMkddc.;cccccccccccc;    Cursor: Adwaita
ccccc;XMO';cccc;MMM.;cccccccccccccccc'    Terminal: ghostty 1.0.1-1.fc41
ccccc;MMo;ccccc;MMW.;ccccccccccccccc;     CPU: AMD Ryzen 5 7600X (12) @ 5.45 GHz
ccccc;0MNc.ccc.xMMd;ccccccccccccccc;      GPU 1: NVIDIA GeForce RTX 3050 6GB [Discrete]
cccccc;dNMWXXXWM0:;cccccccccccccc:,       GPU 2: AMD Raphael [Integrated]
cccccccc;.:odl:.;cccccccccccccc:,.        Memory: 6.80 GiB / 30.45 GiB (22%)
ccccccccccccccccccccccccccccc:'.          Swap: 0 B / 8.00 GiB (0%)
:ccccccccccccccccccccccc:;,..             Disk (/): 171.11 GiB / 1.82 TiB (9%) - btrfs
 ':cccccccccccccccc::;,.                  Local IP (enp12s0): 192.168.178.20/24
                                          Locale: en_US.UTF-8
> ~ flatpak list | grep anytype                                                                                                 17:04:46
Anytype io.anytype.anytype      0.44.0  stable  flathub system

Anything else?

> ~ flatpak run io.anytype.anytype                                                                          17:00:52
[2:0101/170056.096574:ERROR:bus.cc(407)] Failed to connect to the bus: Failed to connect to socket /run/dbus/system_bus_socket: No such file or directory
Checking for beta autoupdate feature for deb/rpm distributions
Found package-type: deb
LaunchProcess: failed to execvp:
xdg-settings
[2:0101/170056.264801:ERROR:bus.cc(407)] Failed to connect to the bus: Failed to connect to socket /run/dbus/system_bus_socket: No such file or directory
[2:0101/170056.264826:ERROR:bus.cc(407)] Failed to connect to the bus: Failed to connect to socket /run/dbus/system_bus_socket: No such file or directory
[2:0101/170056.264840:ERROR:bus.cc(407)] Failed to connect to the bus: Failed to connect to socket /run/dbus/system_bus_socket: No such file or directory
[2:0101/170056.264853:ERROR:bus.cc(407)] Failed to connect to the bus: Failed to connect to socket /run/dbus/system_bus_socket: No such file or directory
[2:0101/170056.264865:ERROR:bus.cc(407)] Failed to connect to the bus: Failed to connect to socket /run/dbus/system_bus_socket: No such file or directory
[2:0101/170056.265606:ERROR:wayland_connection.cc(197)] Failed to connect to Wayland display: No such file or directory (2)
[2:0101/170056.265618:ERROR:ozone_platform_wayland.cc(264)] Failed to initialize Wayland platform
[2:0101/170056.265622:ERROR:env.cc(258)] The platform failed to initialize.  Exiting.
⋊> ~ flatpak run --socket=wayland io.anytype.anytype
@SHU-red SHU-red added the bug Something isn't working label Jan 1, 2025
@SHU-red SHU-red changed the title [Flatpak/Wayland] [Flatpak/Wayland] Failed to connect to the bus - Anytype does not start Jan 1, 2025
@mhymny
Copy link

mhymny commented Jan 21, 2025

I think you might have some environment variables, that make electron run using wayland(perhaps ELECTRON_OZONE_PLATFORM_HINT=wayland). The flatpak runs on X11 by default. An override should do the trick:
flatpak --user override --nosocket=x11 --socket=wayland --unshare=ipc io.anytype.anytype

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants