From 9bab13c47af98d8c2db2ce50a803463591320875532e92499a2ecb5f3e1df050 Mon Sep 17 00:00:00 2001 From: Benjamin Greiner Date: Thu, 28 Nov 2024 12:19:00 +0000 Subject: [PATCH] - Disable server async tests. It's just too flaky on obs OBS-URL: https://build.opensuse.org/package/show/devel:languages:python:numeric/python-panel?expand=0&rev=64 --- python-panel.changes | 5 +++++ python-panel.spec | 31 +++++++++++++++---------------- 2 files changed, 20 insertions(+), 16 deletions(-) diff --git a/python-panel.changes b/python-panel.changes index 6d2c026..6f34779 100644 --- a/python-panel.changes +++ b/python-panel.changes @@ -1,3 +1,8 @@ +------------------------------------------------------------------- +Thu Nov 28 12:05:47 UTC 2024 - Ben Greiner + +- Disable server async tests. It's just too flaky on obs + ------------------------------------------------------------------- Wed Nov 27 16:03:51 UTC 2024 - Ben Greiner diff --git a/python-panel.spec b/python-panel.spec index 1f86112..c778ace 100644 --- a/python-panel.spec +++ b/python-panel.spec @@ -25,6 +25,9 @@ %bcond_with test %endif +# too flaky server-side. Test it locally +%bcond_with servertests + # truncate trailing suffix %define distversion 1.5.4 Name: python-panel%{psuffix} @@ -131,6 +134,7 @@ to all Python flavors. %autosetup -p1 -n panel-%{version} # no color for pytest sed -i '/addopts/ s/--color=yes//' pyproject.toml +sed -i /asyncio_default_fixture_loop_scope/d pyproject.toml rm panel/.eslintrc.js for p in panel/tests/io/reload_module.py do \ @@ -142,7 +146,7 @@ pushd panel rm package-lock.json local-npm-registry %{_sourcedir} install --include=dev --include=peer popd -sed -i /asyncio_default_fixture_loop_scope/d pyproject.toml + %if ! %{with test} %build @@ -157,25 +161,20 @@ sed -i /asyncio_default_fixture_loop_scope/d pyproject.toml %if %{with test} %check export PYTEST_DEBUG_TEMPROOT=$(mktemp -d -p ./) -# flaky async tests -donttest="test_server_async_callbacks" -donttest="$donttest or test_get_server" -donttest="$donttest or test_server_update" -# flaky timeout -donttest="$donttest or test_server_thread_pool_change_event or test_server_on_load_after_init" -# upstream skips it for win and osx, we skip it because it (flakily) terminates everything on aarch64 -donttest="$donttest or (test_terminal and test_subprocess)" -# file sample.pdf missing -donttest="$donttest or test_pdf_local_file" -# (very) flaky async test: loop already running -# Don't test on 32-bit: asyncio is too flaky -[ $(getconf LONG_BIT) -eq 32 ] && exit 0 +# test_compile tries to build and write next to the imported module: permission denied +export PYTHONPATH=":x" # no network connection in obs deselectmark=(-m "not internet") # no multiflavor playwright ignorefiles=(--ignore scripts/panelite/test/test_utils.py --ignore scripts/panelite/test/test_panelite.py) -# test_compile tries to build and write next to the imported module: permission denied -PYTHONPATH=":x" +# upstream skips it for win and osx, we skip it because it (flakily) terminates everything on aarch64 +donttest="(test_terminal and test_subprocess)" +# file sample.pdf missing +donttest="$donttest or test_pdf_local_file" +%if !%{with servertests} +# flaky async tests +donttest="$donttest or test_server" +%endif %pytest -n auto -rsfE -k "not ($donttest)" "${deselectmark[@]}" "${ignorefiles[@]}" -p no:unraisableexception %endif