From 1e31e2944bf2006b8c08c5576d615bcf0a802e1a Mon Sep 17 00:00:00 2001 From: Simone Chemelli Date: Mon, 14 Apr 2025 09:50:29 +0200 Subject: [PATCH] Add parallel updates to UptimeRobot (#142849) --- homeassistant/components/uptimerobot/binary_sensor.py | 3 +++ homeassistant/components/uptimerobot/sensor.py | 3 +++ homeassistant/components/uptimerobot/switch.py | 3 +++ 3 files changed, 9 insertions(+) diff --git a/homeassistant/components/uptimerobot/binary_sensor.py b/homeassistant/components/uptimerobot/binary_sensor.py index 0ad39a5b2c0..f35c7bd87bd 100644 --- a/homeassistant/components/uptimerobot/binary_sensor.py +++ b/homeassistant/components/uptimerobot/binary_sensor.py @@ -14,6 +14,9 @@ from .const import DOMAIN from .coordinator import UptimeRobotConfigEntry, UptimeRobotDataUpdateCoordinator from .entity import UptimeRobotEntity +# Coordinator is used to centralize the data updates +PARALLEL_UPDATES = 0 + async def async_setup_entry( hass: HomeAssistant, diff --git a/homeassistant/components/uptimerobot/sensor.py b/homeassistant/components/uptimerobot/sensor.py index 1f1db8844e6..2c0b77fcc20 100644 --- a/homeassistant/components/uptimerobot/sensor.py +++ b/homeassistant/components/uptimerobot/sensor.py @@ -23,6 +23,9 @@ SENSORS_INFO = { 9: "down", } +# Coordinator is used to centralize the data updates +PARALLEL_UPDATES = 0 + async def async_setup_entry( hass: HomeAssistant, diff --git a/homeassistant/components/uptimerobot/switch.py b/homeassistant/components/uptimerobot/switch.py index edd93d06e0b..a527bf8ec9b 100644 --- a/homeassistant/components/uptimerobot/switch.py +++ b/homeassistant/components/uptimerobot/switch.py @@ -18,6 +18,9 @@ from .const import API_ATTR_OK, DOMAIN, LOGGER from .coordinator import UptimeRobotConfigEntry, UptimeRobotDataUpdateCoordinator from .entity import UptimeRobotEntity +# Limit the number of parallel updates to 1 +PARALLEL_UPDATES = 1 + async def async_setup_entry( hass: HomeAssistant,