Bug 436636

Summary: Swap file doesn't work after restoring Plasma session
Product: [Applications] kate Reporter: Piotr Mierzwinski <piotr.mierzwinski>
Component: generalAssignee: KWrite Developers <kwrite-bugs-null>
Status: RESOLVED NOT A BUG    
Severity: normal CC: christoph
Priority: NOR    
Version First Reported In: Git   
Target Milestone: ---   
Platform: Neon   
OS: Linux   
Latest Commit: Version Fixed/Implemented In:
Sentry Crash Report:

Description Piotr Mierzwinski 2021-05-05 14:58:57 UTC
SUMMARY
I set option "Swap file" as "Enabled" in second case as "Alternative Directory". In both cases after I restored Plasma session, where kate was restored with its last session, I got not swapped file.
Both options were worked if I closed kate manully and started it again.

STEPS TO REPRODUCE
1. open any file
2. set option: Configuration -> Open/Save -> Advanced -> Swap file: "Enable" or "Alternative Directory" (with proper path)
2. modify opened file
3. Log out from Plasma or restart system

OBSERVED RESULT
kate loads original, not mofied file

EXPECTED RESULT
kate should load swapped file, like it happens in case if user close application manually and run it again

SOFTWARE/OS VERSIONS
Linux/KDE Plasma: 
KDE Plasma Version: 5.21.80
KDE Frameworks Version: 5.82.0
Qt Version: 5.15.2

kate: 21.07.70

ADDITIONAL INFORMATION
Neon updated today (2021/04/05) afternoon.
Comment 1 Christoph Cullmann 2022-10-02 19:53:50 UTC
I think there is a misunderstanding, swap files are only used to recover from crashes, if Kate closes normally like during session save, they have no effects.