Skip to content
This repository was archived by the owner on Aug 18, 2026. It is now read-only.

v0.3.6

Choose a tag to compare

@Levtos-Acc Levtos-Acc released this 23 May 08:57
· 54 commits to main since this release

Neues Source-Modell (const.py)
Pro Gerät jetzt schlanke optionale Slots — neue CONF-Keys:

TV: tv_player_entity, tv_active_entity, tv_power_entity
Apple TV: appletv_player_entity
PS5: ps5_player_entity, ps5_active_entity, ps5_power_entity, ps5_title_entity, ps5_network_entity
Switch: switch_active_entity, switch_power_entity, switch_ping_entity
PC: pc_active_entity, pc_power_entity
Denon: denon_player_entity, denon_active_entity, denon_power_entity
HomePods: homepods_player_entity
DEVICE_CARDS gruppiert sie für den Flow; LEGACY_FALLBACKS mapped jeden neuen Key auf den alten, den er ersetzt. Keine _source_entity-Slots — Source kommt jetzt direkt aus dem Player-Attribut.

Coordinator

_entity_with_fallback(new_key) versucht neuen Key, fällt auf Legacy zurück → existierende Entries laufen ohne Migration.
_build_snapshot() liest source, app_id, media_title, media_content_type, volume_level aus dem jeweiligen media_player. Active/Power/Ping sind nur Plausibilitätssignale, liefern keine Source.
denon_audio_path kombiniert Player-State, source-Attribut, Active-Binary und Power-Sensor.
Switch: handheld_candidate = ping_on UND nicht dock_active UND power<1W — rein diagnostisch, nicht dominant.
device_diagnostics Dict pro Gerät: player_state, active_state, power_w, network_state, source, app_name, media_title, content_type, volume_level, reasons.
Options-Flow (flow.py)

Menü zeigt eine Karte pro Gerät plus sources (Legacy-Aggregat) und tuning.
Jede Karte rendert nur die Slots dieses Geräts.
_save_card() merged ausschließlich diese Keys in entry.options. Andere Geräte, Tuning, Legacy entry.data bleiben unangetastet.
Skip-Semantik ist implizit: Karte nicht öffnen oder leer abschicken → bestehende Werte bleiben. Geleerter Slot wird aus options entfernt → Legacy-Fallback aus data greift wieder.
Backwards-Compat (alle Constraints aus dem Prompt erfüllt)

Keine unique_id-Änderungen.
Keine CONF-Key-Renames; alle alten Keys (tv_active, appletv, ps5_status, ps5_title, switch_dock, pc_active, denon_active, homepods) bleiben gültige Fallbacks.
Fehlende optionale Slots machen die Integration nicht unavailable (Coordinator behandelt None).
enable_control, Subwoofer-Policy, Volume-Targets, Engine-Regeln unverändert.