Request for desktop-launch interface for snapd-desktop-integration

Snapd-desktop-integration needs to read the contents of the .desktop files of snapped applications in order to extract the application icon and the visible name, to use it in refresh notifications (which are being moved from inside snapd into snapd-desktop-integration, to allow more flexibility). Since dektop-launch interface already allows to do that (thus no new interface is required), and snapd-desktop-integration is maintained by Canonical, I’m requesting autoconnection for it.


Hey @SergioCostas ,

I can see that snapd-desktop-integration snap has been granted system-files interface to have read on /snap dir for this very purpose only, see this thread for ref: Autoconnect request for system-files in snapd-desktop-integration

Let me know if read on /snap is not working.


Hi @0xnishit ,

The problem is that what we need to read is any .desktop file placed at /var/lib/snapd/desktop/applications, and there are rules in desktop-legacy that prevents any snap to read the contents of the .desktop files placed there, only allowing to list the files inside (snapd/interfaces/builtin/utils.go at 64aee549b53cceb87e16bf3389548832fea9f31f · snapcore/snapd · GitHub). I tried adding that path to the system-files interface, but still those rules prevent accessing.

A patch for desktop-launch interface is awaiting merge, that will detect if it is connected and override those rules (interfaces: give priority to desktop-launch over desktop-legacy by sergio-costas · Pull Request #13933 · snapcore/snapd · GitHub).

Is the desktop-legacy plug actually needed in this case? Could you remove it to get rid of these rules?

the desktop-legacy plug is automatically connected if you connect the desktop plug. Also, I need the unity7plug too, which also includes those same rules.

Ah ok - in that case, desktop-launch (with the in-progress PR for snapd mentioned earlier) is the only way to achieve this functionality for snapd-desktop-integration. +1 from me.

1 Like

Sounds reasonable, +1 from me as well

1 Like

It also sounds fine to me.

3 votes for, 0 against. Granting Snapd-desktop-integration *auto-connection to desktop-launch interface. This is now live.

1 Like