Open aherbjornsen opened 5 years ago
The new autodiscovery is working great. However, I try to monitor for stale sensors and then it would be nice if the announcement included a 'force_update= true'
I solved this by adding
payload['force_update'] = True
to plantgw.py around line 300But this should probably be configurable from .plantgw.yaml
I found plantgw.py in /usr/local/lib/python3.7/dist-packages/plantgw/ and added the line above. How do I recompile and get this change into my instance?
You do not have to recompile anything, just make the change in the py-file.
Anyway, I found that this did not help because Home Assistant changes the sensor last_updated time when it receive announcements (and not only when it receives actual sensor updates).
I've created an issue here: https://github.com/home-assistant/core/issues/26725 Unfortunately there was not much interest in the problem, so it is now closed.
The new autodiscovery is working great. However, I try to monitor for stale sensors and then it would be nice if the announcement included a 'force_update= true'
I solved this by adding
payload['force_update'] = True
to plantgw.py around line 300But this should probably be configurable from .plantgw.yaml