Bug 489289

Summary: wayland fake session restore doesn't open expected apps, while restoring apps intentionally closed before shutdown
Product: [Plasma] plasmashell Reporter: Eugene Savitsky <eugene.savitsky>
Component: Session ManagementAssignee: Plasma Bugs List <plasma-bugs-null>
Status: CONFIRMED ---    
Severity: normal CC: cwo.kde, kde, lassi.vaatamoinen, natalie_clarius, nate, notmart, postix
Priority: NOR Keywords: wayland-only
Version First Reported In: 6.1.0   
Target Milestone: 1.0   
Platform: Other   
OS: Linux   
Latest Commit: Version Fixed/Implemented In:
Sentry Crash Report:

Description Eugene Savitsky 2024-06-27 08:22:54 UTC
Fedora 40, Wayland.

Starting with KDE 6.1.0 (and now on 6.1.1) when the PC starts up, it automatically opens two LibreOffice Sheets windows, that I do not run at all. But fails to open Firefox and Firefox Developer windows, as well as Thunberbird window.
Terminal windows is starting as it should.

And that every time I start up or restart the PC.
Comment 1 cwo 2024-06-27 09:38:58 UTC
See also https://bugs.kde.org/show_bug.cgi?id=488818

Try setting session restore to "start with an empty session" and restart, then re-enable session restore. A corrupt saved session can apparently cause further session saving to fail.
Comment 2 Eugene Savitsky 2024-06-27 09:58:31 UTC
Tried out. 

1. After enabling "start with an empty session" and restart nothing opened as expected. 

2. Opened FF, FF Developer, Thunderbird. 

3. Re-enabled "On last logout" and restarted.

4. After restart again opened:
a) 2 x LibreOffice Calc windows
b) Dolphin

But no of any FF's, nor TB.
Comment 3 Lassi Väätämöinen 2024-06-28 17:36:44 UTC
Does not seem to work on Plasma 6.1.0 on openSUSE Tumbleweed, either.

Operating System: openSUSE Tumbleweed 20240627
KDE Plasma Version: 6.1.1
KDE Frameworks Version: 6.3.0
Qt Version: 6.7.2
Kernel Version: 6.9.6-1-default (64-bit)
Graphics Platform: Wayland
Processors: 12 × AMD Ryzen 5 3600 6-Core Processor
Memory: 15,5 GiB of RAM
Graphics Processor: AMD Radeon RX 580 Series
Manufacturer: Micro-Star International Co., Ltd.
Product Name: MS-7B79
System Version: 4.0
Comment 4 Lassi Väätämöinen 2024-06-28 17:43:34 UTC
(In reply to Lassi Väätämöinen from comment #3)
> Does not seem to work on Plasma 6.1.0 on openSUSE Tumbleweed, either.

I also tried this sequence
1. enable "start with an empty session"
2. Logout + login
3. Empty session started
4. Enable "On last logout" apps restore
5. Logout + login

Plasma started some apps that were saved as manually saved session some time ago. Same happened also when I closed all applications before logout+login. So it just digs out some old session state from somewhere, not the recent session.
Comment 5 Lassi Väätämöinen 2024-06-28 18:20:12 UTC
Basically what you should do for the "fake session restore" is to set the session save/restore method to manual.

https://bugs.kde.org/show_bug.cgi?id=436318#c88


It's very counter-intuitive, if you ask me. Especially since it is not indicated in the settings page in any way.
Comment 6 postix 2025-07-12 12:11:33 UTC
Can confirm. Apps, such as SoftMaker's TextMaker, SimpleScan or Dolphin open up again on login, even when closed intentionally before shutting down. I'm using Fedora 42 with Plasma 6.4.2.