Input_slider

are the input_sliders now returning float values? as I now get 1.0 instead of 1 i.e. an integer value

Yes, see here:

Ah, thanks very much :slight_smile:

OK, apparently int’s don’t have a length :P, so is there anyway I can do the following?

   value_template: '{% if states.input_slider.alarmfinishhr.state|int|length == 1 %}0{% endif %}{{ states.input_slider.alarmfinishhr.state|int }}:{% if states.input_slider.alarmfinishmins.state|int|length == 1 %}0{% endif %}{{ states.input_slider.alarmfinishmins.state|int }}'

fixed it with round(0) :slight_smile:

1 Like