From beb70daf14bc14acad076b34dca39a3ca6b633bb Mon Sep 17 00:00:00 2001 From: Sviatoslav Sydorenko Date: Fri, 19 Aug 2022 19:07:34 +0200 Subject: [PATCH] Fix pytest collection during test_host partial run Sometimes pytest errors out with an `ImportError` during its tests collection stage when a Python package/directory containing the test module does not have an `__init__.py` in it. This is being observed under Python 3.9 and higher. The patch provides a workaround for this problem but does not address the root cause which is currently unknown. Ref: https://github.com/ansible/ansible/pull/78585#issuecomment-1220885431 --- test/units/inventory/__init__.py | 0 1 file changed, 0 insertions(+), 0 deletions(-) create mode 100644 test/units/inventory/__init__.py diff --git a/test/units/inventory/__init__.py b/test/units/inventory/__init__.py new file mode 100644 index 00000000000..e69de29bb2d