Dielee / volvo2mqtt

Home Assistant addon for connecting AAOS Volvos
MIT License
162 stars 38 forks source link

Months to Service sensor bug when time is less than a month #125

Closed nlindn closed 1 year ago

nlindn commented 1 year ago

Describe the bug When the time to service is less than a month the API returns days instead of months. In the Home Assistant sensor this is not taken to account and the sensor will for example show 26 months to service when it is 26 days.

To Reproduce: Connect a Volvo to the integration with less than a month to service.

Expected behavior: The sensor name in HA is Months to Service. When the time is less than a month expected behavior would be to show 0 months. Other option is to have the sensor name as Time to Service and show months and days as in the API.

Version info: Docker container v1.8.12

Logs: "timeToService" : { "value" : 26, "unit" : "days", "timestamp" : "2023-11-16T06:36:38.426Z" }

Dielee commented 1 year ago

Should be fixed with v1.8.13 :)

nlindn commented 1 year ago

Yes, this is now fixed 👍