6.0.0-git
2019-04-24

[#6183] Kronolith gives premature notifications
Summary Kronolith gives premature notifications
Queue Kronolith
Queue Version HEAD
Type Bug
State Resolved
Priority 1. Low
Owners chuck (at) horde (dot) org, jan (at) horde (dot) org
Requester eric (at) knudstrup (dot) org
Created 2008-02-01 (4100 days ago)
Due
Updated 2008-08-20 (3899 days ago)
Assigned 2008-05-01 (4010 days ago)
Resolved 2008-08-20 (3899 days ago)
Milestone
Patch No

History
2008-08-20 17:28:46 Jan Schneider Assigned to Chuck Hagenbuch
State ⇒ Resolved
 
2008-08-20 17:28:32 CVS Commit Comment #19 Reply to this comment
2008-05-23 19:12:11 Chuck Hagenbuch Version ⇒ HEAD
 
2008-05-01 22:12:24 Jan Schneider Comment #18
Assigned to Jan Schneider
Taken from Chuck Hagenbuch
State ⇒ Assigned
Priority ⇒ 1. Low
Reply to this comment
I still want to take a look why this didn't work with MDB2_Schema.
2008-04-18 21:16:07 Chuck Hagenbuch Comment #17
Assigned to Chuck Hagenbuch
Taken from Horde DevelopersHorde Developers
State ⇒ Resolved
Reply to this comment
Looking at this, I agree with Michael Redinger. Patch committed - thanks!
2008-04-18 21:12:05 Chuck Hagenbuch Assigned to Horde DevelopersHorde Developers
Taken from Jan Schneider
 
2008-03-24 11:33:17 Jan Schneider Comment #16
State ⇒ Assigned
Reply to this comment
Seems to be a problem with MDB2_Schema.
2008-03-24 04:55:17 eric (at) knudstrup (dot) org Comment #15 Reply to this comment
Yes, I used the setup script.
2008-03-23 11:59:39 Michael (dot) Redinger (at) uibk (dot) ac (dot) at Comment #14 Reply to this comment
Right, I did use setup.php.
2008-03-23 11:27:07 Jan Schneider Comment #13 Reply to this comment
I suppose you created the table with the setup.php script the first time?
2008-03-22 21:20:02 Michael (dot) Redinger (at) uibk (dot) ac (dot) at Comment #12 Reply to this comment
You are right - that seems to be some problem with the database.

A closer look at the database showed that all datetime columns where 
set to a '1970'  default:



`alarm_start` datetime NOT NULL default '1970-01-01 00:00:00',

  `alarm_end` datetime default '1970-01-01 00:00:00',

  `alarm_snooze` datetime default '1970-01-01 00:00:00',



I have not the slightest idea how that happened. I started with 
horde-webmail-1.1-rc2 with a clean OS+DB install and only updated the 
files to the latest horde/imp RCs since then (and did not touch the 
database - that is something I always try to avoid because I am not 
well schooled in it ...)



I now dropped the table an recreated it. No more stupid defaults ...



Anyway - I would be nice to know if this solves Eric's problem, too (I 
suppose it does).



Thanks,

Michael
2008-03-22 18:50:44 Jan Schneider State ⇒ Feedback
 
2008-03-22 18:30:40 Jan Schneider Comment #11
Taken from Horde DevelopersHorde Developers
Reply to this comment
Are you sure that alarm_snoozed is a not a NOT NULL column in your 
alarms table? It doesn't make any sense, and I can't reproduce that 
MySQL is supposed to add 1970-01-01 to the alarm_snoozed column if you 
don't specify it. That would be badly broken behavior.
2008-03-21 09:51:09 michael (dot) redinger (at) uibk (dot) ac (dot) at Comment #10
New Attachment: horde-alarms.diff Download
Reply to this comment
I think I found the problem:

I suppose alarm_snooze should not be set to '1970-01-01 00:00:00'? For 
my alarms, this is always true.

