Skip to content

Overview device rename, current-power naming, and roof icons - #14

Merged
patricknitsch merged 2 commits into
mainfrom
feature/translated-overview-device-name
Jul 21, 2026
Merged

Overview device rename, current-power naming, and roof icons#14
patricknitsch merged 2 commits into
mainfrom
feature/translated-overview-device-name

Conversation

@patricknitsch

@patricknitsch patricknitsch commented Jul 21, 2026

Copy link
Copy Markdown
Owner

Summary

  • The device that groups all summed/total-across-roofs sensors (total power, total energy, total clear-sky power, temperature, weather code) was named after the config entry title (usually just "pvnode") - the same name as the integration itself, which didn't convey that this specific device holds the combined/site-wide values.
    • Switch PvnodeTotalEntity's DeviceInfo from a fixed name=entry.title to translation_key="overview", resolved via a new device.overview.name translation entry: "Summary" in English, "Gesamt" in German.
  • Rename the "power"/"total_power" entities from "Power forecast"/"Total power forecast" to "Current power forecast"/"Total current power forecast" (German: "Leistungsprognose aktuell"/"Gesamt-Leistungsprognose aktuell"), to make clear these represent the current time slot's value, not the whole forecast.
  • Add icons.json giving every per-roof-surface sensor (power, energy per day, clear-sky power) the mdi:home-roof icon, so they're visually recognizable as belonging to a physical roof surface. The summary/overview device's sensors keep their existing device-class-driven icons (unchanged).
  • Updated the README's "Entities" and "Use Cases" sections to match.

Compatibility note

These only change displayed names/icons - existing installations keep their current entity_ids (HA doesn't rename already-registered entities when the underlying device/entity name or translation changes), so this is not a breaking change for anyone upgrading. Only brand-new setups (or the test suite, which spins up fresh entities every time) get entity_ids derived from the new names, e.g. sensor.summary_total_current_power_forecast / sensor.dachflache_1_current_power_forecast instead of sensor.pvnode_total_power_forecast / sensor.dachflache_1_power_forecast.

Test plan

  • pytest tests/ -v — all 22 tests pass (entity_id assertions updated for the new names)
  • ruff check / ruff format --check — clean
  • Verified strings.json / translations/en.json / translations/de.json / icons.json all parse as valid JSON
  • Note: icons.json-driven default icons are resolved by the HA frontend, not exposed as a backend state attribute, so this can't be asserted directly in the pytest harness - verified by reading HA core's helpers/icon.py / helpers/entity.py to confirm the resolution mechanism and file-discovery convention (no manifest change needed).

claude added 2 commits July 21, 2026 09:22
The overview device that groups all summed/total-across-roofs sensors
was named after the config entry title (usually just "pvnode"), which
duplicated the integration name and didn't convey what the device
actually groups.

Use DeviceInfo's translation_key instead of a fixed name, so the
device shows as "Summary" in English and "Gesamt" in German (falls
back to the translation_key itself for any other language, per HA's
translation resolution).
Rename the "power"/"total_power" translation keys from "Power
forecast"/"Total power forecast" to "Current power forecast"/"Total
current power forecast" (German: "Leistungsprognose
aktuell"/"Gesamt-Leistungsprognose aktuell"), making clear these show
the current time slot's value rather than the whole forecast.

Add icons.json giving every per-roof-surface sensor (power, energy per
day, clear-sky power) the mdi:home-roof icon, visually tying them to
the physical roof surface they belong to. The summary/overview
device's sensors keep their existing device-class-driven icons.
@patricknitsch patricknitsch changed the title Rename the overview device to a translatable "Summary"/"Gesamt" name Overview device rename, current-power naming, and roof icons Jul 21, 2026
@patricknitsch
patricknitsch merged commit e83715c into main Jul 21, 2026
1 check passed
@patricknitsch
patricknitsch deleted the feature/translated-overview-device-name branch July 21, 2026 09:31
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants