From 05325fe302c6b16968f9c86cf569f1f3a6c3a9b6 Mon Sep 17 00:00:00 2001 From: Zoheb Shaikh <26975142+ZohebShaikh@users.noreply.github.com> Date: Wed, 15 Jul 2026 08:55:19 +0000 Subject: [PATCH 1/2] tests: fix pytest-xdist and pytest-timeout working together --- pyproject.toml | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/pyproject.toml b/pyproject.toml index 315870950..06a4d8284 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -103,10 +103,11 @@ addopts = '--tb=native -vv --doctest-modules --doctest-glob="*.rst"' # https://iscinumpy.gitlab.io/post/bound-version-constraints/#watch-for-warnings filterwarnings = ["error", "ignore::DeprecationWarning"] # Doctest python code in docs, python code in src docstrings, test functions in tests +timeout_method = "thread" +timeout_func_only = true testpaths = "docs src tests" asyncio_mode = "auto" -timeout = 10 - +timeout = 1 [tool.coverage.run] patch = ["subprocess"] data_file = "/tmp/blueapi.coverage" @@ -160,6 +161,8 @@ commands = [ "pytest", "-n", "logical", + "--max-worker-restart", + "0", "tests/unit_tests", "--cov=blueapi", "--cov-report", From 0e91d67a8614c0ce584879ec07834426e2f63771 Mon Sep 17 00:00:00 2001 From: Zoheb Shaikh <26975142+ZohebShaikh@users.noreply.github.com> Date: Wed, 15 Jul 2026 09:03:02 +0000 Subject: [PATCH 2/2] increase timeout --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 06a4d8284..575f5b669 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -107,7 +107,7 @@ timeout_method = "thread" timeout_func_only = true testpaths = "docs src tests" asyncio_mode = "auto" -timeout = 1 +timeout = 1.5 [tool.coverage.run] patch = ["subprocess"] data_file = "/tmp/blueapi.coverage"