New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Don't block Supervisor entry setup with refreshing updates #109809
Conversation
Hey there @home-assistant/supervisor, mind taking a look at this pull request as it has been labeled with an integration ( Code owner commandsCode owners of
|
assert refresh_updates_mock.call_count == 0 | ||
|
||
# There is a REQUEST_REFRESH_DELAYs cooldown on the debouncer | ||
async_fire_time_changed( | ||
hass, dt_util.now() + timedelta(seconds=REQUEST_REFRESH_DELAY) | ||
) | ||
await hass.async_block_till_done() |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This test was actually not correct / not functional this way.
Corrected now.
Tested with various sensors enabled and disabled and restarting on two different production instances. No obvious regressions observed |
Proposed change
On startup, the
hassio
integration will refresh all updates, which can take quite a bit of time (e.g., pulling all git repositories of add-ons). This main cause a global timeout on the first stage:We don't have to block the setup for this; So, this PR removes this call from the startup. Information will be available a bit later (also the Supervisor does update that info on a schedule as well).
Type of change
Additional information
Checklist
ruff format homeassistant tests
)If user exposed functionality or configuration variables are added/changed:
If the code communicates with devices, web services, or third-party tools:
Updated and included derived files by running:
python3 -m script.hassfest
.requirements_all.txt
.Updated by running
python3 -m script.gen_requirements_all
..coveragerc
.To help with the load of incoming pull requests: