https://bugs.kde.org/show_bug.cgi?id=510087

--- Comment #5 from smihael <[email protected]> ---
I have been able to reproduce this issue twice so far by creating one or more
new notes (using a middle-click on the desktop) and then c to simulate a sudden
power loss such as battery drainage.

I have not been able to reproduce the issue by triggering suspend in the
following ways:
* Closing the laptop lid (but I am quite sure data loss occurred in this way in
the past),
* Selecting suspend manually from the system menu,
* Sending a suspend signal directly without going through any DE daemons:  echo
mem | sudo tee /sys/power/state

However, I suspect the outcome might be different if the system remains in
suspend for a longer time instead of being resumed immediately.
This leads me to believe the bug is related to data being cached or stored in
memory without being written to disk.

I also tested by running killall plasmashell, but the issue did not reproduce.
This suggests that another process is responsible for holding the notes'
content in memory.

Additionally, I found that the contents of notes cannot be restored from
~/.local/share/plasma_notes/. This prompted me to investigate when they are
actually written there for permanent storage.

I set up a watch:
notifywait -m -e create -e modify ~/.local/share/plasma_notes/
Setting up watches.
Watches established.

No events are triggered when creating a new note or when suspending the system
through the DE menu. The newly created note is only saved once it is edited,
for example by adding at least one more character.

.local/share/plasma_notes/ CREATE 037b2cb7-1f28-460b-8cc8-75fa31512c
.local/share/plasma_notes/ MODIFY 037b2cb7-1f28-460b-8cc8-75fa31512c
.local/share/plasma_notes/ MODIFY 037b2cb7-1f28-460b-8cc8-75fa31512c

Then the note also survives pressing Alt+SysRq+B.

Here are some details about my setup as requested. 

Operating System: KDE neon User Edition
KDE Plasma Version: 6.4.4
KDE Frameworks Version: 6.17.0
Qt Version: 6.9.1
Kernel Version: 6.14.0-28-generic (64-bit)
Graphics Platform: Wayland
Processors: 8 × Intel® Core™ i7-10510U CPU @ 1.80GHz
Memory: 16 GiB of RAM (15.4 GiB usable)
Graphics Processor 1: Intel® UHD Graphics
Graphics Processor 2: Quadro P520
Manufacturer: HP
Product Name: HP ZBook Firefly 14 G7 Mobile Workstation

-- 
You are receiving this mail because:
You are watching all bug changes.

Reply via email to