Bug 282535 - Reminders not showing on start if the pc was off at their start time
Summary: Reminders not showing on start if the pc was off at their start time
Alias: None
Product: korganizer
Classification: Applications
Component: reminder daemon (korgac) (show other bugs)
Version: 4.7
Platform: Arch Linux Linux
: NOR normal
Target Milestone: ---
Assignee: kdepim bugs
Depends on:
Reported: 2011-09-22 07:29 UTC by t3ddy
Modified: 2019-07-29 11:58 UTC (History)
11 users (show)

See Also:
Latest Commit:
Version Fixed In: 4.10

Proposed fix using collectionTreeFetched (2.42 KB, patch)
2012-09-17 19:00 UTC, Frank Roscher

Note You need to log in before you can comment on or make changes to this bug.
Description t3ddy 2011-09-22 07:29:13 UTC
Version:           4.7 (using KDE 4.7.1) 
OS:                Linux

Reminders works only if the pc is on when they should start.
Old version of korganizer (before kde 4.7) shown reminders on kde start if the pc was off at their start time.
I think that this behaviour should be reintroduced.

Reproducible: Always

Steps to Reproduce:
Set a reminder for a time you know your pc will be off.

Actual Results:  
On kde start nothing will show up.

Expected Results:  
A popup reminding you of the event.
Comment 1 t3ddy 2011-10-30 21:15:48 UTC
I've also tried with an empty profile, the problem is still present.
Now on KDE 4.7.2
Comment 2 Jack 2011-11-02 23:18:44 UTC
Kubuntu 11.10
KDE 4.7.2
Same problem
 and sometimes fails to load Calendar file ( icalout.ics ) at reboot
Comment 3 t3ddy 2011-11-04 09:49:55 UTC
Still present in KDE 4.7.3
Comment 4 Christian Trippe 2012-01-28 13:29:02 UTC
*** This bug has been confirmed by popular vote. ***
Comment 5 Jan Riel 2012-01-28 14:28:37 UTC
Still present in KDE 4.7.4
Comment 6 t3ddy 2012-01-29 13:44:20 UTC
Still present in 4.8
Comment 7 Luca 2012-04-04 14:27:06 UTC
The same for me:

Kubuntu 11.10 kernel 3.0.0-17 64-bit, Kde 4.8.1 KOrganizer 4.8
Comment 8 flob737 2012-04-14 17:58:11 UTC
By the way, also present in ubuntu 11.10, gnome 3.2.1, korganizer 4.7.3
Comment 9 Luca 2012-05-07 19:00:34 UTC
Still present in Kubuntu 12.04 KDE 4.8.3
Comment 10 Frank Roscher 2012-06-24 18:35:00 UTC
I can "fix" this bug by removing line 143 in korganizer/korgac/koalarmclient.cpp of current git: 

Removing this just causes checkAlarms to be called at a later point instead of right at the time of initialization - so apparently this is a kind of race condition. The list of alarms gets filled too late or korgac is started too early.

As I don't have any knowledge of the codebase I unfortunately won't be able to dig into this much deeper. Please, PIM devs, look into it. This bug really cripples korganizer. I missed several birthdays and other reminders until I even noticed it.
Comment 11 Jörg Afflerbach 2012-07-16 09:02:10 UTC
This issue seems to apply to birthdays and anniversaries from the address book, too. So you better don’t rely on korganizer if you can’t remember your wife’s birthday or your wedding anniversary... ;-) 

Still present here on KDE 4.8.4.
Comment 12 Chris Fritz 2012-08-16 02:25:19 UTC
Still present in KDE 4.9 on Arch Linux.
Comment 13 Frank Roscher 2012-09-17 19:00:28 UTC
Created attachment 73984 [details]
Proposed fix using collectionTreeFetched

The attached patch reliably fixes the bug in my tests. It uses the new collectionTreeFetched signal in git trunk - which was introduced by David Jarvie to fix a similar problem in KAlarm.
Disclaimer: I'm still not too familiar with Akonadi, so there could very well be problems I haven't considered.
Also, while I'm writing this: Wouldn't it be worthwhile to backport David's changes to 4.9 (along with a fix for this bug)?
Comment 14 Frank Roscher 2012-10-29 18:45:54 UTC
This should be fixed in 4.10.
My commit unfortunately wasn't able to close this bug report automatically because I had different mail addresses configured for bugs and commits - so I'll just reproduce the information below:

Prevent KOrganizer from ignoring reminders that trigger during downtime

Wait for all collections to be populated before performing checks for reminders. Avoids the situation where KOrganizer thinks it has already checked for outstanding reminders in all collections even though it only looked at an uninitialized, empty list of collections.
BUG: 282535
FIXED-IN: 4.10
REVIEW: 106824
DIGEST: Makes KOrganizer reminders work reliably again for people who do not have KDE running 24/7. This was broken since the switch to Akonadi.
Comment 15 Andreas Blochberger 2013-04-23 06:33:24 UTC
I have tested this with KDE 4.10 and korganizer still does not remind me of missed events. I guess, this fix did't fix it
Comment 16 Frank Roscher 2013-04-23 15:39:38 UTC
(In reply to comment #15)
> I have tested this with KDE 4.10 and korganizer still does not remind me of
> missed events. I guess, this fix did't fix it

Doesn't it _ever_ remind you of missed events or just sometimes?
"Sometimes" I wouldn't want to rule out, cause... Akonadi. But if it doesn't work at all that would point to a more specific problem on your end.
Comment 17 Andreas Blochberger 2013-04-23 17:36:22 UTC
As a testcase i've created an event for the next day at 7:00 with a reminder 15mins before. Next day i started korganizer at 8:00 and noreminder came up. 
I will create a test calendar today, and see what happens tomorrow. I'll add the following events:
- whole day event with reminder
- event early in the morning, that i will definitly miss ;-)

I'll report tommorow and add the calendar file, if it doesn't work. Because it could alos only be related to a CalDAV resource.
Comment 18 Andreas Blochberger 2013-04-24 17:01:02 UTC
With a local calendar file it works as expected. With a remote calender (CalDAV) it does not work. I have created an event in the past (with Lightning) and then started korganizer. The event was there, but no reminder was shown.
Comment 19 gustavo 2013-04-24 17:11:01 UTC
I reproduced this error in the past with Kontact 4.8 using a CalDAV calendar. I can confirm this happens with CalDAV. Haven't tested without CalDAV.
Comment 20 Frank Roscher 2013-04-27 15:13:53 UTC
Looks to me like a separate bug, maybe in the ETMCalendar itself. Also: As soon as I add a DAV calendar, reminders don't even work for local calendars anymore.
You should open a separate bug report describing this issue. That way it should also get more attention from the people familiar with the affected code - I'm not really the best person in this regard as I neither like nor know Akonadi very well.