[template] Stop water heater republishing when a temperature is unknown (#19013)

This commit is contained in:
tronikos
2026-09-14 13:36:39 +12:00
committed by GitHub
parent a0821c225a
commit 41e34c19eb
3 changed files with 57 additions and 2 deletions
@@ -0,0 +1,16 @@
esphome:
name: wh-template-unknown-test
host:
api:
logger:
water_heater:
- platform: template
id: unknown_boiler
name: Unknown Boiler
# Both temperatures stay unknown, as they do before an upstream component reports a value.
current_temperature: !lambda "return NAN;"
target_temperature: !lambda "return NAN;"
supported_modes:
- "off"
- eco