summaryrefslogtreecommitdiff
path: root/kvmd/aiotools.py
diff options
context:
space:
mode:
Diffstat (limited to 'kvmd/aiotools.py')
-rw-r--r--kvmd/aiotools.py5
1 files changed, 5 insertions, 0 deletions
diff --git a/kvmd/aiotools.py b/kvmd/aiotools.py
index 993209d1..9f854489 100644
--- a/kvmd/aiotools.py
+++ b/kvmd/aiotools.py
@@ -105,6 +105,11 @@ def run_sync(coro: Coroutine[Any, Any, _RetvalT]) -> _RetvalT:
# =====
+async def wait_infinite() -> None:
+ await asyncio.get_event_loop().create_future()
+
+
+# =====
@contextlib.asynccontextmanager
async def unlock_only_on_exception(lock: asyncio.Lock) -> AsyncGenerator[None, None]:
await lock.acquire()