Bug 282591 - KCalCore parses exceptions incorrectly???
Summary: KCalCore parses exceptions incorrectly???
Status: RESOLVED UNMAINTAINED
Alias: None
Product: kdepimlibs
Classification: Applications
Component: kcalcore (show other bugs)
Version: 4.10
Platform: Ubuntu Linux
: NOR normal
Target Milestone: ---
Assignee: Sergio Martins
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2011-09-23 00:01 UTC by Ingo Ratsdorf
Modified: 2017-01-07 22:39 UTC (History)
4 users (show)

See Also:
Latest Commit:
Version Fixed In:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Ingo Ratsdorf 2011-09-23 00:01:58 UTC
Version:           4.7 (using KDE 4.7.1) 
OS:                Linux

Using egroupware 1.9 dev trunk as calendar server and accessing via davgroupware akonadi resource.
Created a repeating event with three attendees, one confirmed. All events showed correctly in KOrganizer and Akonadiconsole.


Reproducible: Always

Steps to Reproduce:
Created an exception to the standard repetition and declined one of the two optional attendees.

Actual Results:  
All repeating events disappeared in Korganiser, only the rejected one occurrence is now left on the day without any attendee information left.

Expected Results:  
All events to remain as previously and only on the exception day one declined attendee.

Event structure returned from egroupware:
================================

BEGIN:VCALENDAR
VERSION:2.0
PRODID:-//eGroupWare//NONSGML eGroupWare Calendar 1.9.003//EN
METHOD:PUBLISH
BEGIN:VTIMEZONE
TZID:Pacific/Auckland
X-LIC-LOCATION:Pacific/Auckland
BEGIN:DAYLIGHT
TZOFFSETFROM:+1200
TZOFFSETTO:+1300
TZNAME:NZDT
DTSTART:19700927T020000
RRULE:FREQ=YEARLY;BYDAY=-1SU;BYMONTH=9
END:DAYLIGHT
BEGIN:STANDARD
TZOFFSETFROM:+1300
TZOFFSETTO:+1200
TZNAME:NZST
DTSTART:19700405T030000
RRULE:FREQ=YEARLY;BYDAY=1SU;BYMONTH=4
END:STANDARD
END:VTIMEZONE
BEGIN:VEVENT
CLASS:PUBLIC
SUMMARY:Jolan swimming
LOCATION:Westwave Aquatic Centre\, Alderman Drive\, Henderson\, Auckland
DTSTART;TZID=Pacific/Auckland:20110903T110000
DTEND;TZID=Pacific/Auckland:20110903T113000
ATTENDEE;CN=Ingo
  Ratsdorf;ROLE=REQ-PARTICIPANT;PARTSTAT=TENTATIVE;CUTYPE=INDIVIDUAL;RSVP=FA
 LSE;EMAIL=ingo@envirology.co.nz;X-EGROUPWARE-UID=5:MAILTO:ingo@envirology.c
 o.nz
ATTENDEE;CN=Tatjana
  Ratsdorf;ROLE=REQ-PARTICIPANT;PARTSTAT=TENTATIVE;CUTYPE=INDIVIDUAL;RSVP=FA
 LSE;EMAIL=tatjana@envirology.co.nz;X-EGROUPWARE-UID=8:MAILTO:tatjana@enviro
 logy.co.nz
ATTENDEE;CN=Jolan
  Ratsdorf;ROLE=REQ-PARTICIPANT;PARTSTAT=ACCEPTED;CUTYPE=INDIVIDUAL;RSVP=FAL
 SE;EMAIL=jolan@envirology.co.nz;X-EGROUPWARE-UID=11:MAILTO:jolan@envirology
 .co.nz
