mirror of
https://github.com/home-assistant/supervisor.git
synced 2025-07-19 15:16:33 +00:00
Catch OS-Error (#3924)
This commit is contained in:
parent
f9b474866b
commit
18b43ce767
@ -18,7 +18,7 @@ def read_yaml_file(path: Path) -> dict:
|
||||
try:
|
||||
return _YAML.load(path) or {}
|
||||
|
||||
except (YAMLError, AttributeError) as err:
|
||||
except (YAMLError, AttributeError, OSError) as err:
|
||||
raise YamlFileError(
|
||||
f"Can't read YAML file {path!s} - {err!s}", _LOGGER.error
|
||||
) from err
|
||||
|
Loading…
x
Reference in New Issue
Block a user