(See eric's horde_alarms sample below.)



I tracked the alarm notification to the select statement in 
lib/Horde/Alarm/sql.php, function _list.

One of the conditions is:

alarm_snooze <= $time->rfc3339DateTime()



If alarm_snooze is set to 1970, this is always true.



eg.:

SELECT alarm_id, alarm_uid, alarm_start, alarm_end, alarm_methods, 
alarm_params, alarm_title, alarm_text, alarm_snooze, alarm_internal 
FROM horde_alarms WHERE alarm_dismissed = 0 AND ((alarm_snooze IS NULL 
AND alarm_start <= '2008-03-21T10:10:07') OR alarm_snooze <= 
'2008-03-21T10:10:07') AND (alarm_end IS NULL OR alarm_end >= 
'2008-03-21T10:10:07') AND (alarm_uid = '' OR alarm_uid = 'myuser') 
ORDER BY alarm_start, alarm_end;





I am using a MySQL database. In the horde SQL scripts, alarm_snooze is 
set to DATETIME.

If you insert something into horde_alarms without setting alarm_snooze 
explicitely, it is set to the start of unix time (1970).



Attaching a patch.
2008-03-19 14:14:06 michael (dot) redinger (at) uibk (dot) ac (dot) at Comment #9 Reply to this comment
I am experiencing exactly the same problem:



- notifications are created as soon as a task or event is created

- if the notification method is a popup, the popup keeps reappearing 
every time I select a page.

   changing the alarm method does not help - only deleting the event 
or task or deleting the alarm in the database.

- if the method is email, I immediately get an email

- I used a clean account

- the alarm entry in horde_alarms seems to be quite ok (at least for me)



I am using the latest RCs (RC3 for horde, RC2 for nag and kronolith; I 
  also tried kronolith CVS).



As this happens both with kronolith and turba, I suppose the problem 
is somewhere in the horde code.




2008-03-06 00:33:12 Jan Schneider Assigned to Jan Schneider
Assigned to Horde DevelopersHorde Developers
State ⇒ Assigned
 
2008-02-27 22:56:47 eric (at) knudstrup (dot) org Comment #8 Reply to this comment
Here's one I just created.  The email got sent out immediately after I 
entered it into the calendar.  I'm on RC2 now.

('20080227142103.361826vdkjj1m8n4@knudstrup.org','eknuds','2008-03-26 
16:00:00','2008-04-10 17:00:00','a:1:{i:0;s:4:\"mail\";}',

'a:1:{s:4:\"mail\";a:3:{s:6:\"__desc\";s:0:\"\";s:5:\"email\";s:18:\"eric@knudstrup.org\";s:4:\"body\";s:103:\"We would like to remind you of this upcoming event.\n\ntest\n\nLocation: \n\nDate: 04/10/2008\nTime: 04:00pm\n\n\";}}','test',NULL,'1970-01-01 
00:00:00',0,'a:1:{s:4:\"mail\";a:1:{s:4:\"sent\";b:1;}}')
2008-02-24 12:02:40 Jan Schneider Comment #7 Reply to this comment
And how do the according entry or entries in the horde_alarms table look like?
2008-02-01 01:45:56 eric (at) knudstrup (dot) org Comment #6 Reply to this comment
Sorry for the flood of separate messages.

Here's the information for the event.  I also just got an email 
notification for it:

Category             Unfiled

Location           test

Status           Confirmed

Owner           ektest

Start On           03/02/2008 6:00 am

End On           03/02/2008 7:00 am

Alarm           15 Day(s)

Created           01/31/2008 5:13 pm

Last Modified           01/31/2008 5:22 pm
2008-02-01 01:40:29 eric (at) knudstrup (dot) org Comment #5 Reply to this comment
When I select "Horde" on the left menu I get three or four popups in 
immediate succession.

Also, disabling popups doesn't seem to disable them, even for this new 
account.
2008-02-01 01:36:24 eric (at) knudstrup (dot) org Comment #4 Reply to this comment
Okay, clean account.  I just went back in and changed the notification 
for this event to be 15 days prior (it starts on 3/2).  now I'm 
getting a popup for it whenever I cause a page reload.
2008-02-01 01:32:29 eric (at) knudstrup (dot) org Comment #3 Reply to this comment
Here's my particulars:

Address Book  Address Book (turba)  H3 (2.2-RC1)                      Application is ready.

Calendar Calendar (kronolith) H3 (2.2-RC2)                 Application is ready.

Dynamic Mail Dynamic Mail (dimp) H3 (1.0-RC1)                 Application is ready.

Filters Filters (ingo) H3 (1.2-RC1)                 Application is ready.

Horde Horde (horde) 3.2-RC1                 Application is ready.

Mail Mail (imp) H3 (4.2-RC1)                 Application is ready.

Mobile Mail Mobile Mail (mimp) H3 (1.1-RC1)                 Application is ready.

Notes Notes (mnemo) H3 (2.2-RC1)                 Application is ready.

Tasks Tasks (nag) H3 (2.2-RC1)



Accessing the test.php file for horde and kronolith says it's fine 
(PHP 5.2.5).

I just tried it with a test account and I do see an inline 
notification for an event starting next month.

Still trying to get the popups...
2008-02-01 01:13:43 Chuck Hagenbuch Comment #2
State ⇒ Feedback
Priority ⇒ 2. Medium
Reply to this comment
What Horde version are you using?



Can you reproduce this for a clean test account, or just your own? 
I've never seen this and never heard of anyone else seeing this.
2008-02-01 00:07:59 eric (at) knudstrup (dot) org Comment #1
Type ⇒ Bug
State ⇒ Unconfirmed
Priority ⇒ 3. High
Summary ⇒ Kronolith gives premature notifications
Queue ⇒ Kronolith
Reply to this comment
I am receiving notifications for alarmed events which are months in 
the future.

I also receive popups even though I have disabled popups in my preferences.

These popups come every time I "reload" the browser or switch to a 
different Horde Application.

I am using Firefox 1.5.0.10 from Fedora Core 6.

Saved Queries