RRULE:FREQ=WEEKLY;BYDAY=SA;UNTIL=20110930T221500Z
EXDATE;TZID=Pacific/Auckland;VALUE=DATE-TIME:20110827T110000
PRIORITY:5
TRANSP:OPAQUE
CATEGORIES:Family
UID:13b437a6-87a4-432d-b1b9-db63721d78df
SEQUENCE:2
STATUS:CONFIRMED
CREATED:20110816T024519Z
LAST-MODIFIED:20110922T224302Z
DTSTAMP:20110922T225702Z
END:VEVENT
BEGIN:VEVENT
CLASS:PUBLIC
SUMMARY:Jolan swimming
LOCATION:Westwave Aquatic Centre\, Alderman Drive\, Henderson\, Auckland
DTSTART;TZID=Pacific/Auckland:20110924T110000
DTEND;TZID=Pacific/Auckland:20110924T113000
ATTENDEE;CN=Ingo
  Ratsdorf;ROLE=REQ-PARTICIPANT;PARTSTAT=DECLINED;CUTYPE=INDIVIDUAL;RSVP=FAL
 SE;EMAIL=ingo@envirology.co.nz;X-EGROUPWARE-UID=5:MAILTO:ingo@envirology.co
 .nz
ATTENDEE;CN=Tatjana
  Ratsdorf;ROLE=REQ-PARTICIPANT;PARTSTAT=TENTATIVE;CUTYPE=INDIVIDUAL;RSVP=FA
 LSE;EMAIL=tatjana@envirology.co.nz;X-EGROUPWARE-UID=8:MAILTO:tatjana@enviro
 logy.co.nz
ATTENDEE;CN=Jolan
  Ratsdorf;ROLE=REQ-PARTICIPANT;PARTSTAT=ACCEPTED;CUTYPE=INDIVIDUAL;RSVP=FAL
 SE;EMAIL=jolan@envirology.co.nz;X-EGROUPWARE-UID=11:MAILTO:jolan@envirology
 .co.nz
PRIORITY:5
TRANSP:OPAQUE
CATEGORIES:Family
UID:13b437a6-87a4-432d-b1b9-db63721d78df
RECURRENCE-ID;TZID=Pacific/Auckland:20110924T110000
SEQUENCE:2
STATUS:CONFIRMED
CREATED:20110816T024519Z
LAST-MODIFIED:20110922T224302Z
DTSTAMP:20110922T225702Z
END:VEVENT
END:VCALENDAR

================================

Event information shown in Akonadiconsole raw payload:

================================
BEGIN:VCALENDAR
PRODID:-//K Desktop Environment//NONSGML libkcal 3.2//EN
VERSION:2.0
BEGIN:VEVENT
CREATED:20110922T233219Z
DTSTAMP:20110922T224853Z
UID:13b437a6-87a4-432d-b1b9-db63721d78df
SEQUENCE:2
LAST-MODIFIED:20110922T224302Z
SUMMARY:Jolan swimming
LOCATION:Westwave Aquatic Centre\, Alderman Drive\, Henderson\, Auckland
STATUS:CONFIRMED
PRIORITY:5
CATEGORIES:Family
RECURRENCE-ID;TZID=Pacific/Auckland:20110924T110000
DTSTART;TZID=Pacific/Auckland:20110924T110000
DTEND;TZID=Pacific/Auckland:20110924T113000
TRANSP:OPAQUE
END:VEVENT

END:VCALENDAR

================================

However the events are shown exactly as expected in lightning 1.0b5 and on the iphone 4.3.5.
Comment 1 Ingo Ratsdorf 2011-09-23 19:51:38 UTC
Possibly related to Bug 282317?
Comment 2 Ingo Ratsdorf 2011-11-02 01:31:31 UTC
Possibly related to bug #282591?
Comment 3 Philipp Schmidt 2012-08-03 07:45:48 UTC
Can confirm this with my ownCloud Server.

Android also generates a Status=Cancelled for a single recurrence ID. The Payload of the ics is as follows:

BEGIN:VEVENT
CREATED:20120803T071001Z
LAST-MODIFIED:20120803T071029Z
DTSTAMP:20120803T071029Z
UID:d9833f16-a0ea-4855-9404-add90e165e98
SUMMARY:Test Event
RRULE:FREQ=DAILY;UNTIL=20120817T080000Z;INTERVAL=2
DTSTART;TZID=Europe/Berlin:20120806T100000
DTEND;TZID=Europe/Berlin:20120806T110000
LOCATION:asdf
END:VEVENT

