Skip to content

Conversation

@jelmer
Copy link
Owner

@jelmer jelmer commented Jan 13, 2026

When PUT requests failed due to precondition errors (e.g., invalid calendar data), the server was returning 207 Multi-Status responses instead of the appropriate status code (e.g., 412 Precondition Failed). This caused Thunderbird to fail when importing ICS files.

The issue was in Status.get_single_body() which raised NeedsMultiStatus whenever an error element was present. Now error elements are properly serialized into the response body as XML while preserving the original status code, per RFC 4918.

Fixes #545

When PUT requests failed due to precondition errors (e.g., invalid
calendar data), the server was returning 207 Multi-Status responses
instead of the appropriate status code (e.g., 412 Precondition Failed).
This caused Thunderbird to fail when importing ICS files.

The issue was in Status.get_single_body() which raised NeedsMultiStatus
whenever an error element was present. Now error elements are properly
serialized into the response body as XML while preserving the original
status code, per RFC 4918.

Fixes #545
@jelmer jelmer merged commit e9da66e into master Jan 13, 2026
29 of 41 checks passed
@jelmer jelmer deleted the single-error branch January 13, 2026 16:45
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.

thunderbird 146.0 (64-bit) can't import ICS server returned 207

2 participants