Bug 127290 - Next occurrence prior to event start date
Summary: Next occurrence prior to event start date
Status: RESOLVED UNMAINTAINED
Alias: None
Product: kresources
Classification: Unmaintained
Component: framework (other bugs)
Version First Reported In: unspecified
Platform: Compiled Sources Linux
: NOR normal
Target Milestone: ---
Assignee: kdepim bugs
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2006-05-14 03:03 UTC by Randy Pearson
Modified: 2024-08-11 18:08 UTC (History)
0 users

See Also:
Latest Commit:
Version Fixed In:
Sentry Crash Report:


Attachments
Prevent negative periods patch (457 bytes, patch)
2006-05-14 03:08 UTC, Randy Pearson
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Randy Pearson 2006-05-14 03:03:10 UTC
Version:           svn 3.5 branch (using KDE Devel)
Installed from:    Compiled sources

The next occurrence calculation for events with an UNTIL clause in the RRULE will return a date before the event start date.  When using COUNT in the RRULE, the next occurrence is correct.

The RecurrenceRule::getNextValidDateInterval() function is using a negative periods value and applying it to the start date.

This event has a problem:


Next Occurrence: 05/15/06 03:30 pm

BEGIN:VEVENT
DTSTAMP:20060513T185001Z
ORGANIZER;CN=Randy Pearson:MAILTO:randy@bamafolks.com
CREATED:20051221T222431Z
UID:libkcal-343789519.333
SEQUENCE:1
LAST-MODIFIED:20051221T222548Z
SUMMARY:Intro to Java
CLASS:PUBLIC
PRIORITY:5
RRULE:FREQ=WEEKLY;UNTIL=20060918T050000Z;BYDAY=MO,WE
EXDATE;VALUE=DATE:20060904
DTSTART:20060821T203000Z
DTEND:20060821T233000Z
TRANSP:OPAQUE
BEGIN:VALARM
DESCRIPTION:
ACTION:DISPLAY
TRIGGER;VALUE=DURATION:-PT2H
END:VALARM

END:VEVENT

However, this event works correctly:

Next Occurrence: 08/21/06 08:00 am

BEGIN:VEVENT
DTSTAMP:20060513T185001Z
ORGANIZER;CN=Randy Pearson:MAILTO:randy@bamafolks.com
CREATED:20051207T152831Z
UID:libkcal-2096248965.836
SEQUENCE:1
LAST-MODIFIED:20060222T225404Z
SUMMARY:UNIX Hands-On (Northrup-Grummond)
LOCATION:UAH
CLASS:PUBLIC
PRIORITY:5
RRULE:FREQ=WEEKLY;COUNT=5;BYDAY=MO,TU,WE,TH,FR
DTSTART:20060821T130000Z
DTEND:20060821T170000Z
TRANSP:OPAQUE
BEGIN:VALARM
DESCRIPTION:
ACTION:DISPLAY
TRIGGER;VALUE=DURATION:-PT30M
END:VALARM

END:VEVENT
Comment 1 Randy Pearson 2006-05-14 03:08:49 UTC
Created attachment 16081 [details]
Prevent negative periods patch

When the event has not yet started, toDate is the current system time, which
results in a negative value for periods.  This patch prevents a negative
addition.
Comment 2 Reinhold Kainhofer 2006-11-02 19:06:41 UTC
Reassigning all KOrganizer bug reports and wishes to the newly created 
korganizer-devel mailing list.
Comment 3 Christoph Cullmann 2024-08-11 18:08:29 UTC
Dear reporter, the resources handling got redone for KF5 and KF6 based PIM applications.

If you still encounter the issues you had in the past, please report them to the current maintained and updated PIM applications you use

Thanks a lot!