siyuan-note/siyuan · error
CalDAV: calendar path is invalid
Error message
CalDAV: calendar path is invalid
What it means
CalDAV sentinel error ErrorCalDavCalendarPathInvalid: the request path's depth does not equal the calendar-collection depth expected by GetCalDavPathDepth. The URL addresses something other than a calendar (e.g. a deeper resource or the root), which the calendar lookup cannot handle.
Source
Thrown at kernel/model/caldav.go:82
calendarSupportedComponentSet = []string{"VEVENT", "VTODO"}
defaultCalendar = caldav.Calendar{
Path: CalDavDefaultCalendarPath,
Name: CalDavDefaultCalendarName,
Description: "Default calendar",
MaxResourceSize: calendarMaxResourceSize,
SupportedComponentSet: calendarSupportedComponentSet,
}
calendars = Calendars{
loaded: false,
changed: false,
lock: sync.Mutex{},
calendars: sync.Map{},
calendarsMetaData: []*caldav.Calendar{},
}
ErrorCalDavCalendarNotFound = errors.New("CalDAV: calendar not found")
ErrorCalDavCalendarPathInvalid = errors.New("CalDAV: calendar path is invalid")
ErrorCalDavCalendarObjectNotFound = errors.New("CalDAV: calendar object not found")
ErrorCalDavCalendarObjectPathInvalid = errors.New("CalDAV: calendar object path is invalid")
)
// CalendarsMetaDataFilePath returns the absolute path of the calendars' meta data file
func CalendarsMetaDataFilePath() string {
return DavPath2DirectoryPath(CalDavCalendarsMetaDataFilePath)
}
func GetCalDavPathDepth(urlPath string) CalDavPathDepth {
urlPath = PathCleanWithSlash(urlPath)
return CalDavPathDepth(len(strings.Split(urlPath, "/")) - 1)
}
// GetCardDavPathDepth parses
func ParseCalendarObjectPath(objectPath string) (calendarPath string, objectID string, err error) {
calendarPath, objectFileName := path.Split(objectPath)View on GitHub (pinned to 8641553a1f)
Solutions
- Check the CalDAV URL points at a calendar collection path
- Adjust the client configuration to use the documented calendar path depth
Defensive patterns
Strategy: validation
When it happens
Trigger: Thrown at kernel/model/caldav.go:82 when the library encounters an invalid state.
Common situations: See trigger scenarios.
AI-assisted analysis of siyuan-note/siyuan@8641553a1f (2026-09-11).
Data as JSON: /api/errors/62bedc8d0507202d.
Report an issue: GitHub.