Skip to content

fix: send sync-collection with Depth: 0 - #818

Merged
tobixen merged 1 commit into
masterfrom
fix/sync-collection-depth-0
Oct 24, 2026
Merged

tobixen merged 1 commit into
masterfrom
fix/sync-collection-depth-0

Conversation

@tobixen

@tobixen tobixen commented Oct 23, 2026 •

Copy link
Copy Markdown
Member

Credits to @SashankBhamidi for finding this one in PyCalendar/calendaring-sync#33

Testing has been done towards all servers I have access to, none of them cares about the Depth header.

Commit message:

fix: send sync-collection with Depth: 0

RFC 6578 section 3.2 defines the sync-collection REPORT for Depth: 0
only; other values result in 400.  The shared report helper
hard-coded Depth: 1 (correct for calendar-query) and the async
sync_collection() defaulted to 1.  The helper now takes a depth, and
both sync paths send 0.  A probe of all 14 docker and 7 external test
servers found identical results at both depths.

Prompt: The other session reports: A caldav library bug the page reveals: caldav sends sync-collection with Depth: 1, but RFC 6578 defines it for Depth: 0 only. All five servers tolerate it. The cause is _request_report_build_resultlist in caldav/collection.py, which hard-codes depth 1. That is a fix in caldav, not a probe. [finding relayed from another AI session]
Followup-Prompt: All the docker test servers are up.  Please verify that all of them and all external servers can handle Depth 0

Assisted-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Reviewed-by: Tobias Brox <tobias@redpill-linpro.com>

🤖 Generated with Claude Code

RFC 6578 section 3.2 defines the sync-collection REPORT for Depth: 0
only; other values result in 400.  The shared report helper
hard-coded Depth: 1 (correct for calendar-query) and the async
sync_collection() defaulted to 1.  The helper now takes a depth, and
both sync paths send 0.  A probe of all 14 docker and 7 external test
servers found identical results at both depths.

Prompt: The other session reports: A caldav library bug the page reveals: caldav sends sync-collection with Depth: 1, but RFC 6578 defines it for Depth: 0 only. All five servers tolerate it. The cause is _request_report_build_resultlist in caldav/collection.py, which hard-codes depth 1. That is a fix in caldav, not a probe. [finding relayed from another AI session]
Followup-Prompt: All the docker test servers are up.  Please verify that all of them and all external servers can handle Depth 0

Assisted-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Reviewed-by: Tobias Brox <tobias@redpill-linpro.com>
@tobixen
tobixen force-pushed the fix/sync-collection-depth-0 branch from 0e24e45 to 7701e07 Compare October 24, 2026 00:02

@SashankBhamidi SashankBhamidi left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, thank you!

@tobixen
tobixen merged commit 7701e07 into master Oct 24, 2026
17 checks passed
@tobixen
tobixen deleted the fix/sync-collection-depth-0 branch October 24, 2026 10:07
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants