ZHA - Philips Hue Dimmer Switch (RWL020, RWL021)

Seems there was a change in 2022.6.0 and brightness value is no longer returned as 0 when the light is off (I’m assuming) so V2 throws an error when turning on.

To get it working again I changed the line

cur_brightness : '{{ state_attr(light, ''brightness'') | int }}'

to

cur_brightness : '{{ state_attr(light, ''brightness'') | default(0) }}'
6 Likes