I have new sensors created with the new create entities nodes, this one is sensor, that have unknown values when HA restarts (they’re values for the greatest daily, monthly… power, solar values).
No problem with sensors created in HA directly.
Any ideas for solving this issue?
Having the same issue, created some sensors recently for custom energy tracking but after restart of HASS the values are gone.
Did you find a solution for it?
In theory you can make a helper and whenever the value updates save it there and after restart retrieve from there but that’s not a very nice solution.
I ran into this issue recently with NodeRed sensors based on MQTT. Whenever HA would be restarted, the NodeRed sensors would go unknown. I couldn’t easily use an inject node as the sensors were based on MQTT, which only triggers with a new MQTT message and not when HA restarts.
I found that setting the sensor to “resend states and attributes” in the HA sensor configuration in NodeRed resolved it.