maint: Update HACS to 2.0.5

This commit is contained in:
2025-01-28 05:49:12 -08:00
parent 97d51536a9
commit b02e3c0ac7
5 changed files with 10 additions and 7 deletions

View File

@@ -927,9 +927,6 @@ class HacsRepository:
raise HacsException("repository.content.path.local is None")
self.validate.errors.clear()
if not self.can_download:
raise HacsException("The version of Home Assistant is not compatible with this version")
version_to_install = version or self.version_to_download()
if version_to_install == self.data.default_branch:
self.ref = version_to_install

View File

@@ -172,6 +172,7 @@ class HacsPluginRepository(HacsRepository):
def _get_resource_handler(self) -> ResourceStorageCollection | None:
"""Get the resource handler."""
resources: ResourceStorageCollection | None
if not (hass_data := self.hacs.hass.data):
self.logger.error("%s Can not access the hass data", self.string)
return
@@ -180,7 +181,12 @@ class HacsPluginRepository(HacsRepository):
self.logger.warning("%s Can not access the lovelace integration data", self.string)
return
resources: ResourceStorageCollection | None = lovelace_data.get("resources")
if self.hacs.core.ha_version > "2025.1.99":
# Changed to 2025.2.0
# Changed in https://github.com/home-assistant/core/pull/136313
resources = lovelace_data.resources
else:
resources = lovelace_data.get("resources")
if resources is None:
self.logger.warning("%s Can not access the dashboard resources", self.string)