Open jelmer opened 7 years ago
Just found out that this is not supported... Would be great to have this feature!
EDIT: Somehow it seems to have worked the second time I tried. Is this already supported?
You can create recurring events and retrieve them, but specific query commands (e.g. date range searches) will only return the recurring event if the first instance is covered by the date range.
Any ideas on how to solve this? (I'm considering to migrate my personal calendar to Xandikos, this is probably the only blocker issue)
We need to expand rrules:
You could probably use the code for CalDAV:expand in Xandikos/CalDAV.py as inspiration (potentially with some refactoring to share more oy the logic).
I've done some work on this, and my draft branch does work but I'm not happy with it in its current form.
It currently expands ics files when generating indexes, which can be really expensive for events that don't have an end date.
The correct solution is to store RRULE, EXDATE, EXRULE, etc in indexes as well and then evaluate those against the specified timerange when filtering.
I will test it
My test code still fails on the expand part, but except for that even my pesky testTodoDatesearch
passed.
I will try to come up with a trivial example of expected vs observed result on a query.
Search query:
<C:calendar-query xmlns:D="DAV:" xmlns:C="urn:ietf:params:xml:ns:caldav">
<D:prop>
<C:calendar-data>
<C:expand start="20081101T160000Z" end="20081103T160000Z"/>
</C:calendar-data>
</D:prop>
<C:filter>
<C:comp-filter name="VCALENDAR">
<C:comp-filter name="VEVENT">
<C:time-range start="20081101T160000Z" end="20081103T160000Z"/>
</C:comp-filter>
</C:comp-filter>
</C:filter>
</C:calendar-query>
event returned:
BEGIN:VCALENDAR
VERSION:2.0
PRODID:-//Example Corp.//CalDAV Client//EN
BEGIN:VEVENT
UID:19970901T130000Z-123403@example.com
DTSTART;VALUE=DATE:19971102
CATEGORIES:ANNIVERSARY,PERSONAL,SPECIAL OCCASION
CLASS:CONFIDENTIAL
DTSTAMP:19970901T130000Z
RRULE:FREQ=YEARLY
SUMMARY:Our Blissful Anniversary
TRANSP:TRANSPARENT
END:VEVENT
END:VCALENDAR
The icalendar data returned is not expanded.
any news about this issue?
rrule et al