feat(recurring): implement RECURRENCE-ID override handling

- Add `overrides` field to `rem` type to hold single-event REMs from
  non-cancelled overrides
- Add `is_cancelled`, `build_override_rem`, and `collect_overrides` to
  process RECURRENCE-ID override events
- Replace `warn_unhandled_recurring` with `collect_overrides` in the
  collector pipeline
- Fix `separate_master_and_recurrence` partition logic (swapped
  `Left`/`Right`)
- Render override REMs appended to the master REM in `string_of_rem`
This commit is contained in:
2026-05-17 20:04:18 +02:00
parent a5e15fa84f
commit 106aff01bf
3 changed files with 66 additions and 18 deletions

View File

@@ -176,8 +176,8 @@ let separate_master_and_recurrence (events : Icalendar.event list) : Icalendar.e
List.partition_map
(fun (ev, recur_id_opt) ->
match recur_id_opt with
| None -> Right ev
| Some _ -> Left ev)
| None -> Left ev (* no RECURRENCE-ID → master *)
| Some _ -> Right ev (* has RECURRENCE-ID → override *))
recur_ids
in
match master_and_recurrences with