Desktop Session Ignored applications doesn't apply for flatpak RustDesk

I am on openSUSE Tumbleweed, I’ve set “(KDE) System Settings > Session > Desktop Session > Ignored applications:” to “rustdesk,konsole” for testing. I am using the flatpak version of RustDesk. Konsole correctly doesn’t get restored, RustDesk always comes back. I’ve confirmed RustDesk not launching for some other reason by temporarily changing to “Start with an empty session”, in which case RustDesk did not open.

As far as I could determine, “rustdesk” is the correct executable name, but I can’t rule out some part of the flatpak structure interfering here. Admittedly I’m not that knowledgeable about flatpaks.

Hi! Just to check, have you tried using the Flatpak package name, com.rustdesk.RustDesk in that ignored box?

If that doesn’t help, it might help to temporarily change the setting in System Settings > Session > Desktop Session to “When session was manually saved”, perform that manual saving without RustDesk open, then switch back to your intended method. There have been some folks mention that following those steps helped “clear out” some stuck or corrupted session settings.

Hopefully something there either works or helps get things moving in a good direction :slight_smile:

Ah crap, I had actually intended to try that one, but then forgot about it. Unfortunately my test just now didn’t yield any more success.

I also tried the manual save method, interestingly I couldn’t use gui logoff or restart the first time after saving the session. Behavior worked as expected after that, but switching it back did not fix the issue.

My best guess is that the session saver uses the command used to originally spawn a process and that one is something like “/usr/bin/flatpak run --branch=stable --arch=x86_64 --command=rustdesk --file-forwarding com.rustdesk.RustDesk @@u %u @@”, which probably isn’t matching the command filter.

Hmm, yes it’s possible that something further would be needed with the executable name. However, if that is consistently happening on your system, then this is starting to seem like a bug - whether there’s an issue handling Flatpaks in general, or just not a clear way for a user to know how to structure that “ignore” line, the effect (and what would be reported) ends up being what you’re experiencing - applications that you’d expect are ignored, get restored anyway.

Before suggesting filing a new bug report, one quick thing to double-check - is RustDesk set up to start itself on login in some way? Checking your Autostart settings should be the way to verify that - if it is set up to be an automatically started app or daemon of some kind - which at least some other remote desktop-type apps, like Remmina, do by default - then it’ll start regardless of what the session restore mechanism does.

Yeah, I’m thinking a bug report might make sense at this point. RustDesk is not set to autostart, which is also why it wouldn’t show up on an empty session. Good call tho to rule it out.

Ah OK - yep, at the core of it, excluding Flatpak applications from session restore seems to not be functioning for you, at least in a way that’s intuitive to configure, so I’d recommend contributing an issue report via the KDE Bugtracking System: Get Involved/Issue Reporting - KDE Community Wiki

Thanks!

I’m not surprised by this. The UI to configure excluded apps is really primitive right now. I’m not even sure what would be the correct thing to enter for a Flatpak or Snap app!

It clearly predates their existence, and needs to be replaced with something more sophisticated that identifies apps by their .desktop files.

1 Like

Nicely done bug report @SEKCobra , and some exciting news on this front, thanks to reports like yours and development work from @sitter with assists from @David_Edmundson and @ngraham :

From This Week in Plasma: Final Plasma 6.3 Features - KDE Blogs

The session restore “Excluded applications” list you can populate yourself now actually takes effect on Wayland. Also, you now list apps by their desktop file names, which lets the feature work for apps whose executable is ambiguous, such as Flatpak apps. (Harald Sitter, 6.3.0. Link 1 and link 2)

1 Like