From 333c151955ae1f3dafa38efab78d56f8f98bca73 Mon Sep 17 00:00:00 2001 From: Tim van Cann <timvancann@gmail.com> Date: Sat, 4 Jul 2020 17:47:12 +0200 Subject: [PATCH] Call sync function from async context (#37324) --- homeassistant/components/avri/sensor.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/homeassistant/components/avri/sensor.py b/homeassistant/components/avri/sensor.py index a4931004a92..06519a5c455 100644 --- a/homeassistant/components/avri/sensor.py +++ b/homeassistant/components/avri/sensor.py @@ -22,7 +22,7 @@ async def async_setup_entry( integration_id = entry.data[CONF_ID] try: - each_upcoming = client.upcoming_of_each() + each_upcoming = await hass.async_add_executor_job(client.upcoming_of_each) except AvriException as ex: raise PlatformNotReady from ex else: -- GitLab