Bug 173034

Summary: alarms whose time has past cause all other alarms to not execute
Product: [Applications] kalarm Reporter: bill p. (aka google01103) <dweeble01103>
Component: generalAssignee: David Jarvie <djarvie>
Status: CLOSED FIXED    
Severity: normal    
Priority: NOR    
Version: unspecified   
Target Milestone: ---   
Platform: openSUSE   
OS: Linux   
Latest Commit: Version Fixed In:
Attachments: KAlarm config file
Calendar containing the problem alarm

Description bill p. (aka google01103) 2008-10-17 15:09:05 UTC
Version:           2.0.4 (using KDE 4.1.2)
OS:                Linux
Installed from:    SuSE RPMs

If an existing alarm that repeats multiple time per day has it's "time" previous to the current time when pc restarted then no alarms will execute

For some reason, maybe because I use hibernate instead of shutdown (?), when I restart the computer and look at kalarm there might be an alarm whose time is yesterday - this seems to keep all alarms set to run today from running until I reset the yesterday alarm to sometime in the future. The alarm that has yesterday's time is a daily repeater with "cancel if late" NOT checked. My understanding is not checking "cancel if late" should cause that alarm to execute when kalarm is once again active if the execute time has past.
Comment 1 David Jarvie 2008-10-19 01:16:53 UTC
I can't reproduce this. Can you please attach your KAlarm config file ($KDEHOME/share/config/kalarmrc) and the alarm calendar file ($KDEHOME/share/apps/kalarm/calendar.ics) where $KDEHOME is likely to be ~/.kde4 . Preferably remove all other alarms except the one which causes the bug, before attaching the calendar file - otherwise, please indicate which alarm to look at.
Comment 2 David Jarvie 2008-10-20 07:44:59 UTC
Created attachment 28035 [details]
KAlarm config file
Comment 3 David Jarvie 2008-10-20 07:45:51 UTC
Created attachment 28036 [details]
Calendar containing the problem alarm
Comment 4 David Jarvie 2008-10-20 07:48:27 UTC
Additional information supplied by the reporter:

I have attached the files requested and a snapshop of what kalarm displays this morning please note that today is the 19th but the first alarm shown (ntpdate.sh) is dated the 18th and that the 2nd alarm (bkup-opera with a "date to" equal to 0) shown has not yet executed. This is a recent problem, say within a couple of weeks but the alarms have been used for years. Once I change the ntpdate.sh alarm time to the future all will be fine!

The attachments are above.
Comment 5 David Jarvie 2008-10-22 00:11:30 UTC
The problem is due to hibernation. After the system wakes up again, KAlarm's timers need to be adjusted to subtract the length of time the system was hibernating. Instead, they continue their countdown not realising that they are now invalid. The fix for this needs investigation as to how KAlarm can recognise that the system has been to sleep.
Comment 6 David Jarvie 2008-11-01 15:36:00 UTC
Fixed for KDE 4.1.3 (SVN commits 874976, 874980). KAlarm now checks every minute whether any alarm is due, rather than going to sleep until the next alarm trigger. This is not ideal, but is currently the only practical solution.