chkuendig / hass-amphiro-ble

🚿 Amphiro Digital Hand Shower component for Home Assistant
https://christian.kuendig.info/posts/2023-01-hass-amphiro/
MIT License
8 stars 2 forks source link

Deprecated constants which will be removed in HA Core 2025.1 #6

Closed ExMacro closed 9 months ago

ExMacro commented 9 months ago

HA logs have the following mention that some of the constants used will be deprecated in a year. Thanks already beforehand if you have the time to fix this in the near future @chkuendig!

Logger: homeassistant.const
Source: helpers/deprecation.py:205
First occurred: 18:46:47 (8 occurrences)
Last logged: 18:46:51

TEMP_CELSIUS was used from amphiro_ble, this is a deprecated constant which will be removed in HA Core 2025.1. Use UnitOfTemperature.CELSIUS instead, please report it to the author of the 'amphiro_ble' custom integration
TIME_SECONDS was used from amphiro_ble, this is a deprecated constant which will be removed in HA Core 2025.1. Use UnitOfTime.SECONDS instead, please report it to the author of the 'amphiro_ble' custom integration
chkuendig commented 9 months ago

Thank you for bringing this to my attention!

Should be fixed with chkuendig/hass-amphiro-ble@930570c.

ExMacro commented 8 months ago

Thanks @chkuendig ! And sorry but now that I updated, there's still a few more constants to fix.. Didn't notice these at the first time.

Logger: homeassistant.const
Source: helpers/deprecation.py:205
First occurred: 17:48:24 (2 occurrences)
Last logged: 17:48:24

ENERGY_KILO_WATT_HOUR was used from amphiro_ble, this is a deprecated constant which will be removed in HA Core 2025.1. Use UnitOfEnergy.KILO_WATT_HOUR instead, please report it to the author of the 'amphiro_ble' custom integration
VOLUME_LITERS was used from amphiro_ble, this is a deprecated constant which will be removed in HA Core 2025.1. Use UnitOfVolume.LITERS instead, please report it to the author of the 'amphiro_ble' custom integration
chkuendig commented 8 months ago

This should now also be fixed (I was wondering about the other units but kind of forgot about it as I don't get these warnings on my end as I haven't updated to the newest HA yet)