Following the most recent esphome update I occasionally receive errors on my Lovelace stating the entity is non-numeric.
The hardware is a Sonoff TH10 and has been solid for a long time, so was surprised to see the error, and how it displays only intermittently.
Here’s what I see on the dashboard:-
Here’s the code for the Sonoff unit in question…
substitutions:
off_hour: '3'
esphome:
name: outside-lights
platform: ESP8266
board: esp01_1m
on_boot:
- wait_until:
condition: api.connected
- delay: 2s
- if:
condition:
and:
- sun.is_below_horizon:
- lambda: |-
auto hour = id(ha_time).now().hour;
return hour > 12 || hour < ${off_hour};
then:
- light.turn_on:
id: outside_lights
wifi:
ssid: !secret wifi_ssid
password: !secret wifi_password
# Enable logging
logger:
# Enable Home Assistant API
api:
ota:
binary_sensor:
- platform: gpio
pin:
number: GPIO0
mode: INPUT_PULLUP
inverted: True
name: "Button"
- platform: status
name: "Outside Light Controller Status"
output:
- platform: gpio
id: relay
pin: GPIO12
# Register the blue LED as a dimmable output ....
- platform: esp8266_pwm
id: blue_led
pin: GPIO13
inverted: True
light:
# ... and then make a light out of it.
- platform: monochromatic
name: "Outside Light Controller Blue LED"
output: blue_led
- platform: binary
name: "Outside Lights"
id: outside_lights
output: relay
sensor:
- platform: dht
model: SI7021
pin: GPIO14
temperature:
name: "Sonoff Outside Temperature"
humidity:
name: "Sonoff Outside Humidity"
update_interval: 30s
time:
platform: homeassistant
timezone: !secret timezone
id: ha_time
on_time:
- hours: ${off_hour}
minutes: 0
seconds: 0
then:
- light.turn_off:
id: outside_lights
sun:
latitude: !secret latitude
longitude: !secret longitude
on_sunset:
- elevation: -10°
then:
- light.turn_on:
id: outside_lights
switch:
- platform: restart
name: "Outside Lights Restart"
Have tried a few things, but alas none that have worked. This was one of the threads I read for some ideas.
https://community.home-assistant.io/t/lovelace-guage-card-entity-is-non-numeric/202163
Any suggestions appreciated.