mirror of
https://github.com/home-assistant/core.git
synced 2025-07-14 16:57:10 +00:00
Setup integration dependencies before loading it (#23957)
This commit is contained in:
parent
33ed017851
commit
4a70c725b4
@ -343,12 +343,6 @@ async def check_ha_config_file(hass):
|
||||
result.add_error("Integration not found: {}".format(domain))
|
||||
continue
|
||||
|
||||
try:
|
||||
component = integration.get_component()
|
||||
except ImportError:
|
||||
result.add_error("Component not found: {}".format(domain))
|
||||
continue
|
||||
|
||||
if (not hass.config.skip_pip and integration.requirements and
|
||||
not await requirements.async_process_requirements(
|
||||
hass, integration.domain, integration.requirements)):
|
||||
@ -356,6 +350,12 @@ async def check_ha_config_file(hass):
|
||||
', '.join(integration.requirements)))
|
||||
continue
|
||||
|
||||
try:
|
||||
component = integration.get_component()
|
||||
except ImportError:
|
||||
result.add_error("Component not found: {}".format(domain))
|
||||
continue
|
||||
|
||||
if hasattr(component, 'CONFIG_SCHEMA'):
|
||||
try:
|
||||
config = component.CONFIG_SCHEMA(config)
|
||||
|
Loading…
x
Reference in New Issue
Block a user