diff --git a/CHANGELOG.md b/CHANGELOG.md index 029108dcf..f81d9060d 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -2,6 +2,10 @@ Versions from 0.40 and up +## Ongoing + +- Downstream HA [Core PR](https://github.com/home-assistant/core/pull/138201) update signature of platforms' async_setup_entry + ## v0.57.1 - Bugfix for Stretch (Issue #833) via plugwise [v1.7.2](https://github.com/plugwise/python-plugwise/releases/tag/v1.7.2) diff --git a/custom_components/plugwise/binary_sensor.py b/custom_components/plugwise/binary_sensor.py index 852650d0a..dad3d8dc2 100644 --- a/custom_components/plugwise/binary_sensor.py +++ b/custom_components/plugwise/binary_sensor.py @@ -18,7 +18,7 @@ ) from homeassistant.const import EntityCategory from homeassistant.core import HomeAssistant, callback -from homeassistant.helpers.entity_platform import AddEntitiesCallback +from homeassistant.helpers.entity_platform import AddConfigEntryEntitiesCallback from .const import ( BATTERY_STATE, @@ -104,7 +104,7 @@ class PlugwiseBinarySensorEntityDescription(BinarySensorEntityDescription): async def async_setup_entry( hass: HomeAssistant, entry: PlugwiseConfigEntry, - async_add_entities: AddEntitiesCallback, + async_add_entities: AddConfigEntryEntitiesCallback, ) -> None: """Set up Plugwise binary_sensors from a config entry.""" coordinator = entry.runtime_data diff --git a/custom_components/plugwise/button.py b/custom_components/plugwise/button.py index 2cf58b7c5..2848a60e5 100644 --- a/custom_components/plugwise/button.py +++ b/custom_components/plugwise/button.py @@ -5,7 +5,7 @@ from homeassistant.components.button import ButtonDeviceClass, ButtonEntity from homeassistant.const import EntityCategory from homeassistant.core import HomeAssistant -from homeassistant.helpers.entity_platform import AddEntitiesCallback +from homeassistant.helpers.entity_platform import AddConfigEntryEntitiesCallback from .const import ( LOGGER, # pw-betea @@ -21,7 +21,7 @@ async def async_setup_entry( hass: HomeAssistant, entry: PlugwiseConfigEntry, - async_add_entities: AddEntitiesCallback, + async_add_entities: AddConfigEntryEntitiesCallback, ) -> None: """Set up Plugwise buttons from a config entry.""" coordinator = entry.runtime_data diff --git a/custom_components/plugwise/climate.py b/custom_components/plugwise/climate.py index 0f6a697c7..72fa54b69 100644 --- a/custom_components/plugwise/climate.py +++ b/custom_components/plugwise/climate.py @@ -24,7 +24,7 @@ ) from homeassistant.core import HomeAssistant, callback from homeassistant.exceptions import HomeAssistantError -from homeassistant.helpers.entity_platform import AddEntitiesCallback +from homeassistant.helpers.entity_platform import AddConfigEntryEntitiesCallback from .const import ( ACTIVE_PRESET, @@ -58,7 +58,7 @@ async def async_setup_entry( hass: HomeAssistant, entry: PlugwiseConfigEntry, - async_add_entities: AddEntitiesCallback, + async_add_entities: AddConfigEntryEntitiesCallback, ) -> None: """Set up Plugwise thermostats from a config entry.""" coordinator = entry.runtime_data diff --git a/custom_components/plugwise/number.py b/custom_components/plugwise/number.py index 7797c9fed..a9637de22 100644 --- a/custom_components/plugwise/number.py +++ b/custom_components/plugwise/number.py @@ -12,7 +12,7 @@ ) from homeassistant.const import EntityCategory, UnitOfTemperature from homeassistant.core import HomeAssistant, callback -from homeassistant.helpers.entity_platform import AddEntitiesCallback +from homeassistant.helpers.entity_platform import AddConfigEntryEntitiesCallback from .const import ( LOGGER, @@ -69,7 +69,7 @@ class PlugwiseNumberEntityDescription(NumberEntityDescription): async def async_setup_entry( hass: HomeAssistant, entry: PlugwiseConfigEntry, - async_add_entities: AddEntitiesCallback, + async_add_entities: AddConfigEntryEntitiesCallback, ) -> None: """Set up Plugwise number platform from a config entry.""" # Upstream above to adhere to standard used diff --git a/custom_components/plugwise/select.py b/custom_components/plugwise/select.py index d1e3a6218..9aba54df6 100644 --- a/custom_components/plugwise/select.py +++ b/custom_components/plugwise/select.py @@ -7,7 +7,7 @@ from homeassistant.components.select import SelectEntity, SelectEntityDescription from homeassistant.const import STATE_ON, EntityCategory from homeassistant.core import HomeAssistant, callback -from homeassistant.helpers.entity_platform import AddEntitiesCallback +from homeassistant.helpers.entity_platform import AddConfigEntryEntitiesCallback from .const import ( AVAILABLE_SCHEDULES, @@ -74,7 +74,7 @@ class PlugwiseSelectEntityDescription(SelectEntityDescription): async def async_setup_entry( hass: HomeAssistant, entry: PlugwiseConfigEntry, - async_add_entities: AddEntitiesCallback, + async_add_entities: AddConfigEntryEntitiesCallback, ) -> None: """Set up Plugwise selector from a config entry.""" coordinator = entry.runtime_data diff --git a/custom_components/plugwise/sensor.py b/custom_components/plugwise/sensor.py index eef1354a9..d071d584a 100644 --- a/custom_components/plugwise/sensor.py +++ b/custom_components/plugwise/sensor.py @@ -26,7 +26,7 @@ UnitOfVolumeFlowRate, ) from homeassistant.core import HomeAssistant, callback -from homeassistant.helpers.entity_platform import AddEntitiesCallback +from homeassistant.helpers.entity_platform import AddConfigEntryEntitiesCallback from .const import ( DHW_SETPOINT, @@ -459,7 +459,7 @@ class PlugwiseSensorEntityDescription(SensorEntityDescription): async def async_setup_entry( hass: HomeAssistant, entry: PlugwiseConfigEntry, - async_add_entities: AddEntitiesCallback, + async_add_entities: AddConfigEntryEntitiesCallback, ) -> None: """Set up Plugwise sensors from a config entry.""" # Upstream as Plugwise not Smile diff --git a/custom_components/plugwise/switch.py b/custom_components/plugwise/switch.py index 733c7b5fb..1d330c02d 100644 --- a/custom_components/plugwise/switch.py +++ b/custom_components/plugwise/switch.py @@ -14,7 +14,7 @@ ) from homeassistant.const import EntityCategory from homeassistant.core import HomeAssistant, callback -from homeassistant.helpers.entity_platform import AddEntitiesCallback +from homeassistant.helpers.entity_platform import AddConfigEntryEntitiesCallback from .const import ( COOLING_ENA_SWITCH, @@ -72,7 +72,7 @@ class PlugwiseSwitchEntityDescription(SwitchEntityDescription): async def async_setup_entry( hass: HomeAssistant, entry: PlugwiseConfigEntry, - async_add_entities: AddEntitiesCallback, + async_add_entities: AddConfigEntryEntitiesCallback, ) -> None: """Set up Plugwise switches from a config entry.""" coordinator = entry.runtime_data diff --git a/hacs.json b/hacs.json index 6bd477de7..2bef39382 100644 --- a/hacs.json +++ b/hacs.json @@ -9,6 +9,6 @@ "sensor", "switch" ], - "homeassistant": "2025.2.0", + "homeassistant": "2025.3.0", "render_readme": true }