From df40c3bf72a0c6117b2c2a46cff181b7d5c73d78 Mon Sep 17 00:00:00 2001 From: "Ricardo (XenGi) Band" Date: Tue, 14 Jul 2026 20:13:41 +0200 Subject: [PATCH] fix --- hosts/www/caldav-export.py | 13 ++++++++++++- 1 file changed, 12 insertions(+), 1 deletion(-) diff --git a/hosts/www/caldav-export.py b/hosts/www/caldav-export.py index bb8f445..295e3b3 100644 --- a/hosts/www/caldav-export.py +++ b/hosts/www/caldav-export.py @@ -45,7 +45,18 @@ def export_calendar(url: str, username: str, password: str, calendar: str) -> Ca print(f" {len(objects)} objects") for obj in objects: - cal = Calendar.from_ical(obj.data) + data = obj.data + + if data is None: + print(f" fetching {obj.url}") + obj.load() + data = obj.data + + if not data: + print(f" skipping empty object {obj.url}") + continue + + cal = Calendar.from_ical(data) for component in cal.walk(): if component.name != "VCALENDAR":