You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
RFC 4791 §5.2.3 states that absent supported-calendar-component-set means
the server accepts all component types. Previously the method raised
KeyError (fallback path) or returned an empty list (protocol-layer path).
Changes:
- Returns the RFC-compliant component set when the property is absent,
adjusted per compatibility hints (e.g. excludes VTODO if save-load.todo
is unsupported for the given server)
- Fixes async path that returned an unawaited coroutine instead of the result
- Removes dead _find_objects_and_props() fallback code
- Replaces no_supported_components_support flag with get-supported-components
feature, allowing caldav-server-tester to track it
- Adds create-calendar.with-supported-component-types feature definition
Fixes#653
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Copy file name to clipboardExpand all lines: CHANGELOG.md
+1Lines changed: 1 addition & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -18,6 +18,7 @@ This project should adhere to [Semantic Versioning](https://semver.org/spec/v2.0
18
18
19
19
* Reusing a `CalDAVSearcher` across multiple `search()` calls could yield inconsistent results: the first call would return only pending tasks (correct), but subsequent calls would change behaviour because `icalendar_searcher.Searcher.check_component()` mutated the `include_completed` field from `None` to `False` as a side-effect. Fixed by passing a copy with `include_completed` already resolved to `filter_search_results()`, leaving the original searcher object unchanged. Fixes https://github.com/python-caldav/caldav/issues/650
20
20
*`_resolve_properties()` would crash with `UnboundLocalError` in production mode when a server returned an empty or unrecognisable PROPFIND response (the response paths did not match the request URI and there was more than one or zero paths returned). Fixed by returning `{}` instead of falling through to an unbound variable. Related: https://github.com/pycalendar/calendar-cli/issues/114
21
+
*`Calendar.get_supported_components()` raised `KeyError` when the server did not include the `supported-calendar-component-set` property in its response. RFC 4791 section 5.2.3 states this property is optional and that its absence means all component types are accepted; the method now returns the RFC default `["VEVENT", "VTODO", "VJOURNAL"]` in that case, trimmed by any known server limitations from the compatibility hints (e.g. if `save-load.todo` is `unsupported`, `VTODO` is excluded). Fixes https://github.com/python-caldav/caldav/issues/653
Copy file name to clipboardExpand all lines: caldav/compatibility_hints.py
+10-10Lines changed: 10 additions & 10 deletions
Original file line number
Diff line number
Diff line change
@@ -82,6 +82,12 @@ class FeatureSet:
82
82
"get-current-user-principal.has-calendar": {
83
83
"type": "server-observation",
84
84
"description": "Principal has one or more calendars. Some servers and providers comes with a pre-defined calendar for each user, for other servers a calendar has to be explicitly created (supported means there exists a calendar - it may be because the calendar was already provisioned together with the principal, or it may be because a calendar was created manually, the checks can't see the difference)"},
85
+
"get-supported-components": {
86
+
"description": "Server returns the supported-calendar-component-set property (RFC 4791 section 5.2.3). The property is optional: when absent the RFC mandates that all component types are accepted, so 'unsupported' here is not a protocol violation, but the client cannot determine the actual supported set without trying.",
"description": "Server honours the supported-calendar-component-set restriction set at MKCALENDAR time. When 'full', the server both advertises (or enforces) the restriction; when 'unsupported', the restriction is silently ignored (wrong-type objects can be saved to the calendar). When 'ungraceful', the MKCALENDAR request itself fails when a component set is specified.",
90
+
},
85
91
"rate-limit": {
86
92
"type": "client-feature",
87
93
"description": "client (or test code) must sleep a bit between requests. Pro-active rate limiting is done through interval and count, server-flagged rate-limiting is controlled through default_sleep/max_sleep",
"""Robur raises AuthorizationError when trying to access a non-existing resource (while 404 is expected). Probably so one shouldn't probe a public name space?""",
811
817
812
-
'no_supported_components_support':
813
-
"""The supported components prop query does not work""",
814
-
815
818
'no_relships':
816
819
"""The calendar server does not support child/parent relationships between calendar components""",
0 commit comments