{"record":{"id":"62140de9d545311b","repo":"home-assistant/core","slug":"caldav-lookup-error-err","errorCode":null,"errorMessage":"CalDAV lookup error: {err}","messagePattern":"CalDAV lookup error: (.+?)","errorType":"exception","errorClass":"HomeAssistantError","httpStatus":null,"severity":"error","filePath":"homeassistant/components/caldav/todo.py","lineNumber":157,"sourceCode":"                partial(self._calendar.save_todo, **item_data),\n            )\n            # refreshing async otherwise it would take too much time\n            self.hass.async_create_task(self.async_update_ha_state(force_refresh=True))\n        except (requests.ConnectionError, requests.Timeout, DAVError) as err:\n            raise HomeAssistantError(f\"CalDAV save error: {err}\") from err\n\n    @override\n    async def async_update_todo_item(self, item: TodoItem) -> None:\n        \"\"\"Update a To-do item.\"\"\"\n        uid: str = cast(str, item.uid)\n        try:\n            todo = await self.hass.async_add_executor_job(\n                self._calendar.todo_by_uid, uid\n            )\n        except NotFoundError as err:\n            raise HomeAssistantError(f\"Could not find To-do item {uid}\") from err\n        except (requests.ConnectionError, requests.Timeout, DAVError) as err:\n            raise HomeAssistantError(f\"CalDAV lookup error: {err}\") from err\n        vtodo = todo.icalendar_component  # type: ignore[attr-defined]\n        vtodo[\"SUMMARY\"] = item.summary or \"\"\n        if status := item.status:\n            vtodo[\"STATUS\"] = TODO_STATUS_MAP_INV.get(status, \"NEEDS-ACTION\")\n        if due := item.due:\n            todo.set_due(due)  # type: ignore[attr-defined]\n        else:\n            vtodo.pop(\"DUE\", None)\n        if description := item.description:\n            vtodo[\"DESCRIPTION\"] = description\n        else:\n            vtodo.pop(\"DESCRIPTION\", None)\n        try:\n            await self.hass.async_add_executor_job(\n                partial(\n                    todo.save,\n                    no_create=True,\n                    obj_type=\"todo\",","sourceCodeStart":139,"sourceCodeEnd":175,"githubUrl":"https://github.com/home-assistant/core/blob/58a3fdb3ea0538617f0a07efcfba6294de64fd59/homeassistant/components/caldav/todo.py#L139-L175","documentation":"HomeAssistantError raised in async_update_todo_item when the todo_by_uid lookup fails at the transport/DAV level (requests.ConnectionError, requests.Timeout, or DAVError) rather than with NotFoundError. The message embeds the underlying exception text.","triggerScenarios":"Updating a to-do item while the CalDAV server is unreachable, slow beyond the client timeout, or returns an unparseable DAV response for the lookup REPORT query.","commonSituations":"Network outages during item edits, overloaded self-hosted servers, or reverse proxies timing out long REPORT queries on large calendars.","solutions":["Verify server connectivity and latency from the HA host","Reduce calendar size or increase server performance if REPORT queries on big VTODO collections time out","Retry the update once the server responds to a basic request"],"exampleFix":null,"handlingStrategy":"retry","validationCode":null,"typeGuard":null,"tryCatchPattern":"except (requests.ConnectionError, requests.Timeout, DAVError) as err:\n    raise HomeAssistantError(f\"CalDAV lookup error: {err}\") from err","preventionTips":["Monitor server response times; REPORT queries on huge collections are the usual timeout source","Retry the update after confirming basic connectivity","Avoid editing to-dos during known maintenance windows on the server"],"tags":["homeassistant","caldav","todo","network"],"backgroundTag":null,"analyzedSha":"58a3fdb3ea0538617f0a07efcfba6294de64fd59","analyzedAt":"2026-08-14T20:54:38.818Z","schemaVersion":2},"datasetVersion":"2026-08-15T22:17:37.221Z"}