chore(fw): take Home Assistant from the nixos-26.05 channel #447

Merged
dominik.polakovics merged 1 commit from lab/20261009-0047 into main 2026-10-09 09:47:40 +02:00

Closes #446

What this does

Drops the separate builtins.fetchGit nixpkgs pin (nixos-unstable 331800d) in hosts/fw/modules/home-assistant/default.nix and lets the hass container take Home Assistant from the host channel. midea_ac moves from the pin to pkgs.home-assistant-custom-components for the same reason.

The HA version does not change. nixos-26.05 (7c8764b7, what fw runs today) ships homeassistant-2026.5.4, the same version the pin provided. The stable channel will stay on 2026.5.x; a newer HA needs a pin to a newer nixpkgs again (see "Going beyond 2026.5" below).

What changes at runtime

Diffed the home-assistant.service PYTHONPATH of the container config before and after (nix-instantiate --eval on hosts/fw/configuration.nix against the channel). 220 site-packages entries; 14 differ:

Package pin (before) channel (after) HA 2026.5.4 pins
python3 3.14.4 3.14.7 >=3.14.2
pyjwt 2.12.1 2.14.0 2.12.1 (nixpkgs backports upstream PR #172893 for 2.13+)
aiodiscover 3.2.3 3.0.0 2.7.1
cached-ipaddress 1.1.1 1.0.1 1.0.1
wakeonlan 3.3.0 3.1.0 3.1.0
aiodns 4.0.0 4.0.4 4.0.4
xmltodict 1.0.2 1.0.4 1.0.4
pillow 12.2.0 12.3.0 12.2.0
idna 3.13 3.15 –
urllib3 2.6.3 2.7.0 –
beautifulsoup4 / soupsieve – 4.14.3 / 2.8.3 4.13.3

Unchanged: homeassistant-2026.5.4, frontend 20260429.4, msmart-ng 2026.4.1, mysqlclient 2.2.7, habluetooth 6.1.0, sqlalchemy 2.0.49, aiohttp 3.13.5, all custom components (midea_ac 2026.4.0, epex_spot 4.1.0, solarbank-planner 0.1.0, lovelace apexcharts-card 2.2.3, scheduler 3.2.13).

Packaging differences in nixpkgs (pkgs/servers/home-assistant/) between the two revisions:

  • patches/nixos-was-never-supported.patch added (release-26.05 880079db): suppresses the "Core installation method is deprecated" repair issue HA raises on non-container installs.
  • patches/pyjwt-2.13-compat.patch added (0960784a): catches jwt.InvalidKeyError in refresh-token validation, needed for pyjwt 2.14.
  • caldav instead of caldav_2 in the package-set override (caldav is not used here).
  • component-packages.nix, frontend.nix, intents.nix, midea_ac, epex_spot, msmart-ng: identical.

Verification

  • scripts/pre-commit dry-build of fw: OK.
  • The service PYTHONPATH after the change still carries msmart-ng and mysqlclient, so the reason midea_ac had to come from the pin (a second, mismatched Python package set) is gone.
  • Container journal on fw for the current boot (2026-10-09 00:45): HA 2026.5.4 starts, custom integrations solarbank_planner, anker_solix, epex_spot, midea_ac, bermuda, hacs load. Nothing in this PR touches the runtime-downloaded ones (hacs 2.0.5, anker_solix 3.5.4, bermuda 0.7.2).
  • No recorder schema change (same HA version), so the MariaDB hass database is untouched. Rollback is a plain nixos-rebuild switch to the previous generation.

Pre-existing issues seen in the journal (not caused or fixed here)

  • ping platform under binary_sensor: is rejected ("does not support platform setup") – entity never loads.
  • ModuleNotFoundError: No module named 'pyipp' – an ipp config entry exists but the component is not in extraComponents.
  • Three template render errors at startup (sensor.sensors_lowest_battery_level|int, sensor.creality_extruder temperature |float) – missing default=.
  • Two deprecated YAML options (exclude at configuration.yaml:1187, entity_id at :1660).
  • Shelly plugs/buttons configured with .cloonar.smart hostnames are rejected ("does not appear to be an IPv4 or IPv6 address").
  • Residual risk: pyjwt 2.14 vs HA's pinned 2.12.1 is covered by the backported patch and is what every nixos-26.05 HA host runs; first login after the switch should be checked once.

Going beyond 2026.5 (not in this PR)

nixos-unstable is at 2026.9.4; upstream is at 2026.10. Blocking item for this config: 2026.6 removed the legacy template platform (platform: template under sensor:/binary_sensor:), still used in default.nix, 3dprinter.nix, battery.nix (×2), light.nix, locks.nix, multimedia.nix (×2), ac.nix. Those 10 blocks must move to the template: key first. Other upstream breaking changes between 2026.6 and 2026.10 that touch integrations used here: Shelly and ESPHome Bluetooth scanner mode defaults to Auto (2026.6); update install actions and mqtt.publish require an admin account (2026.9, 2026.10); legacy auth-provider username mode removed (2026.10). Also HACS 2.0.5, bermuda 0.7.2 and anker_solix 3.5.4 would need compatibility checks.

🤖 Generated with Claude Code

Closes #446 ## What this does Drops the separate `builtins.fetchGit` nixpkgs pin (nixos-unstable `331800d`) in `hosts/fw/modules/home-assistant/default.nix` and lets the hass container take Home Assistant from the host channel. `midea_ac` moves from the pin to `pkgs.home-assistant-custom-components` for the same reason. **The HA version does not change.** nixos-26.05 (`7c8764b7`, what `fw` runs today) ships `homeassistant-2026.5.4`, the same version the pin provided. The stable channel will stay on 2026.5.x; a newer HA needs a pin to a newer nixpkgs again (see "Going beyond 2026.5" below). ## What changes at runtime Diffed the `home-assistant.service` `PYTHONPATH` of the container config before and after (`nix-instantiate --eval` on `hosts/fw/configuration.nix` against the channel). 220 site-packages entries; 14 differ: | Package | pin (before) | channel (after) | HA 2026.5.4 pins | |---|---|---|---| | python3 | 3.14.4 | 3.14.7 | >=3.14.2 | | pyjwt | 2.12.1 | 2.14.0 | 2.12.1 (nixpkgs backports upstream PR #172893 for 2.13+) | | aiodiscover | 3.2.3 | 3.0.0 | 2.7.1 | | cached-ipaddress | 1.1.1 | 1.0.1 | 1.0.1 | | wakeonlan | 3.3.0 | 3.1.0 | 3.1.0 | | aiodns | 4.0.0 | 4.0.4 | 4.0.4 | | xmltodict | 1.0.2 | 1.0.4 | 1.0.4 | | pillow | 12.2.0 | 12.3.0 | 12.2.0 | | idna | 3.13 | 3.15 | – | | urllib3 | 2.6.3 | 2.7.0 | – | | beautifulsoup4 / soupsieve | – | 4.14.3 / 2.8.3 | 4.13.3 | Unchanged: `homeassistant-2026.5.4`, frontend `20260429.4`, `msmart-ng 2026.4.1`, `mysqlclient 2.2.7`, `habluetooth 6.1.0`, `sqlalchemy 2.0.49`, `aiohttp 3.13.5`, all custom components (`midea_ac 2026.4.0`, `epex_spot 4.1.0`, `solarbank-planner 0.1.0`, lovelace `apexcharts-card 2.2.3`, `scheduler 3.2.13`). Packaging differences in nixpkgs (`pkgs/servers/home-assistant/`) between the two revisions: - `patches/nixos-was-never-supported.patch` added (release-26.05 `880079db`): suppresses the "Core installation method is deprecated" repair issue HA raises on non-container installs. - `patches/pyjwt-2.13-compat.patch` added (`0960784a`): catches `jwt.InvalidKeyError` in refresh-token validation, needed for pyjwt 2.14. - `caldav` instead of `caldav_2` in the package-set override (caldav is not used here). - `component-packages.nix`, `frontend.nix`, `intents.nix`, `midea_ac`, `epex_spot`, `msmart-ng`: identical. ## Verification - `scripts/pre-commit` dry-build of `fw`: OK. - The service `PYTHONPATH` after the change still carries `msmart-ng` and `mysqlclient`, so the reason `midea_ac` had to come from the pin (a second, mismatched Python package set) is gone. - Container journal on `fw` for the current boot (2026-10-09 00:45): HA 2026.5.4 starts, custom integrations `solarbank_planner`, `anker_solix`, `epex_spot`, `midea_ac`, `bermuda`, `hacs` load. Nothing in this PR touches the runtime-downloaded ones (hacs 2.0.5, anker_solix 3.5.4, bermuda 0.7.2). - No recorder schema change (same HA version), so the MariaDB `hass` database is untouched. Rollback is a plain `nixos-rebuild switch` to the previous generation. ## Pre-existing issues seen in the journal (not caused or fixed here) - `ping` platform under `binary_sensor:` is rejected ("does not support platform setup") – entity never loads. - `ModuleNotFoundError: No module named 'pyipp'` – an `ipp` config entry exists but the component is not in `extraComponents`. - Three template render errors at startup (`sensor.sensors_lowest_battery_level|int`, `sensor.creality_extruder` temperature `|float`) – missing `default=`. - Two deprecated YAML options (`exclude` at configuration.yaml:1187, `entity_id` at :1660). - Shelly plugs/buttons configured with `.cloonar.smart` hostnames are rejected ("does not appear to be an IPv4 or IPv6 address"). - Residual risk: pyjwt 2.14 vs HA's pinned 2.12.1 is covered by the backported patch and is what every nixos-26.05 HA host runs; first login after the switch should be checked once. ## Going beyond 2026.5 (not in this PR) nixos-unstable is at 2026.9.4; upstream is at 2026.10. Blocking item for this config: **2026.6 removed the legacy template platform** (`platform: template` under `sensor:`/`binary_sensor:`), still used in `default.nix`, `3dprinter.nix`, `battery.nix` (×2), `light.nix`, `locks.nix`, `multimedia.nix` (×2), `ac.nix`. Those 10 blocks must move to the `template:` key first. Other upstream breaking changes between 2026.6 and 2026.10 that touch integrations used here: Shelly and ESPHome Bluetooth scanner mode defaults to Auto (2026.6); `update` install actions and `mqtt.publish` require an admin account (2026.9, 2026.10); legacy auth-provider username mode removed (2026.10). Also HACS 2.0.5, bermuda 0.7.2 and anker_solix 3.5.4 would need compatibility checks. 🤖 Generated with [Claude Code](https://claude.com/claude-code)
Drop the separate nixos-unstable pin (331800d, HA 2026.5.4). The host
channel nixos-26.05 ships the same HA 2026.5.4, so this changes no HA
version, only the toolchain it is built with (Python 3.14.7, channel
dependency set, nixpkgs install-method and pyjwt-2.13 patches).

With HA and the customComponents now coming from one package set, the
midea_ac component no longer needs the pin to keep msmart-ng on the
PYTHONPATH, so it moves to the channel as well.

Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
dominik.polakovics deleted branch lab/20261009-0047 2026-10-09 09:47:41 +02:00
Sign in to join this conversation.
No reviewers
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
Cloonar/nixos!447
No description provided.