1
0
mirror of https://github.com/home-assistant/core.git synced 2025-12-24 21:06:19 +00:00

Enable ruff RUF005 and fix occurrences (#113589)

This commit is contained in:
Sid
2024-03-16 18:37:20 +01:00
committed by GitHub
parent 2a5c85a020
commit ccd2e989c3
58 changed files with 150 additions and 128 deletions

View File

@@ -506,7 +506,7 @@ async def async_hass_config_yaml(hass: HomeAssistant) -> dict:
await merge_packages_config(hass, config, core_config.get(CONF_PACKAGES, {}))
except vol.Invalid as exc:
suffix = ""
if annotation := find_annotation(config, [CONF_CORE, CONF_PACKAGES] + exc.path):
if annotation := find_annotation(config, [CONF_CORE, CONF_PACKAGES, *exc.path]):
suffix = f" at {_relpath(hass, annotation[0])}, line {annotation[1]}"
_LOGGER.error(
"Invalid package configuration '%s'%s: %s", CONF_PACKAGES, suffix, exc