Skip to content

Commit 3c62292

Browse files
tobixenclaude
andcommitted
Fix Nextcloud test failures and cleanup regime configuration
Changes: 1. Add save-load.reuse-deleted-uid feature definition to document the Nextcloud trashbin bug (issue #30096) 2. Change cleanup-regime from 'none' to 'wipe-calendar' for ephemeral Docker containers (Bedework, Cyrus, Sogo, Nextcloud). This ensures objects are deleted after tests while keeping calendars intact, preventing UID reuse conflicts. 3. Remove 'save-load.reuse-deleted-uid': {'support': 'broken'} from Nextcloud config since caldav-server-tester doesn't explicitly test this feature. The bug is worked around in specific tests that need to delete events. The Nextcloud testCheckCompatibility and testCreateEvent tests now pass consistently with these changes combined with caldav-server-tester fixes. 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
1 parent 3aca035 commit 3c62292

File tree

1 file changed

+9
-8
lines changed

1 file changed

+9
-8
lines changed

caldav/compatibility_hints.py

Lines changed: 9 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -107,6 +107,9 @@ class FeatureSet:
107107
"save-load.todo.recurrences.count": {"description": "The server will receive and store a recurring task with a count set in the RRULE"},
108108
"save-load.todo.mixed-calendar": {"description": "The same calendar may contain both events and tasks (Zimbra only allows tasks to be placed on special task lists)"},
109109
"save-load.journal": {"description": "The server will even accept journals"},
110+
"save-load.reuse-deleted-uid": {
111+
"description": "After deleting an event, the server allows creating a new event with the same UID. When 'broken', the server keeps deleted events in a trashbin with a soft-delete flag, causing unique constraint violations on UID reuse. See https://github.com/nextcloud/server/issues/30096"
112+
},
110113
"save-load.event.timezone": {
111114
"description": "The server accepts events with non-UTC timezone information. When unsupported or broken, the server may reject events with timezone data (e.g., return 403 Forbidden). Related to GitHub issue https://github.com/python-caldav/caldav/issues/372."
112115
},
@@ -820,8 +823,6 @@ def dotted_feature_set_list(self, compact=False):
820823
#'save-load.todo.mixed-calendar': {'support': 'unsupported'}, ## Why? It started complaining about this just recently.
821824
'principal-search.by-name': {'support': 'unsupported'},
822825
'principal-search.list-all': {'support': 'ungraceful'},
823-
# Ephemeral Docker container: no cleanup needed, unique calendars per test
824-
'test-calendar': {'cleanup-regime': 'none'},
825826
'old_flags': ['unique_calendar_ids'],
826827
}
827828

@@ -897,8 +898,8 @@ def dotted_feature_set_list(self, compact=False):
897898
'propfind_allprop_failure',
898899
'duplicates_not_allowed',
899900
],
900-
# Ephemeral Docker container: no cleanup needed
901-
'test-calendar': {'cleanup-regime': 'none'},
901+
# Ephemeral Docker container: wipe objects (delete-calendar not supported)
902+
'test-calendar': {'cleanup-regime': 'wipe-calendar'},
902903
'auto-connect.url': {'basepath': '/ucaldav/'},
903904
"save-load.journal": {
904905
"support": "ungraceful"
@@ -995,8 +996,8 @@ def dotted_feature_set_list(self, compact=False):
995996
"search.recurrences.expanded.exception": {"support": "unsupported"},
996997
'search.time-range.alarm': {'support': 'unsupported'},
997998
'principal-search': {'support': 'ungraceful'},
998-
# Ephemeral Docker container: no cleanup needed
999-
"test-calendar": {"cleanup-regime": "none"},
999+
# Ephemeral Docker container: wipe objects but keep calendar (avoids UID conflicts)
1000+
"test-calendar": {"cleanup-regime": "wipe-calendar"},
10001001
'delete-calendar': {
10011002
'support': 'fragile',
10021003
'behaviour': 'Deleting a recently created calendar fails'},
@@ -1084,8 +1085,8 @@ def dotted_feature_set_list(self, compact=False):
10841085
"support": "ungraceful",
10851086
"behaviour": "Search by name failed: ReportError at '501 Not Implemented - <?xml version=\"1.0\" encoding=\"ISO-8859-1\"?>\n<html xmlns=\"http://www.w3.org/1999/xhtml\">\n<body><h3>An error occurred during object publishing</h3><p>did not find the specified REPORT</p></body>\n</html>\n', reason no reason",
10861087
},
1087-
# Ephemeral Docker container: no cleanup needed
1088-
'test-calendar': {'cleanup-regime': 'none'},
1088+
# Ephemeral Docker container: wipe objects (delete-calendar fragile)
1089+
'test-calendar': {'cleanup-regime': 'wipe-calendar'},
10891090

10901091
}
10911092
## Old notes for sogo (todo - incorporate them in the structure above)

0 commit comments

Comments
 (0)