Flatpak telegram.desktop desktop entry problems

kde, wayland, nixos-23.05

what happens:

  • install org.telegram.desktop flatpak (from flathub)
  • try to start telegram from application launcher, from it’s desktop entry
  • get an error: “Failed to execute program org.telegram.desktop: No such file or directory”

starting manually with flatpak run org.telegram.desktop works fine, so it seems that something is wrong with .desktop entry

This started happening about a week-two ago with telegram’s update

I thought i’ve broken something, but then was able to reproduce it on a fresh new system

Looked through flatpak or telegram’s issues - noone has reported anything similar, so i’m assuming this is something NixOS-specific

I have no idea what’s wrong: .desktop file looks fine to me, stock, unchanged, no overrides

edit: searching through discourse stumbled upon this, which might be related: Flatpaks with `DBusActivatable=true` fail to start through menu · Issue #138956 · NixOS/nixpkgs · GitHub

and indeed, the problem see to be the DBusActivatable=true in the desktop file

a workaround would be to copy /var/lib/flatpak/app/org.telegram.desktop/current/active/export/share/applications/org.telegram.desktop.desktop to ~/.local/share/applications/. and removing the line DBusActivatable=true from it

Sorry for making a fuss… (should have started searching from this discourse, not from google…)
at least maybe this post help someone else googling specifically for telegram

hope nixos’s issue will be fixed soon so there won’t be a need for the workaround

5 Likes