From 9992a3e192918117c8a6e96f4fba664ec7ba79b8 Mon Sep 17 00:00:00 2001 From: Elad Bar Date: Thu, 2 May 2024 22:58:17 +0300 Subject: [PATCH] Fix StrEnum warning --- CHANGELOG.md | 4 ++++ custom_components/shinobi/common/connectivity_status.py | 3 +-- custom_components/shinobi/common/enums.py | 2 +- custom_components/shinobi/manifest.json | 2 +- 4 files changed, 7 insertions(+), 4 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 2457dd2..3878cab 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,9 @@ # Changelog +## v3.0.8 + +- Fix warning - StrEnum is a deprecated alias which will be removed in HA Core 2025.5. Use enum.StrEnum instead + ## v3.0.7 _Minimum HA Version: 2024.1.0b0_ diff --git a/custom_components/shinobi/common/connectivity_status.py b/custom_components/shinobi/common/connectivity_status.py index e687849..eafc8e5 100644 --- a/custom_components/shinobi/common/connectivity_status.py +++ b/custom_components/shinobi/common/connectivity_status.py @@ -1,7 +1,6 @@ +from enum import StrEnum import logging -from homeassistant.backports.enum import StrEnum - class ConnectivityStatus(StrEnum): NotConnected = "Not connected" diff --git a/custom_components/shinobi/common/enums.py b/custom_components/shinobi/common/enums.py index 4ebe32c..a7e41c1 100644 --- a/custom_components/shinobi/common/enums.py +++ b/custom_components/shinobi/common/enums.py @@ -1,4 +1,4 @@ -from homeassistant.backports.enum import StrEnum +from enum import StrEnum class MonitorMode(StrEnum): diff --git a/custom_components/shinobi/manifest.json b/custom_components/shinobi/manifest.json index 2a2769d..754eddb 100644 --- a/custom_components/shinobi/manifest.json +++ b/custom_components/shinobi/manifest.json @@ -9,5 +9,5 @@ "iot_class": "local_polling", "issue_tracker": "https://github.com/elad-bar/ha-shinobi/issues", "requirements": [], - "version": "3.0.7" + "version": "3.0.8" }