Screenshots on gnome in snap

Hello,

I am a developer for the screenshot application flameshot . We are gearing up for a new release, but I am having issues with our snap version on gnome, tested on Ubuntu 24.04. The flatpak and from source build do not have this issue.

I’ve tested in --devmode with dev confinement and have the same issue, so I don’t think the issue is related to confinement.

The issue I am having is when the application goes to take a screenshot, a dbus error is returned saying “only the focused app is allowed to show a system access dialog”. This is the system dialog to initially grant screenshot permissions on gnome.

You can see in the attached screenshot the flameshot application is in the foreground so I am not sure why I’m getting this error. Again this does not happen in ubuntu 24.04 with the flatpak version of the same source code.

Any troubleshooting tips are appreciate as I’ve pretty much run out of ideas.

Thanks!

Direct link to snapcraft.yaml

I tested the Flatpak version of Flameshot on Ubuntu 24.04 with Gnome, and by default it also fails to take screenshots.

So I assume the problem is not specifically the Snap version.

I was only able to use Flameshot on Ubuntu 24.04 with Gnome when I used the native version, where a window appeared asking me to accept that Flameshot can take screenshots.

I also tested the Snap version of Flameshot on Ubuntu Budgie 25.04, using Wayland thanks to Labwc, and there I had no problems using the Snap version of Flameshot.

I tested Flameshot Snap on KDE Neon, a notification was displayed asking me to click on the Flameshot icon, after that it showed a window asking if I wanted to let Flameshot take screenshots of the screen.

In Gnome this does not happen, the notification appears, but the system does not ask if I want to allow Flameshot to take screenshots.

I tested with the Flatpak version and with the Snap version, both have the same problem.

2025-06-20_03-35