You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The ModernForms fan light internally has a notion of "brightness" that it retains whether on or off; if you toggle it on, it comes on to the brightness setting from the last time it was on. This is good.
However, if you turn it on while specifying a brightness (e.g. using the light.turn_on service and providing a brightness value; or sliding the brightness slider to a non-zero value while the light is off in the lovelace UI), then the light should come on at the newly selected brightness value. But in fact, it firstomes on initially at its old brightness and then quickly changes to the newly-selected brightness, appearing to flash.
It seems that the way to make this work as expected is rather than sending a single request to the light changing both brightness and "on" state in one shot, to first set the brightness to the new value, and only after that has adjusted, to send a separate request to turn the light on.
What version of Home Assistant Core has the issue?
core-2021.11.3
What was the last working version of Home Assistant Core?
While it seems like a reasonable request of the fan to both turn on and set brightness in one shot, empirically the result is that the light turns on at its previous brightness level first and then adjusts the brightness after. Doing two separate requests seems to make it work here.
The text was updated successfully, but these errors were encountered:
Hey there @wonderslug, mind taking a look at this issue as it has been labeled with an integration (modern_forms) you are listed as a code owner for? Thanks! (message by CodeOwnersMention)
Howdy, Yeah seeing this. It probably should be adjusted at the library level, not as much at the HA level. Ive setup an issue wonderslug/aiomodernforms#99 and will see if I can make the adjustments soon.
The problem
The ModernForms fan light internally has a notion of "brightness" that it retains whether on or off; if you toggle it on, it comes on to the brightness setting from the last time it was on. This is good.
However, if you turn it on while specifying a brightness (e.g. using the
light.turn_on
service and providing a brightness value; or sliding the brightness slider to a non-zero value while the light is off in the lovelace UI), then the light should come on at the newly selected brightness value. But in fact, it firstomes on initially at its old brightness and then quickly changes to the newly-selected brightness, appearing to flash.It seems that the way to make this work as expected is rather than sending a single request to the light changing both brightness and "on" state in one shot, to first set the brightness to the new value, and only after that has adjusted, to send a separate request to turn the light on.
What version of Home Assistant Core has the issue?
core-2021.11.3
What was the last working version of Home Assistant Core?
No response
What type of installation are you running?
Home Assistant Container
Integration causing the issue
Modern Forms
Link to integration documentation on our website
https://www.home-assistant.io/integrations/modern_forms/
Example YAML snippet
No response
Anything in the logs that might be useful for us?
No response
Additional information
This line of code seems to be the source of the problem:
core/homeassistant/components/modern_forms/light.py
Line 129 in 6749930
While it seems like a reasonable request of the fan to both turn on and set brightness in one shot, empirically the result is that the light turns on at its previous brightness level first and then adjusts the brightness after. Doing two separate requests seems to make it work here.
The text was updated successfully, but these errors were encountered: