From 7ee31f088465b75a106c1448127f992560f60b64 Mon Sep 17 00:00:00 2001 From: Joost Lekkerkerker Date: Thu, 25 Sep 2025 17:57:30 +0200 Subject: [PATCH 01/15] Bump pySmartThings to 3.3.0 (#152977) --- homeassistant/components/smartthings/manifest.json | 2 +- requirements_all.txt | 2 +- requirements_test_all.txt | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/homeassistant/components/smartthings/manifest.json b/homeassistant/components/smartthings/manifest.json index 951d1372a6991..96c6d94da4f90 100644 --- a/homeassistant/components/smartthings/manifest.json +++ b/homeassistant/components/smartthings/manifest.json @@ -30,5 +30,5 @@ "iot_class": "cloud_push", "loggers": ["pysmartthings"], "quality_scale": "bronze", - "requirements": ["pysmartthings==3.2.9"] + "requirements": ["pysmartthings==3.3.0"] } diff --git a/requirements_all.txt b/requirements_all.txt index e7eb58bbb2054..b580de8f356ae 100644 --- a/requirements_all.txt +++ b/requirements_all.txt @@ -2384,7 +2384,7 @@ pysmappee==0.2.29 pysmarlaapi==0.9.2 # homeassistant.components.smartthings -pysmartthings==3.2.9 +pysmartthings==3.3.0 # homeassistant.components.smarty pysmarty2==0.10.3 diff --git a/requirements_test_all.txt b/requirements_test_all.txt index 3c6183a4199e2..9abe779c7789a 100644 --- a/requirements_test_all.txt +++ b/requirements_test_all.txt @@ -1987,7 +1987,7 @@ pysmappee==0.2.29 pysmarlaapi==0.9.2 # homeassistant.components.smartthings -pysmartthings==3.2.9 +pysmartthings==3.3.0 # homeassistant.components.smarty pysmarty2==0.10.3 From 159c7fbfd15c9f67c51a96189bfb32c4b5a5296e Mon Sep 17 00:00:00 2001 From: Erik Montnemery Date: Thu, 25 Sep 2025 18:29:26 +0200 Subject: [PATCH 02/15] Correct filter of target selector in sonos services (#152972) --- homeassistant/components/sonos/services.yaml | 15 ++++++++++----- 1 file changed, 10 insertions(+), 5 deletions(-) diff --git a/homeassistant/components/sonos/services.yaml b/homeassistant/components/sonos/services.yaml index 8970642889972..5d596c5679fe2 100644 --- a/homeassistant/components/sonos/services.yaml +++ b/homeassistant/components/sonos/services.yaml @@ -24,8 +24,9 @@ restore: set_sleep_timer: target: - device: + entity: integration: sonos + domain: media_player fields: sleep_time: selector: @@ -36,13 +37,15 @@ set_sleep_timer: clear_sleep_timer: target: - device: + entity: integration: sonos + domain: media_player play_queue: target: - device: + entity: integration: sonos + domain: media_player fields: queue_position: selector: @@ -53,8 +56,9 @@ play_queue: remove_from_queue: target: - device: + entity: integration: sonos + domain: media_player fields: queue_position: selector: @@ -71,8 +75,9 @@ get_queue: update_alarm: target: - device: + entity: integration: sonos + domain: media_player fields: alarm_id: required: true From eb38837a8cff410a91611f725512b102923370dc Mon Sep 17 00:00:00 2001 From: Erik Montnemery Date: Thu, 25 Sep 2025 18:30:05 +0200 Subject: [PATCH 03/15] Replace target selector with device selector in fully_kiosk services (#152959) Co-authored-by: Franck Nijhof Co-authored-by: Norbert Rittel --- .../components/fully_kiosk/services.yaml | 24 ++++++++++++------- .../components/fully_kiosk/strings.json | 12 ++++++++++ 2 files changed, 27 insertions(+), 9 deletions(-) diff --git a/homeassistant/components/fully_kiosk/services.yaml b/homeassistant/components/fully_kiosk/services.yaml index 7784996da9beb..9cfc91295ede2 100644 --- a/homeassistant/components/fully_kiosk/services.yaml +++ b/homeassistant/components/fully_kiosk/services.yaml @@ -1,8 +1,10 @@ load_url: - target: - device: - integration: fully_kiosk fields: + device_id: + required: true + selector: + device: + integration: fully_kiosk url: example: "https://home-assistant.io" required: true @@ -10,10 +12,12 @@ load_url: text: set_config: - target: - device: - integration: fully_kiosk fields: + device_id: + required: true + selector: + device: + integration: fully_kiosk key: example: "motionSensitivity" required: true @@ -26,12 +30,14 @@ set_config: text: start_application: - target: - device: - integration: fully_kiosk fields: application: example: "de.ozerov.fully" required: true selector: text: + device_id: + required: true + selector: + device: + integration: fully_kiosk diff --git a/homeassistant/components/fully_kiosk/strings.json b/homeassistant/components/fully_kiosk/strings.json index fd7eaecd44656..785124575ba8a 100644 --- a/homeassistant/components/fully_kiosk/strings.json +++ b/homeassistant/components/fully_kiosk/strings.json @@ -147,6 +147,10 @@ "name": "Load URL", "description": "Loads a URL on Fully Kiosk Browser.", "fields": { + "device_id": { + "name": "Device ID", + "description": "The target device for this action." + }, "url": { "name": "[%key:common::config_flow::data::url%]", "description": "URL to load." @@ -157,6 +161,10 @@ "name": "Set configuration", "description": "Sets a configuration parameter on Fully Kiosk Browser.", "fields": { + "device_id": { + "name": "%key:component::fully_kiosk::services::load_url::fields::device_id::name%", + "description": "%key:component::fully_kiosk::services::load_url::fields::device_id::description%" + }, "key": { "name": "Key", "description": "Configuration parameter to set." @@ -174,6 +182,10 @@ "application": { "name": "Application", "description": "Package name of the application to start." + }, + "device_id": { + "name": "%key:component::fully_kiosk::services::load_url::fields::device_id::name%", + "description": "%key:component::fully_kiosk::services::load_url::fields::device_id::description%" } } } From 1c12d2b8cd0ca0c88aac44fd387df5b494be3e3f Mon Sep 17 00:00:00 2001 From: Maciej Bieniek Date: Thu, 25 Sep 2025 18:30:47 +0200 Subject: [PATCH 04/15] Bump accuweather to version 4.2.2 (#152965) --- homeassistant/components/accuweather/manifest.json | 2 +- requirements_all.txt | 2 +- requirements_test_all.txt | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/homeassistant/components/accuweather/manifest.json b/homeassistant/components/accuweather/manifest.json index 09ea76d022dcd..11f927c6aeb64 100644 --- a/homeassistant/components/accuweather/manifest.json +++ b/homeassistant/components/accuweather/manifest.json @@ -7,5 +7,5 @@ "integration_type": "service", "iot_class": "cloud_polling", "loggers": ["accuweather"], - "requirements": ["accuweather==4.2.1"] + "requirements": ["accuweather==4.2.2"] } diff --git a/requirements_all.txt b/requirements_all.txt index b580de8f356ae..24f911f842459 100644 --- a/requirements_all.txt +++ b/requirements_all.txt @@ -131,7 +131,7 @@ TwitterAPI==2.7.12 WSDiscovery==2.1.2 # homeassistant.components.accuweather -accuweather==4.2.1 +accuweather==4.2.2 # homeassistant.components.adax adax==0.4.0 diff --git a/requirements_test_all.txt b/requirements_test_all.txt index 9abe779c7789a..868386b0f0f63 100644 --- a/requirements_test_all.txt +++ b/requirements_test_all.txt @@ -119,7 +119,7 @@ Tami4EdgeAPI==3.0 WSDiscovery==2.1.2 # homeassistant.components.accuweather -accuweather==4.2.1 +accuweather==4.2.2 # homeassistant.components.adax adax==0.4.0 From 47df73b18ff6b0ddb4526184f10f68b9e0ab98e5 Mon Sep 17 00:00:00 2001 From: Erik Montnemery Date: Thu, 25 Sep 2025 18:32:12 +0200 Subject: [PATCH 05/15] Remove device filter from target selector in google_mail services (#152968) --- homeassistant/components/google_mail/services.yaml | 2 -- 1 file changed, 2 deletions(-) diff --git a/homeassistant/components/google_mail/services.yaml b/homeassistant/components/google_mail/services.yaml index 9ce1c41f27a3a..1be14b8fac231 100644 --- a/homeassistant/components/google_mail/services.yaml +++ b/homeassistant/components/google_mail/services.yaml @@ -1,7 +1,5 @@ set_vacation: target: - device: - integration: google_mail entity: integration: google_mail fields: From 88016d96d440637f55eec59772f1efeceed470ff Mon Sep 17 00:00:00 2001 From: Erik Montnemery Date: Thu, 25 Sep 2025 18:41:54 +0200 Subject: [PATCH 06/15] Remove device and entity filter from target selector in homeassistant services (#152969) --- homeassistant/components/homeassistant/services.yaml | 5 ----- 1 file changed, 5 deletions(-) diff --git a/homeassistant/components/homeassistant/services.yaml b/homeassistant/components/homeassistant/services.yaml index 372f4fa9955fd..b928ff0b85103 100644 --- a/homeassistant/components/homeassistant/services.yaml +++ b/homeassistant/components/homeassistant/services.yaml @@ -32,15 +32,12 @@ set_location: stop: toggle: target: - entity: {} turn_on: target: - entity: {} turn_off: target: - entity: {} update_entity: fields: @@ -53,8 +50,6 @@ update_entity: reload_custom_templates: reload_config_entry: target: - entity: {} - device: {} fields: entry_id: advanced: true From 8f99c3f64a420eaa45cedf1469d140bb1298ebb7 Mon Sep 17 00:00:00 2001 From: Erik Montnemery Date: Thu, 25 Sep 2025 18:45:32 +0200 Subject: [PATCH 07/15] Remove device filter from target selector in lyric services (#152970) --- homeassistant/components/lyric/services.yaml | 2 -- 1 file changed, 2 deletions(-) diff --git a/homeassistant/components/lyric/services.yaml b/homeassistant/components/lyric/services.yaml index c3c4bc640bf58..3dd300f48ad3f 100644 --- a/homeassistant/components/lyric/services.yaml +++ b/homeassistant/components/lyric/services.yaml @@ -1,7 +1,5 @@ set_hold_time: target: - device: - integration: lyric entity: integration: lyric domain: climate From bc886963397b19d6280b8e60841eaa75c96c49bd Mon Sep 17 00:00:00 2001 From: Simone Chemelli Date: Thu, 25 Sep 2025 18:59:53 +0200 Subject: [PATCH 08/15] Remove deprecated sensors and update remaning for Alexa Devices (#151230) --- .../components/alexa_devices/binary_sensor.py | 74 +++++++++---------- .../components/alexa_devices/config_flow.py | 4 +- .../components/alexa_devices/coordinator.py | 2 +- .../components/alexa_devices/diagnostics.py | 4 +- .../components/alexa_devices/icons.json | 40 ---------- .../components/alexa_devices/manifest.json | 2 +- .../components/alexa_devices/sensor.py | 13 ++++ .../components/alexa_devices/strings.json | 20 ----- .../components/alexa_devices/switch.py | 34 +++++++-- .../components/alexa_devices/utils.py | 25 ++++++- requirements_all.txt | 2 +- requirements_test_all.txt | 2 +- tests/components/alexa_devices/const.py | 17 ++--- .../snapshots/test_binary_sensor.ambr | 48 ------------ .../snapshots/test_diagnostics.ambr | 26 +++++-- .../snapshots/test_services.ambr | 24 ++++-- .../alexa_devices/snapshots/test_switch.ambr | 2 +- tests/components/alexa_devices/test_sensor.py | 30 +++++++- tests/components/alexa_devices/test_switch.py | 50 ++++++++----- tests/components/alexa_devices/test_utils.py | 40 ++++++++++ 20 files changed, 250 insertions(+), 209 deletions(-) diff --git a/homeassistant/components/alexa_devices/binary_sensor.py b/homeassistant/components/alexa_devices/binary_sensor.py index 410ea4555e247..296f4c417f020 100644 --- a/homeassistant/components/alexa_devices/binary_sensor.py +++ b/homeassistant/components/alexa_devices/binary_sensor.py @@ -10,6 +10,7 @@ from aioamazondevices.const import SENSOR_STATE_OFF from homeassistant.components.binary_sensor import ( + DOMAIN as BINARY_SENSOR_DOMAIN, BinarySensorDeviceClass, BinarySensorEntity, BinarySensorEntityDescription, @@ -20,6 +21,7 @@ from .coordinator import AmazonConfigEntry from .entity import AmazonEntity +from .utils import async_update_unique_id # Coordinator is used to centralize the data updates PARALLEL_UPDATES = 0 @@ -31,6 +33,7 @@ class AmazonBinarySensorEntityDescription(BinarySensorEntityDescription): is_on_fn: Callable[[AmazonDevice, str], bool] is_supported: Callable[[AmazonDevice, str], bool] = lambda device, key: True + is_available_fn: Callable[[AmazonDevice, str], bool] = lambda device, key: True BINARY_SENSORS: Final = ( @@ -41,46 +44,15 @@ class AmazonBinarySensorEntityDescription(BinarySensorEntityDescription): is_on_fn=lambda device, _: device.online, ), AmazonBinarySensorEntityDescription( - key="bluetooth", - entity_category=EntityCategory.DIAGNOSTIC, - translation_key="bluetooth", - is_on_fn=lambda device, _: device.bluetooth_state, - ), - AmazonBinarySensorEntityDescription( - key="babyCryDetectionState", - translation_key="baby_cry_detection", - is_on_fn=lambda device, key: (device.sensors[key].value != SENSOR_STATE_OFF), - is_supported=lambda device, key: device.sensors.get(key) is not None, - ), - AmazonBinarySensorEntityDescription( - key="beepingApplianceDetectionState", - translation_key="beeping_appliance_detection", - is_on_fn=lambda device, key: (device.sensors[key].value != SENSOR_STATE_OFF), - is_supported=lambda device, key: device.sensors.get(key) is not None, - ), - AmazonBinarySensorEntityDescription( - key="coughDetectionState", - translation_key="cough_detection", - is_on_fn=lambda device, key: (device.sensors[key].value != SENSOR_STATE_OFF), - is_supported=lambda device, key: device.sensors.get(key) is not None, - ), - AmazonBinarySensorEntityDescription( - key="dogBarkDetectionState", - translation_key="dog_bark_detection", - is_on_fn=lambda device, key: (device.sensors[key].value != SENSOR_STATE_OFF), - is_supported=lambda device, key: device.sensors.get(key) is not None, - ), - AmazonBinarySensorEntityDescription( - key="humanPresenceDetectionState", + key="detectionState", device_class=BinarySensorDeviceClass.MOTION, - is_on_fn=lambda device, key: (device.sensors[key].value != SENSOR_STATE_OFF), - is_supported=lambda device, key: device.sensors.get(key) is not None, - ), - AmazonBinarySensorEntityDescription( - key="waterSoundsDetectionState", - translation_key="water_sounds_detection", - is_on_fn=lambda device, key: (device.sensors[key].value != SENSOR_STATE_OFF), + is_on_fn=lambda device, key: bool( + device.sensors[key].value != SENSOR_STATE_OFF + ), is_supported=lambda device, key: device.sensors.get(key) is not None, + is_available_fn=lambda device, key: ( + device.online and device.sensors[key].error is False + ), ), ) @@ -94,6 +66,22 @@ async def async_setup_entry( coordinator = entry.runtime_data + # Replace unique id for "detectionState" binary sensor + await async_update_unique_id( + hass, + coordinator, + BINARY_SENSOR_DOMAIN, + "humanPresenceDetectionState", + "detectionState", + ) + + async_add_entities( + AmazonBinarySensorEntity(coordinator, serial_num, sensor_desc) + for sensor_desc in BINARY_SENSORS + for serial_num in coordinator.data + if sensor_desc.is_supported(coordinator.data[serial_num], sensor_desc.key) + ) + known_devices: set[str] = set() def _check_device() -> None: @@ -125,3 +113,13 @@ def is_on(self) -> bool: return self.entity_description.is_on_fn( self.device, self.entity_description.key ) + + @property + def available(self) -> bool: + """Return if entity is available.""" + return ( + self.entity_description.is_available_fn( + self.device, self.entity_description.key + ) + and super().available + ) diff --git a/homeassistant/components/alexa_devices/config_flow.py b/homeassistant/components/alexa_devices/config_flow.py index a3bcce1965b27..e863f137f70af 100644 --- a/homeassistant/components/alexa_devices/config_flow.py +++ b/homeassistant/components/alexa_devices/config_flow.py @@ -64,7 +64,7 @@ async def async_step_user( data = await validate_input(self.hass, user_input) except CannotConnect: errors["base"] = "cannot_connect" - except (CannotAuthenticate, TypeError): + except CannotAuthenticate: errors["base"] = "invalid_auth" except CannotRetrieveData: errors["base"] = "cannot_retrieve_data" @@ -112,7 +112,7 @@ async def async_step_reauth_confirm( ) except CannotConnect: errors["base"] = "cannot_connect" - except (CannotAuthenticate, TypeError): + except CannotAuthenticate: errors["base"] = "invalid_auth" except CannotRetrieveData: errors["base"] = "cannot_retrieve_data" diff --git a/homeassistant/components/alexa_devices/coordinator.py b/homeassistant/components/alexa_devices/coordinator.py index 3b14324fdb68c..6ce21aa221632 100644 --- a/homeassistant/components/alexa_devices/coordinator.py +++ b/homeassistant/components/alexa_devices/coordinator.py @@ -68,7 +68,7 @@ async def _async_update_data(self) -> dict[str, AmazonDevice]: translation_key="cannot_retrieve_data_with_error", translation_placeholders={"error": repr(err)}, ) from err - except (CannotAuthenticate, TypeError) as err: + except CannotAuthenticate as err: raise ConfigEntryAuthFailed( translation_domain=DOMAIN, translation_key="invalid_auth", diff --git a/homeassistant/components/alexa_devices/diagnostics.py b/homeassistant/components/alexa_devices/diagnostics.py index 0c4cb79441680..938a20fb21893 100644 --- a/homeassistant/components/alexa_devices/diagnostics.py +++ b/homeassistant/components/alexa_devices/diagnostics.py @@ -60,7 +60,5 @@ def build_device_data(device: AmazonDevice) -> dict[str, Any]: "online": device.online, "serial number": device.serial_number, "software version": device.software_version, - "do not disturb": device.do_not_disturb, - "response style": device.response_style, - "bluetooth state": device.bluetooth_state, + "sensors": device.sensors, } diff --git a/homeassistant/components/alexa_devices/icons.json b/homeassistant/components/alexa_devices/icons.json index bedd4af173424..f9e8de057d02c 100644 --- a/homeassistant/components/alexa_devices/icons.json +++ b/homeassistant/components/alexa_devices/icons.json @@ -1,44 +1,4 @@ { - "entity": { - "binary_sensor": { - "bluetooth": { - "default": "mdi:bluetooth-off", - "state": { - "on": "mdi:bluetooth" - } - }, - "baby_cry_detection": { - "default": "mdi:account-voice-off", - "state": { - "on": "mdi:account-voice" - } - }, - "beeping_appliance_detection": { - "default": "mdi:bell-off", - "state": { - "on": "mdi:bell-ring" - } - }, - "cough_detection": { - "default": "mdi:blur-off", - "state": { - "on": "mdi:blur" - } - }, - "dog_bark_detection": { - "default": "mdi:dog-side-off", - "state": { - "on": "mdi:dog-side" - } - }, - "water_sounds_detection": { - "default": "mdi:water-pump-off", - "state": { - "on": "mdi:water-pump" - } - } - } - }, "services": { "send_sound": { "service": "mdi:cast-audio" diff --git a/homeassistant/components/alexa_devices/manifest.json b/homeassistant/components/alexa_devices/manifest.json index 437c11e0a4c14..14b2ddf90d969 100644 --- a/homeassistant/components/alexa_devices/manifest.json +++ b/homeassistant/components/alexa_devices/manifest.json @@ -8,5 +8,5 @@ "iot_class": "cloud_polling", "loggers": ["aioamazondevices"], "quality_scale": "platinum", - "requirements": ["aioamazondevices==6.0.0"] + "requirements": ["aioamazondevices==6.2.6"] } diff --git a/homeassistant/components/alexa_devices/sensor.py b/homeassistant/components/alexa_devices/sensor.py index 1a863e87c1a77..e6dbc251b9507 100644 --- a/homeassistant/components/alexa_devices/sensor.py +++ b/homeassistant/components/alexa_devices/sensor.py @@ -31,6 +31,9 @@ class AmazonSensorEntityDescription(SensorEntityDescription): """Amazon Devices sensor entity description.""" native_unit_of_measurement_fn: Callable[[AmazonDevice, str], str] | None = None + is_available_fn: Callable[[AmazonDevice, str], bool] = lambda device, key: ( + device.online and device.sensors[key].error is False + ) SENSORS: Final = ( @@ -99,3 +102,13 @@ def native_unit_of_measurement(self) -> str | None: def native_value(self) -> StateType: """Return the state of the sensor.""" return self.device.sensors[self.entity_description.key].value + + @property + def available(self) -> bool: + """Return if entity is available.""" + return ( + self.entity_description.is_available_fn( + self.device, self.entity_description.key + ) + and super().available + ) diff --git a/homeassistant/components/alexa_devices/strings.json b/homeassistant/components/alexa_devices/strings.json index 8e56a7a51b617..f6b850f0920a1 100644 --- a/homeassistant/components/alexa_devices/strings.json +++ b/homeassistant/components/alexa_devices/strings.json @@ -58,26 +58,6 @@ } }, "entity": { - "binary_sensor": { - "bluetooth": { - "name": "Bluetooth" - }, - "baby_cry_detection": { - "name": "Baby crying" - }, - "beeping_appliance_detection": { - "name": "Beeping appliance" - }, - "cough_detection": { - "name": "Coughing" - }, - "dog_bark_detection": { - "name": "Dog barking" - }, - "water_sounds_detection": { - "name": "Water sounds" - } - }, "notify": { "speak": { "name": "Speak" diff --git a/homeassistant/components/alexa_devices/switch.py b/homeassistant/components/alexa_devices/switch.py index 138013666c6e4..2994ab777514d 100644 --- a/homeassistant/components/alexa_devices/switch.py +++ b/homeassistant/components/alexa_devices/switch.py @@ -8,13 +8,17 @@ from aioamazondevices.api import AmazonDevice -from homeassistant.components.switch import SwitchEntity, SwitchEntityDescription +from homeassistant.components.switch import ( + DOMAIN as SWITCH_DOMAIN, + SwitchEntity, + SwitchEntityDescription, +) from homeassistant.core import HomeAssistant from homeassistant.helpers.entity_platform import AddConfigEntryEntitiesCallback from .coordinator import AmazonConfigEntry from .entity import AmazonEntity -from .utils import alexa_api_call +from .utils import alexa_api_call, async_update_unique_id PARALLEL_UPDATES = 1 @@ -24,16 +28,17 @@ class AmazonSwitchEntityDescription(SwitchEntityDescription): """Alexa Devices switch entity description.""" is_on_fn: Callable[[AmazonDevice], bool] - subkey: str + is_available_fn: Callable[[AmazonDevice, str], bool] = lambda device, key: ( + device.online and device.sensors[key].error is False + ) method: str SWITCHES: Final = ( AmazonSwitchEntityDescription( - key="do_not_disturb", - subkey="AUDIO_PLAYER", + key="dnd", translation_key="do_not_disturb", - is_on_fn=lambda _device: _device.do_not_disturb, + is_on_fn=lambda device: bool(device.sensors["dnd"].value), method="set_do_not_disturb", ), ) @@ -48,6 +53,11 @@ async def async_setup_entry( coordinator = entry.runtime_data + # Replace unique id for "DND" switch and remove from Speaker Group + await async_update_unique_id( + hass, coordinator, SWITCH_DOMAIN, "do_not_disturb", "dnd" + ) + known_devices: set[str] = set() def _check_device() -> None: @@ -59,7 +69,7 @@ def _check_device() -> None: AmazonSwitchEntity(coordinator, serial_num, switch_desc) for switch_desc in SWITCHES for serial_num in new_devices - if switch_desc.subkey in coordinator.data[serial_num].capabilities + if switch_desc.key in coordinator.data[serial_num].sensors ) _check_device() @@ -94,3 +104,13 @@ async def async_turn_off(self, **kwargs: Any) -> None: def is_on(self) -> bool: """Return True if switch is on.""" return self.entity_description.is_on_fn(self.device) + + @property + def available(self) -> bool: + """Return if entity is available.""" + return ( + self.entity_description.is_available_fn( + self.device, self.entity_description.key + ) + and super().available + ) diff --git a/homeassistant/components/alexa_devices/utils.py b/homeassistant/components/alexa_devices/utils.py index 437b681413b61..f8898aa5fe46d 100644 --- a/homeassistant/components/alexa_devices/utils.py +++ b/homeassistant/components/alexa_devices/utils.py @@ -6,9 +6,12 @@ from aioamazondevices.exceptions import CannotConnect, CannotRetrieveData +from homeassistant.core import HomeAssistant from homeassistant.exceptions import HomeAssistantError +import homeassistant.helpers.entity_registry as er -from .const import DOMAIN +from .const import _LOGGER, DOMAIN +from .coordinator import AmazonDevicesCoordinator from .entity import AmazonEntity @@ -38,3 +41,23 @@ async def cmd_wrapper(self: _T, *args: _P.args, **kwargs: _P.kwargs) -> None: ) from err return cmd_wrapper + + +async def async_update_unique_id( + hass: HomeAssistant, + coordinator: AmazonDevicesCoordinator, + domain: str, + old_key: str, + new_key: str, +) -> None: + """Update unique id for entities created with old format.""" + entity_registry = er.async_get(hass) + + for serial_num in coordinator.data: + unique_id = f"{serial_num}-{old_key}" + if entity_id := entity_registry.async_get_entity_id(domain, DOMAIN, unique_id): + _LOGGER.debug("Updating unique_id for %s", entity_id) + new_unique_id = unique_id.replace(old_key, new_key) + + # Update the registry with the new unique_id + entity_registry.async_update_entity(entity_id, new_unique_id=new_unique_id) diff --git a/requirements_all.txt b/requirements_all.txt index 24f911f842459..c2f4528d1aad7 100644 --- a/requirements_all.txt +++ b/requirements_all.txt @@ -185,7 +185,7 @@ aioairzone-cloud==0.7.2 aioairzone==1.0.1 # homeassistant.components.alexa_devices -aioamazondevices==6.0.0 +aioamazondevices==6.2.6 # homeassistant.components.ambient_network # homeassistant.components.ambient_station diff --git a/requirements_test_all.txt b/requirements_test_all.txt index 868386b0f0f63..48d8d367b3aea 100644 --- a/requirements_test_all.txt +++ b/requirements_test_all.txt @@ -173,7 +173,7 @@ aioairzone-cloud==0.7.2 aioairzone==1.0.1 # homeassistant.components.alexa_devices -aioamazondevices==6.0.0 +aioamazondevices==6.2.6 # homeassistant.components.ambient_network # homeassistant.components.ambient_station diff --git a/tests/components/alexa_devices/const.py b/tests/components/alexa_devices/const.py index d078e92199ed3..05a6ff5871964 100644 --- a/tests/components/alexa_devices/const.py +++ b/tests/components/alexa_devices/const.py @@ -18,15 +18,13 @@ online=True, serial_number=TEST_DEVICE_1_SN, software_version="echo_test_software_version", - do_not_disturb=False, - response_style=None, - bluetooth_state=True, entity_id="11111111-2222-3333-4444-555555555555", - appliance_id="G1234567890123456789012345678A", + endpoint_id="G1234567890123456789012345678A", sensors={ + "dnd": AmazonDeviceSensor(name="dnd", value=False, error=False, scale=None), "temperature": AmazonDeviceSensor( - name="temperature", value="22.5", scale="CELSIUS" - ) + name="temperature", value="22.5", error=False, scale="CELSIUS" + ), }, ) @@ -42,14 +40,11 @@ online=True, serial_number=TEST_DEVICE_2_SN, software_version="echo_test_2_software_version", - do_not_disturb=False, - response_style=None, - bluetooth_state=True, entity_id="11111111-2222-3333-4444-555555555555", - appliance_id="G1234567890123456789012345678A", + endpoint_id="G1234567890123456789012345678A", sensors={ "temperature": AmazonDeviceSensor( - name="temperature", value="22.5", scale="CELSIUS" + name="temperature", value="22.5", error=False, scale="CELSIUS" ) }, ) diff --git a/tests/components/alexa_devices/snapshots/test_binary_sensor.ambr b/tests/components/alexa_devices/snapshots/test_binary_sensor.ambr index 16f9eeaedae84..c6b9a2afa08ab 100644 --- a/tests/components/alexa_devices/snapshots/test_binary_sensor.ambr +++ b/tests/components/alexa_devices/snapshots/test_binary_sensor.ambr @@ -1,52 +1,4 @@ # serializer version: 1 -# name: test_all_entities[binary_sensor.echo_test_bluetooth-entry] - EntityRegistryEntrySnapshot({ - 'aliases': set({ - }), - 'area_id': None, - 'capabilities': None, - 'config_entry_id': , - 'config_subentry_id': , - 'device_class': None, - 'device_id': , - 'disabled_by': None, - 'domain': 'binary_sensor', - 'entity_category': , - 'entity_id': 'binary_sensor.echo_test_bluetooth', - 'has_entity_name': True, - 'hidden_by': None, - 'icon': None, - 'id': , - 'labels': set({ - }), - 'name': None, - 'options': dict({ - }), - 'original_device_class': None, - 'original_icon': None, - 'original_name': 'Bluetooth', - 'platform': 'alexa_devices', - 'previous_unique_id': None, - 'suggested_object_id': None, - 'supported_features': 0, - 'translation_key': 'bluetooth', - 'unique_id': 'echo_test_serial_number-bluetooth', - 'unit_of_measurement': None, - }) -# --- -# name: test_all_entities[binary_sensor.echo_test_bluetooth-state] - StateSnapshot({ - 'attributes': ReadOnlyDict({ - 'friendly_name': 'Echo Test Bluetooth', - }), - 'context': , - 'entity_id': 'binary_sensor.echo_test_bluetooth', - 'last_changed': , - 'last_reported': , - 'last_updated': , - 'state': 'on', - }) -# --- # name: test_all_entities[binary_sensor.echo_test_connectivity-entry] EntityRegistryEntrySnapshot({ 'aliases': set({ diff --git a/tests/components/alexa_devices/snapshots/test_diagnostics.ambr b/tests/components/alexa_devices/snapshots/test_diagnostics.ambr index 9ae5832ce3343..2450d9e7d7bbc 100644 --- a/tests/components/alexa_devices/snapshots/test_diagnostics.ambr +++ b/tests/components/alexa_devices/snapshots/test_diagnostics.ambr @@ -2,7 +2,6 @@ # name: test_device_diagnostics dict({ 'account name': 'Echo Test', - 'bluetooth state': True, 'capabilities': list([ 'AUDIO_PLAYER', 'MICROPHONE', @@ -12,9 +11,17 @@ ]), 'device family': 'mine', 'device type': 'echo', - 'do not disturb': False, 'online': True, - 'response style': None, + 'sensors': dict({ + 'dnd': dict({ + '__type': "", + 'repr': "AmazonDeviceSensor(name='dnd', value=False, error=False, scale=None)", + }), + 'temperature': dict({ + '__type': "", + 'repr': "AmazonDeviceSensor(name='temperature', value='22.5', error=False, scale='CELSIUS')", + }), + }), 'serial number': 'echo_test_serial_number', 'software version': 'echo_test_software_version', }) @@ -25,7 +32,6 @@ 'devices': list([ dict({ 'account name': 'Echo Test', - 'bluetooth state': True, 'capabilities': list([ 'AUDIO_PLAYER', 'MICROPHONE', @@ -35,9 +41,17 @@ ]), 'device family': 'mine', 'device type': 'echo', - 'do not disturb': False, 'online': True, - 'response style': None, + 'sensors': dict({ + 'dnd': dict({ + '__type': "", + 'repr': "AmazonDeviceSensor(name='dnd', value=False, error=False, scale=None)", + }), + 'temperature': dict({ + '__type': "", + 'repr': "AmazonDeviceSensor(name='temperature', value='22.5', error=False, scale='CELSIUS')", + }), + }), 'serial number': 'echo_test_serial_number', 'software version': 'echo_test_software_version', }), diff --git a/tests/components/alexa_devices/snapshots/test_services.ambr b/tests/components/alexa_devices/snapshots/test_services.ambr index 12eab4a683bf9..dc15796c32c63 100644 --- a/tests/components/alexa_devices/snapshots/test_services.ambr +++ b/tests/components/alexa_devices/snapshots/test_services.ambr @@ -4,8 +4,6 @@ tuple( dict({ 'account_name': 'Echo Test', - 'appliance_id': 'G1234567890123456789012345678A', - 'bluetooth_state': True, 'capabilities': list([ 'AUDIO_PLAYER', 'MICROPHONE', @@ -16,12 +14,18 @@ 'device_family': 'mine', 'device_owner_customer_id': 'amazon_ower_id', 'device_type': 'echo', - 'do_not_disturb': False, + 'endpoint_id': 'G1234567890123456789012345678A', 'entity_id': '11111111-2222-3333-4444-555555555555', 'online': True, - 'response_style': None, 'sensors': dict({ + 'dnd': dict({ + 'error': False, + 'name': 'dnd', + 'scale': None, + 'value': False, + }), 'temperature': dict({ + 'error': False, 'name': 'temperature', 'scale': 'CELSIUS', 'value': '22.5', @@ -41,8 +45,6 @@ tuple( dict({ 'account_name': 'Echo Test', - 'appliance_id': 'G1234567890123456789012345678A', - 'bluetooth_state': True, 'capabilities': list([ 'AUDIO_PLAYER', 'MICROPHONE', @@ -53,12 +55,18 @@ 'device_family': 'mine', 'device_owner_customer_id': 'amazon_ower_id', 'device_type': 'echo', - 'do_not_disturb': False, + 'endpoint_id': 'G1234567890123456789012345678A', 'entity_id': '11111111-2222-3333-4444-555555555555', 'online': True, - 'response_style': None, 'sensors': dict({ + 'dnd': dict({ + 'error': False, + 'name': 'dnd', + 'scale': None, + 'value': False, + }), 'temperature': dict({ + 'error': False, 'name': 'temperature', 'scale': 'CELSIUS', 'value': '22.5', diff --git a/tests/components/alexa_devices/snapshots/test_switch.ambr b/tests/components/alexa_devices/snapshots/test_switch.ambr index c622cc67ea75a..3ce484cf95b93 100644 --- a/tests/components/alexa_devices/snapshots/test_switch.ambr +++ b/tests/components/alexa_devices/snapshots/test_switch.ambr @@ -30,7 +30,7 @@ 'suggested_object_id': None, 'supported_features': 0, 'translation_key': 'do_not_disturb', - 'unique_id': 'echo_test_serial_number-do_not_disturb', + 'unique_id': 'echo_test_serial_number-dnd', 'unit_of_measurement': None, }) # --- diff --git a/tests/components/alexa_devices/test_sensor.py b/tests/components/alexa_devices/test_sensor.py index 560a7e10b90d6..3bb1b3f0a0d86 100644 --- a/tests/components/alexa_devices/test_sensor.py +++ b/tests/components/alexa_devices/test_sensor.py @@ -134,10 +134,38 @@ async def test_unit_of_measurement( mock_amazon_devices_client.get_devices_data.return_value[ TEST_DEVICE_1_SN - ].sensors = {sensor: AmazonDeviceSensor(name=sensor, value=api_value, scale=scale)} + ].sensors = { + sensor: AmazonDeviceSensor( + name=sensor, value=api_value, error=False, scale=scale + ) + } await setup_integration(hass, mock_config_entry) assert (state := hass.states.get(entity_id)) assert state.state == state_value assert state.attributes["unit_of_measurement"] == unit + + +async def test_sensor_unavailable( + hass: HomeAssistant, + freezer: FrozenDateTimeFactory, + mock_amazon_devices_client: AsyncMock, + mock_config_entry: MockConfigEntry, +) -> None: + """Test sensor is unavailable.""" + + entity_id = "sensor.echo_test_illuminance" + + mock_amazon_devices_client.get_devices_data.return_value[ + TEST_DEVICE_1_SN + ].sensors = { + "illuminance": AmazonDeviceSensor( + name="illuminance", value="800", error=True, scale=None + ) + } + + await setup_integration(hass, mock_config_entry) + + assert (state := hass.states.get(entity_id)) + assert state.state == STATE_UNAVAILABLE diff --git a/tests/components/alexa_devices/test_switch.py b/tests/components/alexa_devices/test_switch.py index c5039d68da25a..6bbc1f68d0216 100644 --- a/tests/components/alexa_devices/test_switch.py +++ b/tests/components/alexa_devices/test_switch.py @@ -1,7 +1,9 @@ """Tests for the Alexa Devices switch platform.""" +from copy import deepcopy from unittest.mock import AsyncMock, patch +from aioamazondevices.api import AmazonDeviceSensor from freezegun.api import FrozenDateTimeFactory import pytest from syrupy.assertion import SnapshotAssertion @@ -23,10 +25,12 @@ from homeassistant.helpers import entity_registry as er from . import setup_integration -from .conftest import TEST_DEVICE_1_SN +from .conftest import TEST_DEVICE_1, TEST_DEVICE_1_SN from tests.common import MockConfigEntry, async_fire_time_changed, snapshot_platform +ENTITY_ID = "switch.echo_test_do_not_disturb" + @pytest.mark.usefixtures("entity_registry_enabled_by_default") async def test_all_entities( @@ -52,48 +56,59 @@ async def test_switch_dnd( """Test switching DND.""" await setup_integration(hass, mock_config_entry) - entity_id = "switch.echo_test_do_not_disturb" - - assert (state := hass.states.get(entity_id)) + assert (state := hass.states.get(ENTITY_ID)) assert state.state == STATE_OFF await hass.services.async_call( SWITCH_DOMAIN, SERVICE_TURN_ON, - {ATTR_ENTITY_ID: entity_id}, + {ATTR_ENTITY_ID: ENTITY_ID}, blocking=True, ) assert mock_amazon_devices_client.set_do_not_disturb.call_count == 1 - mock_amazon_devices_client.get_devices_data.return_value[ - TEST_DEVICE_1_SN - ].do_not_disturb = True + device_data = deepcopy(TEST_DEVICE_1) + device_data.sensors = { + "dnd": AmazonDeviceSensor(name="dnd", value=True, error=False, scale=None), + "temperature": AmazonDeviceSensor( + name="temperature", value="22.5", error=False, scale="CELSIUS" + ), + } + mock_amazon_devices_client.get_devices_data.return_value = { + TEST_DEVICE_1_SN: device_data + } freezer.tick(SCAN_INTERVAL) async_fire_time_changed(hass) await hass.async_block_till_done() - assert (state := hass.states.get(entity_id)) + assert (state := hass.states.get(ENTITY_ID)) assert state.state == STATE_ON await hass.services.async_call( SWITCH_DOMAIN, SERVICE_TURN_OFF, - {ATTR_ENTITY_ID: entity_id}, + {ATTR_ENTITY_ID: ENTITY_ID}, blocking=True, ) - mock_amazon_devices_client.get_devices_data.return_value[ - TEST_DEVICE_1_SN - ].do_not_disturb = False + device_data.sensors = { + "dnd": AmazonDeviceSensor(name="dnd", value=False, error=False, scale=None), + "temperature": AmazonDeviceSensor( + name="temperature", value="22.5", error=False, scale="CELSIUS" + ), + } + mock_amazon_devices_client.get_devices_data.return_value = { + TEST_DEVICE_1_SN: device_data + } freezer.tick(SCAN_INTERVAL) async_fire_time_changed(hass) await hass.async_block_till_done() assert mock_amazon_devices_client.set_do_not_disturb.call_count == 2 - assert (state := hass.states.get(entity_id)) + assert (state := hass.states.get(ENTITY_ID)) assert state.state == STATE_OFF @@ -104,16 +119,13 @@ async def test_offline_device( mock_config_entry: MockConfigEntry, ) -> None: """Test offline device handling.""" - - entity_id = "switch.echo_test_do_not_disturb" - mock_amazon_devices_client.get_devices_data.return_value[ TEST_DEVICE_1_SN ].online = False await setup_integration(hass, mock_config_entry) - assert (state := hass.states.get(entity_id)) + assert (state := hass.states.get(ENTITY_ID)) assert state.state == STATE_UNAVAILABLE mock_amazon_devices_client.get_devices_data.return_value[ @@ -124,5 +136,5 @@ async def test_offline_device( async_fire_time_changed(hass) await hass.async_block_till_done() - assert (state := hass.states.get(entity_id)) + assert (state := hass.states.get(ENTITY_ID)) assert state.state != STATE_UNAVAILABLE diff --git a/tests/components/alexa_devices/test_utils.py b/tests/components/alexa_devices/test_utils.py index 1cf190bd29765..020971d8f76f8 100644 --- a/tests/components/alexa_devices/test_utils.py +++ b/tests/components/alexa_devices/test_utils.py @@ -10,8 +10,10 @@ from homeassistant.const import ATTR_ENTITY_ID, STATE_OFF from homeassistant.core import HomeAssistant from homeassistant.exceptions import HomeAssistantError +from homeassistant.helpers import device_registry as dr, entity_registry as er from . import setup_integration +from .const import TEST_DEVICE_1_SN from tests.common import MockConfigEntry @@ -54,3 +56,41 @@ async def test_alexa_api_call_exceptions( assert exc_info.value.translation_domain == DOMAIN assert exc_info.value.translation_key == key assert exc_info.value.translation_placeholders == {"error": error} + + +async def test_alexa_unique_id_migration( + hass: HomeAssistant, + mock_amazon_devices_client: AsyncMock, + mock_config_entry: MockConfigEntry, + device_registry: dr.DeviceRegistry, + entity_registry: er.EntityRegistry, +) -> None: + """Test unique_id migration.""" + + mock_config_entry.add_to_hass(hass) + + device = device_registry.async_get_or_create( + config_entry_id=mock_config_entry.entry_id, + identifiers={(DOMAIN, mock_config_entry.entry_id)}, + name=mock_config_entry.title, + manufacturer="Amazon", + model="Echo Dot", + entry_type=dr.DeviceEntryType.SERVICE, + ) + + entity = entity_registry.async_get_or_create( + SWITCH_DOMAIN, + DOMAIN, + unique_id=f"{TEST_DEVICE_1_SN}-do_not_disturb", + device_id=device.id, + config_entry=mock_config_entry, + has_entity_name=True, + ) + + await hass.config_entries.async_setup(mock_config_entry.entry_id) + await hass.async_block_till_done() + + migrated_entity = entity_registry.async_get(entity.entity_id) + assert migrated_entity is not None + assert migrated_entity.config_entry_id == mock_config_entry.entry_id + assert migrated_entity.unique_id == f"{TEST_DEVICE_1_SN}-dnd" From 3c0b13975a0fc1f84813aa20216d72b01f170dc2 Mon Sep 17 00:00:00 2001 From: Paul Bottein Date: Thu, 25 Sep 2025 19:05:12 +0200 Subject: [PATCH 09/15] Update frontend to 20250925.1 (#152985) --- homeassistant/components/frontend/manifest.json | 2 +- homeassistant/package_constraints.txt | 2 +- requirements_all.txt | 2 +- requirements_test_all.txt | 2 +- 4 files changed, 4 insertions(+), 4 deletions(-) diff --git a/homeassistant/components/frontend/manifest.json b/homeassistant/components/frontend/manifest.json index bf7c9642c131e..618711c5354a5 100644 --- a/homeassistant/components/frontend/manifest.json +++ b/homeassistant/components/frontend/manifest.json @@ -20,5 +20,5 @@ "documentation": "https://www.home-assistant.io/integrations/frontend", "integration_type": "system", "quality_scale": "internal", - "requirements": ["home-assistant-frontend==20250925.0"] + "requirements": ["home-assistant-frontend==20250925.1"] } diff --git a/homeassistant/package_constraints.txt b/homeassistant/package_constraints.txt index f9d165d5b3b4d..725e5269a91cd 100644 --- a/homeassistant/package_constraints.txt +++ b/homeassistant/package_constraints.txt @@ -39,7 +39,7 @@ habluetooth==5.6.4 hass-nabucasa==1.1.2 hassil==3.2.0 home-assistant-bluetooth==1.13.1 -home-assistant-frontend==20250925.0 +home-assistant-frontend==20250925.1 home-assistant-intents==2025.9.24 httpx==0.28.1 ifaddr==0.2.0 diff --git a/requirements_all.txt b/requirements_all.txt index c2f4528d1aad7..4fd13040322e8 100644 --- a/requirements_all.txt +++ b/requirements_all.txt @@ -1186,7 +1186,7 @@ hole==0.9.0 holidays==0.81 # homeassistant.components.frontend -home-assistant-frontend==20250925.0 +home-assistant-frontend==20250925.1 # homeassistant.components.conversation home-assistant-intents==2025.9.24 diff --git a/requirements_test_all.txt b/requirements_test_all.txt index 48d8d367b3aea..b9cdfb90e5bf1 100644 --- a/requirements_test_all.txt +++ b/requirements_test_all.txt @@ -1035,7 +1035,7 @@ hole==0.9.0 holidays==0.81 # homeassistant.components.frontend -home-assistant-frontend==20250925.0 +home-assistant-frontend==20250925.1 # homeassistant.components.conversation home-assistant-intents==2025.9.24 From 35faaa6cae429b5992a2fb11ad839a8d47f5b651 Mon Sep 17 00:00:00 2001 From: Norbert Rittel Date: Thu, 25 Sep 2025 19:19:27 +0200 Subject: [PATCH 10/15] Add missing square brackets to references in `fully_kiosk` actions (#152987) --- homeassistant/components/fully_kiosk/strings.json | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/homeassistant/components/fully_kiosk/strings.json b/homeassistant/components/fully_kiosk/strings.json index 785124575ba8a..11c91c1f637a3 100644 --- a/homeassistant/components/fully_kiosk/strings.json +++ b/homeassistant/components/fully_kiosk/strings.json @@ -162,8 +162,8 @@ "description": "Sets a configuration parameter on Fully Kiosk Browser.", "fields": { "device_id": { - "name": "%key:component::fully_kiosk::services::load_url::fields::device_id::name%", - "description": "%key:component::fully_kiosk::services::load_url::fields::device_id::description%" + "name": "[%key:component::fully_kiosk::services::load_url::fields::device_id::name%]", + "description": "[%key:component::fully_kiosk::services::load_url::fields::device_id::description%]" }, "key": { "name": "Key", @@ -184,8 +184,8 @@ "description": "Package name of the application to start." }, "device_id": { - "name": "%key:component::fully_kiosk::services::load_url::fields::device_id::name%", - "description": "%key:component::fully_kiosk::services::load_url::fields::device_id::description%" + "name": "[%key:component::fully_kiosk::services::load_url::fields::device_id::name%]", + "description": "[%key:component::fully_kiosk::services::load_url::fields::device_id::description%]" } } } From c4389a1679b6af100f0012aa4a9f058cb6d1021b Mon Sep 17 00:00:00 2001 From: "J. Nick Koston" Date: Thu, 25 Sep 2025 12:21:17 -0500 Subject: [PATCH 11/15] Bump aioesphomeapi to 41.10.0 (#152975) Co-authored-by: Michael Hansen --- homeassistant/components/esphome/manifest.json | 2 +- requirements_all.txt | 2 +- requirements_test_all.txt | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/homeassistant/components/esphome/manifest.json b/homeassistant/components/esphome/manifest.json index 674ced0bf9c66..2918f79ed2d2b 100644 --- a/homeassistant/components/esphome/manifest.json +++ b/homeassistant/components/esphome/manifest.json @@ -17,7 +17,7 @@ "mqtt": ["esphome/discover/#"], "quality_scale": "platinum", "requirements": [ - "aioesphomeapi==41.9.4", + "aioesphomeapi==41.10.0", "esphome-dashboard-api==1.3.0", "bleak-esphome==3.3.0" ], diff --git a/requirements_all.txt b/requirements_all.txt index 4fd13040322e8..bf00576c5d2a5 100644 --- a/requirements_all.txt +++ b/requirements_all.txt @@ -247,7 +247,7 @@ aioelectricitymaps==1.1.1 aioemonitor==1.0.5 # homeassistant.components.esphome -aioesphomeapi==41.9.4 +aioesphomeapi==41.10.0 # homeassistant.components.flo aioflo==2021.11.0 diff --git a/requirements_test_all.txt b/requirements_test_all.txt index b9cdfb90e5bf1..9549fca52ff12 100644 --- a/requirements_test_all.txt +++ b/requirements_test_all.txt @@ -235,7 +235,7 @@ aioelectricitymaps==1.1.1 aioemonitor==1.0.5 # homeassistant.components.esphome -aioesphomeapi==41.9.4 +aioesphomeapi==41.10.0 # homeassistant.components.flo aioflo==2021.11.0 From 52de5ff5ffb11df825522f2fab07ef7dff9f8bf1 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ab=C3=ADlio=20Costa?= Date: Thu, 25 Sep 2025 18:23:40 +0100 Subject: [PATCH 12/15] Remove deprecated zone and event condition keys (#152986) --- homeassistant/components/zone/condition.py | 5 +---- homeassistant/helpers/config_validation.py | 3 --- 2 files changed, 1 insertion(+), 7 deletions(-) diff --git a/homeassistant/components/zone/condition.py b/homeassistant/components/zone/condition.py index caa75b4e0be1d..90c6761efc56d 100644 --- a/homeassistant/components/zone/condition.py +++ b/homeassistant/components/zone/condition.py @@ -30,12 +30,9 @@ from . import in_zone -_OPTIONS_SCHEMA_DICT = { +_OPTIONS_SCHEMA_DICT: dict[vol.Marker, Any] = { vol.Required(CONF_ENTITY_ID): cv.entity_ids, vol.Required("zone"): cv.entity_ids, - # To support use_trigger_value in automation - # Deprecated 2016/04/25 - vol.Optional("event"): vol.Any("enter", "leave"), } _CONDITION_SCHEMA = vol.Schema({CONF_OPTIONS: _OPTIONS_SCHEMA_DICT}) diff --git a/homeassistant/helpers/config_validation.py b/homeassistant/helpers/config_validation.py index 4e289a1313b43..7110ad267af00 100644 --- a/homeassistant/helpers/config_validation.py +++ b/homeassistant/helpers/config_validation.py @@ -1545,9 +1545,6 @@ def _backward_compat_service_schema(value: Any | None) -> Any: ), vol.Optional(CONF_ATTRIBUTE): str, vol.Optional(CONF_FOR): positive_time_period_template, - # To support use_trigger_value in automation - # Deprecated 2016/04/25 - vol.Optional("from"): str, } STATE_CONDITION_STATE_SCHEMA = vol.Schema( From 5b70910d77bfc5614f3372328db83a147eba192f Mon Sep 17 00:00:00 2001 From: Noah Husby <32528627+noahhusby@users.noreply.github.com> Date: Thu, 25 Sep 2025 13:34:29 -0500 Subject: [PATCH 13/15] Bump aiorussound to 4.8.2 (#152988) --- homeassistant/components/russound_rio/manifest.json | 2 +- requirements_all.txt | 2 +- requirements_test_all.txt | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/homeassistant/components/russound_rio/manifest.json b/homeassistant/components/russound_rio/manifest.json index efaf8f195adc3..b1b35385495d8 100644 --- a/homeassistant/components/russound_rio/manifest.json +++ b/homeassistant/components/russound_rio/manifest.json @@ -7,6 +7,6 @@ "iot_class": "local_push", "loggers": ["aiorussound"], "quality_scale": "silver", - "requirements": ["aiorussound==4.8.1"], + "requirements": ["aiorussound==4.8.2"], "zeroconf": ["_rio._tcp.local."] } diff --git a/requirements_all.txt b/requirements_all.txt index bf00576c5d2a5..acf7caea4f479 100644 --- a/requirements_all.txt +++ b/requirements_all.txt @@ -375,7 +375,7 @@ aioridwell==2025.09.0 aioruckus==0.42 # homeassistant.components.russound_rio -aiorussound==4.8.1 +aiorussound==4.8.2 # homeassistant.components.ruuvi_gateway aioruuvigateway==0.1.0 diff --git a/requirements_test_all.txt b/requirements_test_all.txt index 9549fca52ff12..1663089b4f45c 100644 --- a/requirements_test_all.txt +++ b/requirements_test_all.txt @@ -357,7 +357,7 @@ aioridwell==2025.09.0 aioruckus==0.42 # homeassistant.components.russound_rio -aiorussound==4.8.1 +aiorussound==4.8.2 # homeassistant.components.ruuvi_gateway aioruuvigateway==0.1.0 From 7450b3fd1a25e561f7e27af35ae540ebfe54e56f Mon Sep 17 00:00:00 2001 From: Simone Chemelli Date: Thu, 25 Sep 2025 21:39:44 +0200 Subject: [PATCH 14/15] Improve tests for Alexa Devices (#152995) --- tests/components/alexa_devices/test_binary_sensor.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/tests/components/alexa_devices/test_binary_sensor.py b/tests/components/alexa_devices/test_binary_sensor.py index bcb89664da46f..6b55a701b459a 100644 --- a/tests/components/alexa_devices/test_binary_sensor.py +++ b/tests/components/alexa_devices/test_binary_sensor.py @@ -123,6 +123,8 @@ async def test_dynamic_device( assert (state := hass.states.get(entity_id_1)) assert state.state == STATE_ON + assert not hass.states.get(entity_id_2) + mock_amazon_devices_client.get_devices_data.return_value = { TEST_DEVICE_1_SN: TEST_DEVICE_1, TEST_DEVICE_2_SN: TEST_DEVICE_2, From 6d0470064f53e6b82bab1fb70f48cd131e9f6377 Mon Sep 17 00:00:00 2001 From: Brandon Harvey <8107750+bharvey88@users.noreply.github.com> Date: Thu, 25 Sep 2025 15:54:06 -0400 Subject: [PATCH 15/15] Rename service to action in ESPHome (#152997) --- homeassistant/components/esphome/manager.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/homeassistant/components/esphome/manager.py b/homeassistant/components/esphome/manager.py index c3db4c3e9e8ec..239dfe5662ac0 100644 --- a/homeassistant/components/esphome/manager.py +++ b/homeassistant/components/esphome/manager.py @@ -1073,7 +1073,7 @@ def _async_register_service( service_name, { "description": ( - f"Calls the service {service.name} of the node {device_info.name}" + f"Performs the action {service.name} of the node {device_info.name}" ), "fields": fields, },