Closed lymanepp closed 2 years ago
I now removed the DEVICE_CLASS TIMESTAMP from the sensor, and converted the time to Local time.
Could you download sensor.py
from this Github and replace the same file in custom_components/weatherbit
and then restart HA, to see if that fixes your issue?
And just to make sure you know - This DateTime tells when WEATHERBIT has last updated the data for that location, not the last time this Integration has pulled data from WeatherBit. Som locations only update once a day.
Your commit changed the display format, but the time was still off by the UTC offset.
I submitted a PR for py-weatherbit to fix the root cause. With that fix, you can probably revert the changes in https://github.com/briis/weatherbit/commit/05903401fb0c6abfd238c98593331c1ab402e24c
Released 1.0.8, where this is fixed. Please check and close if you agree.
The time is correct now! But I'd still prefer to see the observation time as a timestamp instead of a string (i.e., revert changes in https://github.com/briis/weatherbit/commit/05903401fb0c6abfd238c98593331c1ab402e24c).
OK, I will revert it to a Timestamp. Try an download the sensor.py
file, and overwrite as before. Then give the final go that this still shows the correct time.
Thanks Bjarne! It looks good to me.
Wonderful. Just keep the file you downloaded and that will then be in the next release.
Observation time is in UTC. Normally that would be fine, but Lovelace displays that as an offset from the current local time instead of displaying the actual time.