From ed17d11f2a1d2cb7d4c12ab7be3ff605de4ad28f Mon Sep 17 00:00:00 2001 From: "J. Nick Koston" Date: Thu, 7 Mar 2024 10:53:39 -1000 Subject: [PATCH] merge --- homeassistant/config_entries.py | 7 +++---- homeassistant/core.py | 3 +-- 2 files changed, 4 insertions(+), 6 deletions(-) diff --git a/homeassistant/config_entries.py b/homeassistant/config_entries.py index 77f7ec982405..a6e92d6576d4 100644 --- a/homeassistant/config_entries.py +++ b/homeassistant/config_entries.py @@ -1054,14 +1054,13 @@ class ConfigEntry: ) -> asyncio.Task[_R]: """Create a periodic task tied to the config entry lifecycle. - This type of task is for background tasks that usually run for - the lifetime of Home Assistant or an integration's setup. + This type of task is typically used for polling. - This is a background task which is different from a normal task: + This is a periodic task which is different from a normal task: - Will not block startup - Will be automatically cancelled on shutdown - - Calls to async_block_till_done will not wait for completion + - Calls to async_block_till_done will wait for completion by default This method must be run in the event loop. """ diff --git a/homeassistant/core.py b/homeassistant/core.py index 14b8c7f2f3a5..df42c1951e18 100644 --- a/homeassistant/core.py +++ b/homeassistant/core.py @@ -703,8 +703,7 @@ class HomeAssistant: ) -> asyncio.Task[_R]: """Create a task from within the event loop. - This type of tasks is for periodic updates such as polling - entities. + This type of task is typically used for polling. This is a periodic task which is different from a normal task: