Repository navigation
Reboot and restart required as core runtime flags #1433
TL;DRToday "you need to restart" and "you need to reboot" are signalled ad hoc, once per source, so updating ten HACS integrations gives you ten repairs that all mean the same thing. This proposes two latching runtime states on BackgroundHome Assistant has plenty of ways to tell you "you need to restart" or "you need to reboot," and that is exactly the problem: they are all separate, ad hoc, and per source. Update ten HACS integrations and you are greeted by ten repairs, each telling you to restart. They all mean the same thing and they all resolve with the same single action. Update Home Assistant OS and you get a different repair telling you to reboot. Change a setting that only applies after a restart and you get yet another signal. Every one of these is a bespoke repair issue raised by whoever noticed the need. The user does not care which of the ten things asked for it. They care about one fact: does Home Assistant need a restart, or does the host need a reboot, to be in the state they just asked for. Right now nothing in Core answers that question in one place, so we cannot show one clean indicator, and instead we make the user reason about a pile of notifications that all collapse to the same button. We are missing a single, authoritative answer to a simple question: "is a restart or a reboot pending?" That is the gap this proposal closes. ProposalAdd two boolean runtime states to Core, as attributes of the running instance (
Ownership and lifecycleThe two flags look symmetric but they are not, and this is the part that actually shapes the design.
So Core should not track reboot state itself. Supervisor already does, durably. In That means Core owns surfacing both flags. Even though the reboot state originates in Supervisor, Core is the single place that proxies it to the frontend and anywhere else that needs it, so consumers read one consistent Core contract and never have to know or care that reboot happens to come from Supervisor underneath. Reboot is a Home Assistant OS concept and nothing else. On Container and Core installs there is no managed host and no Supervisor, so The message, and keeping the "why"The indicator carries one generic, translatable headline:
with a matching reboot variant. One translation string, not one per reason. The temptation is to attach a specific reason per source, which is where an earlier attempt at this got messy: translating ten HACS update reasons is not a thing that scales. The fix is to separate the headline from the detail. Keep the headline generic and translatable, and behind the indicator keep a plain list of the integrations that requested it, shown as a "what changed" drill-down. Power users see which integrations are responsible, the headline stays clean, and the only thing we translate is the one headline. The detail is just integration names, so it needs no per reason translation. Making it easy for integrationsRaising a restart is the only thing integrations do here. Reboot is deliberately not on this list: it is entirely a Home Assistant OS matter that Supervisor already raises and tracks itself (see above), so there is no Core side API to request a reboot and nothing to add to the update entity for it. Core only reads and proxies the reboot state. For restart there are two ways to raise it. A general helper in Core, for the cases that are not updates (a config change that only applies after a restart): async_set_restart_required(hass, source)
An Automating on itSome people will want to act on this themselves, for example to send a phone notification when a restart goes pending, or to hold off a routine while one is. So the state is exposed to automations through two triggers and two conditions, one of each per flag:
Changelog
|
Replies: 2 comments
|
This reads quite straight forward and allows too convert these repairs in a nice, native indicator 👍 . Should we maybe also add a reason for reboot? Today, in Supervisor, there are a couple of cases which raise a reboot required issue, most are rather special cases which are available as a CLI configuration only:
We currently don't track a reason though. We have reference and reference_extra where we could add additional data to the issue, so we could add a |
|
This proposal was approved by the core architecture meeting 2026-07-23 |
This proposal was approved by the core architecture meeting 2026-07-23