From eaca5f3629f6eb90b9257d6abdb2207cf930aad5 Mon Sep 17 00:00:00 2001 From: Helmut Grohne Date: Fri, 19 Apr 2024 05:32:22 +0200 Subject: examples/cgroup.py: use asyncio.run --- examples/cgroup.py | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/examples/cgroup.py b/examples/cgroup.py index da222f9..8fa8457 100755 --- a/examples/cgroup.py +++ b/examples/cgroup.py @@ -121,9 +121,7 @@ def main() -> None: # hierarchy is immediately writeable. For others, we may create a scope # unit. if ravel is not None: - asyncio.get_event_loop().run_until_complete( - start_transient_unit_with_ravel(os.getpid()) - ) + asyncio.run(start_transient_unit_with_ravel(os.getpid())) mycgroup = get_cgroup() else: # Re-execute ourselves via systemd-run. -- cgit v1.2.3