From: Tom Hromatka Date: Wed, 17 Jul 2024 19:06:49 +0000 (-0600) Subject: ftests: Add more smarts when creating a container X-Git-Tag: v3.2.0~94 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=e1a1b8fe1d9a08b6df0068a6711d1311b713e705;p=thirdparty%2Flibcgroup.git ftests: Add more smarts when creating a container If lxc returns 'Instance is busy running a "create" operation', the container was successfully created but it's not yet fully running. Call this a success as future operations will succeed once the container has fully started. Signed-off-by: Tom Hromatka --- diff --git a/tests/ftests/container.py b/tests/ftests/container.py index a54f6a3a..594c73e9 100644 --- a/tests/ftests/container.py +++ b/tests/ftests/container.py @@ -102,6 +102,9 @@ class Container(object): try: Run.run(cmd) q.put(True) + except RunError as re: + if re.stderr.find('Instance is busy running a "create" operation') >= 0: + q.put(True) except Exception: # noqa: E722 q.put(False) except BaseException: # noqa: E722