From 65c4ee130648a8ce970c2a11787997191a8a8384 Mon Sep 17 00:00:00 2001 From: magnuselden Date: Sun, 25 Jun 2023 12:15:06 +0200 Subject: [PATCH] core 19.0.0a23 --- custom_components/peaqev/manifest.json | 2 +- custom_components/peaqev/sensors/money_sensor_helpers.py | 5 +++-- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/custom_components/peaqev/manifest.json b/custom_components/peaqev/manifest.json index 42359cf1..07932fbb 100644 --- a/custom_components/peaqev/manifest.json +++ b/custom_components/peaqev/manifest.json @@ -22,7 +22,7 @@ "iot_class": "calculated", "issue_tracker": "https://github.com/elden1337/hass-peaq/issues", "requirements": [ - "peaqevcore==19.0.0a20" + "peaqevcore==19.0.0a23" ], "version": "3.0.0a0" } \ No newline at end of file diff --git a/custom_components/peaqev/sensors/money_sensor_helpers.py b/custom_components/peaqev/sensors/money_sensor_helpers.py index b6e0e386..da1e5042 100644 --- a/custom_components/peaqev/sensors/money_sensor_helpers.py +++ b/custom_components/peaqev/sensors/money_sensor_helpers.py @@ -1,5 +1,6 @@ -from datetime import datetime, timedelta import logging +from datetime import datetime + from peaqevcore.services.hoursselection_service_new.models.hour_price import HourPrice _LOGGER = logging.getLogger(__name__) @@ -86,7 +87,7 @@ def set_all_hours_display(future_hours: list[HourPrice]) -> dict: case 1: ret[dtstr] = "Start" case _: - ret[dtstr] = f"Caution {str(h.permittance * 100)}%" + ret[dtstr] = f"Caution {str(int(h.permittance * 100))}%" return ret