Reduce hassio startup time (#114588)

This commit is contained in:
J. Nick Koston 2024-04-01 09:58:06 -10:00 committed by GitHub
parent 304ed8bf3d
commit 0732952b32
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -368,7 +368,9 @@ async def async_setup(hass: HomeAssistant, config: ConfigType) -> bool: # noqa:
require_admin=True,
)
await hassio.update_hass_api(config.get("http", {}), refresh_token)
update_hass_api_task = hass.async_create_task(
hassio.update_hass_api(config.get("http", {}), refresh_token), eager_start=True
)
last_timezone = None
@ -481,6 +483,7 @@ async def async_setup(hass: HomeAssistant, config: ConfigType) -> bool: # noqa:
# _async_setup_hardware_integration is called
# so the hardware integration can be set up
# and does not fallback to calling later
await update_hass_api_task
await panels_task
await update_info_task
await push_config_task