BEGIN:VEVENT
LAST-MODIFIED:20120803T071316Z
UID:d9833f16-a0ea-4855-9404-add90e165e98
SUMMARY:Test Event
STATUS:CANCELLED
RECURRENCE-ID:20120810T080000Z
DTSTART;TZID=Europe/Berlin:20120810T100000
DTEND;TZID=Europe/Berlin:20120810T110000
TRANSP:OPAQUE
SEQUENCE:1
END:VEVENT

So the exception is not stored as an EXDATE but rather as a single, additional event with the same UID that only references that specific recurrence. Maybe that is where the problem lies? Does KCalCore discard additional events with the same UID?
Comment 4 Philipp Schmidt 2013-06-05 11:47:22 UTC
I took the liberty of updating the Version (still present in 4.10) and setting the ASSIGNED flag.
Comment 5 Sergio Martins 2013-06-09 17:53:39 UTC
Git commit 242776d314c7f799807e3783b366d2f1b2910a7b by Sergio Martins.
Committed on 09/06/2013 at 19:51.
Pushed by smartins into branch 'master'.

Honour STATUS:CANCELLED

EXDATE isn't the only way to delete an occurrence.
CCMAIL: chrigi_1@fastmail.fm

M  +3    -0    kcalcore/occurrenceiterator.cpp

http://commits.kde.org/kdepimlibs/242776d314c7f799807e3783b366d2f1b2910a7b
Comment 6 Philipp Schmidt 2013-06-14 11:28:14 UTC
I have just checked with the current beta: Events are still being displayed. When comparing a local *.ics with the content of the carddav ressource in akonadiconsole however I stumbled upon the following:

The local *.ics has both events present, the main event and the cancelled one. The carddav-ressource only has the last created event (with status cancelled) but not the main event. So it appears that for carddav further occurences are not synced but ignored when syncing with the server. I will investigate further and open a bug against the affected akonadi-ressource.

So when testing this bug: Use local *.ics files, not a dav-groupware server ;).
Comment 7 Sergio Martins 2013-06-14 14:00:38 UTC
Which revision did you test ?
Comment 8 Philipp Schmidt 2013-06-14 15:32:11 UTC
4.11 Beta 1, it was tagged after the commit if I'm not mistaken and has not yet been branched...
Comment 9 Sergio Martins 2013-06-14 20:06:06 UTC
Can you try again, but editing the file first, replacing Europe/Berlin:20120810T100000 with 20120810T100000Z, and doing the same thing for DTEND
Comment 10 Sergio Martins 2013-06-14 20:06:32 UTC
I mean 20120810T080000Z, sorry
Comment 11 Sergio Martins 2013-06-14 22:17:36 UTC
Git commit b4df81924c221adfd550e1c1dddd55c24818f7cf by Sergio Martins.
Committed on 15/06/2013 at 00:08.
Pushed by smartins into branch 'master'.

Use the same timespec when comparing two KDateTime.

Fixes QHash::contains() not working, and ignoring recurring ids.
CCMAIL: chrigi_1@fastmail.fm

M  +3    -1    kcalcore/occurrenceiterator.cpp

http://commits.kde.org/kdepimlibs/b4df81924c221adfd550e1c1dddd55c24818f7cf
Comment 12 Philipp Schmidt 2013-07-01 10:41:39 UTC
Works for me now for local ICS files. Thank you very much!
Comment 13 Denis Kurz 2016-09-24 20:56:13 UTC
This bug has only been reported for versions before 4.14, which have been unsupported for at least two years now. Can anyone tell if this bug still present?

If noone confirms this bug for a Framework-based version of kdepim (version 5.0 or later, as part of KDE Applications 15.08 or later), it gets closed in about three months.
Comment 14 Denis Kurz 2017-01-07 22:39:54 UTC
Just as announced in my last comment, I close this bug. If you encounter it again in a recent version (at least 5.0 aka 15.08), please open a new one unless it already exists. Thank you for all your input.