From 6f6b85f9cfc70bfc452d8e88997d52086686c844 Mon Sep 17 00:00:00 2001 From: Grzegorz Bokota Date: Fri, 6 Feb 2026 00:46:16 +0100 Subject: [PATCH 01/16] Drop test against pyside2 in napari repo case --- .github/workflows/test_napari_repo.yml | 2 +- tox.ini | 16 ++++++++++++---- 2 files changed, 13 insertions(+), 5 deletions(-) diff --git a/.github/workflows/test_napari_repo.yml b/.github/workflows/test_napari_repo.yml index 18a3e62e3..1270132d2 100644 --- a/.github/workflows/test_napari_repo.yml +++ b/.github/workflows/test_napari_repo.yml @@ -34,7 +34,7 @@ jobs: fail-fast: false matrix: platform: [ ubuntu-24.04 ] - python: ['3.10', '3.11', '3.12'] + python: ['3.10', '3.11', '3.12', '3.13'] napari_version: ['repo'] steps: - uses: actions/checkout@v6 diff --git a/tox.ini b/tox.ini index b8651056d..5660717bd 100644 --- a/tox.ini +++ b/tox.ini @@ -71,15 +71,23 @@ deps= pytest-json-report lxml_html_clean -[testenv:py{39,310,311,312,313}-{PyQt5,PySide2,PyQt6,PySide6}-napari_{419,54,repo}] + +[testenv:py{39,310,311,312,313}-{PyQt5,PySide2,PyQt6,PySide6}-napari_{419,54}] deps = {[testenv]deps} napari_419: napari==0.4.19.post1 napari_54: napari==0.5.4 - napari_repo: git+https://github.com/napari/napari.git commands = - !napari_repo: python -m pytest -v package/tests/test_PartSeg/test_napari_widgets.py --json-report --json-report-file={toxinidir}/report-{envname}-{sys_platform}.json {posargs} - napari_repo: python -m pytest package/tests --json-report --json-report-file={toxinidir}/report-{envname}-{sys_platform}.json {posargs} + python -m pytest -v package/tests/test_PartSeg/test_napari_widgets.py --json-report --json-report-file={toxinidir}/report-{envname}-{sys_platform}.json {posargs} + + +[testenv:py{310,311,312,313}-{PyQt5,PyQt6,PySide6}-napari_repo] +deps = + {[testenv]deps} + git+https://github.com/napari/napari.git +commands = + python -m pytest package/tests --json-report --json-report-file={toxinidir}/report-{envname}-{sys_platform}.json {posargs} + [testenv:py{39,310,311,312,313}-PyQt5-coverage] deps = From 3eb6d6f5ac67a8df72450f54f00ee5efe43480fe Mon Sep 17 00:00:00 2001 From: Grzegorz Bokota Date: Fri, 6 Feb 2026 11:30:07 +0100 Subject: [PATCH 02/16] do not show viewer before add layers --- package/PartSeg/common_gui/main_window.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/package/PartSeg/common_gui/main_window.py b/package/PartSeg/common_gui/main_window.py index 6f5ba861b..b7e15d586 100644 --- a/package/PartSeg/common_gui/main_window.py +++ b/package/PartSeg/common_gui/main_window.py @@ -227,10 +227,13 @@ def get_colormaps(self) -> list[Optional[colormap.Colormap]]: return [self.settings.colormap_dict[name][0] for name in colormaps_name] def napari_viewer_show(self): - viewer = Viewer(title="Additional output", settings=self.settings, partseg_viewer_name=self.channel_info) + viewer = Viewer( + title="Additional output", settings=self.settings, partseg_viewer_name=self.channel_info, show=False + ) viewer.scale_bar.unit = "nm" viewer.theme = self.settings.theme_name viewer.create_initial_layers(image=True, roi=True, additional_layers=False, points=True) + viewer.show() self.viewer_list.append(viewer) viewer.window.qt_viewer.destroyed.connect(lambda _x: self.close_viewer(viewer)) From ab839c01ecdb9775c6191b6e83f6671941d4776e Mon Sep 17 00:00:00 2001 From: Grzegorz Bokota Date: Tue, 10 Feb 2026 10:58:49 +0100 Subject: [PATCH 03/16] trigger ci From 73b7ec87bf4820fe4378eccb872a0e37036387d6 Mon Sep 17 00:00:00 2001 From: Grzegorz Bokota Date: Tue, 10 Feb 2026 11:39:13 +0100 Subject: [PATCH 04/16] chore: Proper support for test selection by `posargs` in `tox` configuration --- tox.ini | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/tox.ini b/tox.ini index 5660717bd..230cfdbdc 100644 --- a/tox.ini +++ b/tox.ini @@ -78,7 +78,7 @@ deps = napari_419: napari==0.4.19.post1 napari_54: napari==0.5.4 commands = - python -m pytest -v package/tests/test_PartSeg/test_napari_widgets.py --json-report --json-report-file={toxinidir}/report-{envname}-{sys_platform}.json {posargs} + python -m pytest -v --json-report --json-report-file={toxinidir}/report-{envname}-{sys_platform}.json {posargs:package/tests/test_PartSeg/test_napari_widgets.py} [testenv:py{310,311,312,313}-{PyQt5,PyQt6,PySide6}-napari_repo] @@ -86,7 +86,7 @@ deps = {[testenv]deps} git+https://github.com/napari/napari.git commands = - python -m pytest package/tests --json-report --json-report-file={toxinidir}/report-{envname}-{sys_platform}.json {posargs} + python -m pytest --json-report --json-report-file={toxinidir}/report-{envname}-{sys_platform}.json {posargs:package/tests} [testenv:py{39,310,311,312,313}-PyQt5-coverage] From a2be4d18d181714be5f00286436d22c12e883b0a Mon Sep 17 00:00:00 2001 From: Grzegorz Bokota Date: Wed, 11 Feb 2026 10:42:48 +0100 Subject: [PATCH 05/16] trigger ci From 36a0ab8c9da30886d6615820f7cf5fb889eeab52 Mon Sep 17 00:00:00 2001 From: Grzegorz Bokota Date: Wed, 11 Feb 2026 11:59:44 +0100 Subject: [PATCH 06/16] fix showing window --- package/PartSeg/common_gui/main_window.py | 5 ++++- package/tests/test_PartSeg/test_viewer.py | 13 +++++++------ 2 files changed, 11 insertions(+), 7 deletions(-) diff --git a/package/PartSeg/common_gui/main_window.py b/package/PartSeg/common_gui/main_window.py index b7e15d586..e4dc5daea 100644 --- a/package/PartSeg/common_gui/main_window.py +++ b/package/PartSeg/common_gui/main_window.py @@ -241,9 +241,12 @@ def additional_layers_show(self, with_channels=False): if not self.settings.additional_layers: QMessageBox().information(self, "No data", "Last executed algorithm does not provide additional data") return - viewer = Viewer(title="Additional output", settings=self.settings, partseg_viewer_name=self.channel_info) + viewer = Viewer( + title="Additional output", settings=self.settings, partseg_viewer_name=self.channel_info, show=False + ) viewer.theme = self.settings.theme_name viewer.create_initial_layers(image=with_channels, roi=False, additional_layers=True, points=False) + viewer.show() self.viewer_list.append(viewer) viewer.window.qt_viewer.destroyed.connect(lambda _x: self.close_viewer(viewer)) diff --git a/package/tests/test_PartSeg/test_viewer.py b/package/tests/test_PartSeg/test_viewer.py index 3284e7261..97461edee 100644 --- a/package/tests/test_PartSeg/test_viewer.py +++ b/package/tests/test_PartSeg/test_viewer.py @@ -73,7 +73,7 @@ class TestNapariViewer: def test_base(self, image, analysis_segmentation2, tmp_path): settings = BaseSettings(tmp_path) settings.image = image - viewer = Viewer(settings, "") + viewer = Viewer(settings, "", show=False) viewer.create_initial_layers(True, True, True, True) assert len(viewer.layers) == 2 viewer.create_initial_layers(True, True, True, True) @@ -92,7 +92,7 @@ def test_base(self, image, analysis_segmentation2, tmp_path): def test_points(self, image, tmp_path, qtbot): settings = BaseSettings(tmp_path) settings.image = image - viewer = Viewer(settings, "") + viewer = Viewer(settings, "", show=False) viewer.create_initial_layers(True, True, True, True) assert len(viewer.layers) == 2 points = np.array([[0, 1, 1, 1], [0, 7, 10, 10]]) @@ -113,7 +113,7 @@ def test_points(self, image, tmp_path, qtbot): def test_image(self, image, image2, tmp_path, qtbot): settings = BaseSettings(tmp_path) settings.image = image - viewer = Viewer(settings, "test") + viewer = Viewer(settings, "test", show=False) with qtbot.waitSignal(viewer._sync_widget.sync_image_chk.stateChanged): viewer._sync_widget.sync_image_chk.setChecked(True) assert len(viewer.layers) == 2 @@ -125,7 +125,7 @@ def test_image(self, image, image2, tmp_path, qtbot): def test_roi(self, image, tmp_path, qtbot): settings = BaseSettings(tmp_path) settings.image = image - viewer = Viewer(settings, "test") + viewer = Viewer(settings, "test", show=False) viewer._sync_widget.sync_image() assert len(viewer.layers) == 2 viewer._sync_widget.sync_ROI_chk.setChecked(True) @@ -135,10 +135,11 @@ def test_roi(self, image, tmp_path, qtbot): assert len(viewer.layers) == 4 viewer.close() - def test_additional(self, image, tmp_path, qtbot): + @pytest.mark.usefixtures("qtbot") + def test_additional(self, image, tmp_path): settings = BaseSettings(tmp_path) settings.image = image - viewer = Viewer(settings, "test") + viewer = Viewer(settings, "test", show=False) viewer._sync_widget.sync_image() assert len(viewer.layers) == 2 settings._additional_layers = { From 5324bebc56eaa6bb1da61c8849c3888bcad8446a Mon Sep 17 00:00:00 2001 From: Grzegorz Bokota Date: Wed, 11 Feb 2026 12:00:29 +0100 Subject: [PATCH 07/16] Fix tox env list --- tox.ini | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tox.ini b/tox.ini index 230cfdbdc..829e5182a 100644 --- a/tox.ini +++ b/tox.ini @@ -4,7 +4,7 @@ # and then run "tox" from this directory. [tox] -envlist = py{39,310,311,312,313}-{PyQt5,PySide2,PyQt6,PySide6}-all, py{39,310,311,312,313}-{PyQt5,PyQt6}-napari_{419,54,repo}, py{39,310}-PySide2-napari_{419,54,repo} +envlist = py{39,310,311,312,313}-{PyQt5,PySide2,PyQt6,PySide6}-all, py{39,310,311,312,313}-{PyQt5,PyQt6}-napari_{419,54,repo}, py{312,313}-PySide6-napari_{419,54,repo} toxworkdir=/tmp/tox [gh-actions] From 3ae12cdc36bbcf672adfa048dccb19fd420b9671 Mon Sep 17 00:00:00 2001 From: Grzegorz Bokota Date: Wed, 11 Feb 2026 12:24:35 +0100 Subject: [PATCH 08/16] next fix tox env list --- tox.ini | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tox.ini b/tox.ini index 829e5182a..52bc92020 100644 --- a/tox.ini +++ b/tox.ini @@ -4,7 +4,7 @@ # and then run "tox" from this directory. [tox] -envlist = py{39,310,311,312,313}-{PyQt5,PySide2,PyQt6,PySide6}-all, py{39,310,311,312,313}-{PyQt5,PyQt6}-napari_{419,54,repo}, py{312,313}-PySide6-napari_{419,54,repo} +envlist = py{39,310,311,312,313}-{PyQt5,PySide2,PyQt6,PySide6}-all, py{310,311,312,313}-{PyQt5,PyQt6}-napari_{419,54,repo},py39-{PyQt5,PyQt6}-napari_{419,54} , py{312,313}-PySide6-napari_{419,54,repo} toxworkdir=/tmp/tox [gh-actions] From f92ef081eb7c0205408a5a7af949c0164f8ecdda Mon Sep 17 00:00:00 2001 From: Grzegorz Bokota Date: Wed, 11 Feb 2026 14:35:26 +0100 Subject: [PATCH 09/16] check modified workflow --- .github/workflows/base_test_workflow.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/base_test_workflow.yml b/.github/workflows/base_test_workflow.yml index ffd24d1de..5d82aec19 100644 --- a/.github/workflows/base_test_workflow.yml +++ b/.github/workflows/base_test_workflow.yml @@ -126,7 +126,7 @@ jobs: uses: aganders3/headless-gui@v2 timeout-minutes: ${{ inputs.timeout }} with: - run: python -m tox ${{ inputs.tox_args }} -- ${{ inputs.pytest_args }} + run: python -m tox ${{ inputs.tox_args }} ${{ inputs.pytest_args != '' && format('-- {0}', inputs.pytest_args) || '' }} env: PYVISTA_OFF_SCREEN: True # required for opengl on windows NAPARI: ${{ inputs.napari }} From c57ff16270b066ef7d43e1f14490d94a5d37d995 Mon Sep 17 00:00:00 2001 From: Grzegorz Bokota Date: Wed, 11 Feb 2026 14:39:22 +0100 Subject: [PATCH 10/16] fix tox config --- tox.ini | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tox.ini b/tox.ini index 52bc92020..ade89b999 100644 --- a/tox.ini +++ b/tox.ini @@ -4,7 +4,7 @@ # and then run "tox" from this directory. [tox] -envlist = py{39,310,311,312,313}-{PyQt5,PySide2,PyQt6,PySide6}-all, py{310,311,312,313}-{PyQt5,PyQt6}-napari_{419,54,repo},py39-{PyQt5,PyQt6}-napari_{419,54} , py{312,313}-PySide6-napari_{419,54,repo} +envlist = py{39,310,311,312,313}-{PyQt5,PySide2,PyQt6,PySide6}-all, py{310,311,312,313}-{PyQt5,PyQt6}-napari_repo,py{39,310,311,312,313}-{PyQt5,PyQt6,Pyside2}-napari_{419,54} , py{312,313}-PySide6-napari_{419,54,repo} toxworkdir=/tmp/tox [gh-actions] From 228f07b4394653fa736eeff65ff1d64421146acb Mon Sep 17 00:00:00 2001 From: Grzegorz Bokota Date: Wed, 11 Feb 2026 15:03:57 +0100 Subject: [PATCH 11/16] fix tox config --- tox.ini | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tox.ini b/tox.ini index ade89b999..b5acaa3b5 100644 --- a/tox.ini +++ b/tox.ini @@ -4,7 +4,7 @@ # and then run "tox" from this directory. [tox] -envlist = py{39,310,311,312,313}-{PyQt5,PySide2,PyQt6,PySide6}-all, py{310,311,312,313}-{PyQt5,PyQt6}-napari_repo,py{39,310,311,312,313}-{PyQt5,PyQt6,Pyside2}-napari_{419,54} , py{312,313}-PySide6-napari_{419,54,repo} +envlist = py{39,310,311,312,313}-{PyQt5,PySide2,PyQt6,PySide6}-all, py{310,311,312,313}-{PyQt5,PyQt6}-napari_repo,py{39,310,311,312,313}-{PyQt5,PyQt6,PySide2}-napari_{419,54}, py{312,313}-PySide6-napari_{419,54,repo} toxworkdir=/tmp/tox [gh-actions] From ebecc1a9e8190c0f688f43cd2a33d47d7f711b34 Mon Sep 17 00:00:00 2001 From: Grzegorz Bokota Date: Wed, 11 Feb 2026 20:34:41 +0100 Subject: [PATCH 12/16] improve workflow safety --- .github/workflows/base_test_workflow.yml | 27 ++++++++++-------------- 1 file changed, 11 insertions(+), 16 deletions(-) diff --git a/.github/workflows/base_test_workflow.yml b/.github/workflows/base_test_workflow.yml index 5d82aec19..e9941d0a3 100644 --- a/.github/workflows/base_test_workflow.yml +++ b/.github/workflows/base_test_workflow.yml @@ -52,6 +52,12 @@ jobs: test: name: ${{ inputs.os }} py ${{ inputs.python_version }} ${{ inputs.napari }} ${{ inputs.qt_backend }} ${{ inputs.pydantic }} runs-on: ${{ inputs.os }} + env: + NAPARI: ${{ inputs.napari }} + BACKEND: ${{ inputs.qt_backend }} + PYVISTA_OFF_SCREEN: True # required for opengl on windows + TOX_ARGS: ${{ inputs.tox_args }} + PYTEST_ARGS: ${{ inputs.pytest_args }} steps: - uses: actions/checkout@v6 - uses: actions/setup-python@v6 @@ -90,21 +96,15 @@ jobs: - name: Test with tox PartSegImage if: ${{ inputs.napari == 'latest' }} - run: python -m tox ${{ inputs.tox_args }} -- package/tests/test_PartSegImage ${{ inputs.pytest_args }} + run: python -m tox $TOX_ARGS -- package/tests/test_PartSegImage $PYTEST_ARGS env: - PYVISTA_OFF_SCREEN: True # required for opengl on windows - NAPARI: ${{ inputs.napari }} - BACKEND: ${{ inputs.qt_backend }} PIP_CONSTRAINT: ${{ inputs.napari == 'latest' && format('requirements/constraints_py{0}{1}.txt', inputs.python_version, inputs.pydantic ) || 'requirements/version_denylist.txt' }} UV_CONSTRAINT: ${{ inputs.napari == 'latest' && format('requirements/constraints_py{0}{1}.txt', inputs.python_version, inputs.pydantic ) || 'requirements/version_denylist.txt' }} - name: Test with tox PartSegCore if: ${{ inputs.napari == 'latest' }} - run: python -m tox ${{ inputs.tox_args }} -- package/tests/test_PartSegCore ${{ inputs.pytest_args }} + run: python -m tox $TOX_ARGS -- package/tests/test_PartSegCore $PYTEST_ARGS env: - PYVISTA_OFF_SCREEN: True # required for opengl on windows - NAPARI: ${{ inputs.napari }} - BACKEND: ${{ inputs.qt_backend }} PIP_CONSTRAINT: ${{ inputs.napari == 'latest' && format('requirements/constraints_py{0}{1}.txt', inputs.python_version, inputs.pydantic ) || 'requirements/version_denylist.txt' }} UV_CONSTRAINT: ${{ inputs.napari == 'latest' && format('requirements/constraints_py{0}{1}.txt', inputs.python_version, inputs.pydantic ) || 'requirements/version_denylist.txt' }} @@ -113,11 +113,8 @@ jobs: uses: aganders3/headless-gui@v2 timeout-minutes: ${{ inputs.timeout }} with: - run: python -m tox ${{ inputs.tox_args }} -- package/tests/test_PartSeg ${{ inputs.pytest_args }} + run: python -m tox $TOX_ARGS -- package/tests/test_PartSeg $PYTEST_ARGS env: - PYVISTA_OFF_SCREEN: True # required for opengl on windows - NAPARI: ${{ inputs.napari }} - BACKEND: ${{ inputs.qt_backend }} PIP_CONSTRAINT: ${{ inputs.napari == 'latest' && format('requirements/constraints_py{0}{1}.txt', inputs.python_version, inputs.pydantic ) || 'requirements/version_denylist.txt' }} UV_CONSTRAINT: ${{ inputs.napari == 'latest' && format('requirements/constraints_py{0}{1}.txt', inputs.python_version, inputs.pydantic ) || 'requirements/version_denylist.txt' }} @@ -126,11 +123,9 @@ jobs: uses: aganders3/headless-gui@v2 timeout-minutes: ${{ inputs.timeout }} with: - run: python -m tox ${{ inputs.tox_args }} ${{ inputs.pytest_args != '' && format('-- {0}', inputs.pytest_args) || '' }} + run: python -m tox $TOX_ARGS $PYTEST_ARGS env: - PYVISTA_OFF_SCREEN: True # required for opengl on windows - NAPARI: ${{ inputs.napari }} - BACKEND: ${{ inputs.qt_backend }} + PYTEST_ARGS: ${{ inputs.pytest_args != '' && format('-- {0}', inputs.pytest_args) || '' }} PIP_CONSTRAINT: ${{ inputs.napari == 'latest' && format('requirements/constraints_py{0}{1}.txt', inputs.python_version, inputs.pydantic ) || 'requirements/version_denylist.txt' }} UV_CONSTRAINT: ${{ inputs.napari == 'latest' && format('requirements/constraints_py{0}{1}.txt', inputs.python_version, inputs.pydantic ) || 'requirements/version_denylist.txt' }} From 0d4964870dd55adc3ff1f1308c8825fc15645352 Mon Sep 17 00:00:00 2001 From: Grzegorz Bokota Date: Wed, 11 Feb 2026 20:47:42 +0100 Subject: [PATCH 13/16] next fix --- .github/workflows/base_test_workflow.yml | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/.github/workflows/base_test_workflow.yml b/.github/workflows/base_test_workflow.yml index e9941d0a3..fe7959b76 100644 --- a/.github/workflows/base_test_workflow.yml +++ b/.github/workflows/base_test_workflow.yml @@ -123,9 +123,8 @@ jobs: uses: aganders3/headless-gui@v2 timeout-minutes: ${{ inputs.timeout }} with: - run: python -m tox $TOX_ARGS $PYTEST_ARGS + run: python -m tox $TOX_ARGS ${PYTEST_ARGS:+-- $PYTEST_ARGS} env: - PYTEST_ARGS: ${{ inputs.pytest_args != '' && format('-- {0}', inputs.pytest_args) || '' }} PIP_CONSTRAINT: ${{ inputs.napari == 'latest' && format('requirements/constraints_py{0}{1}.txt', inputs.python_version, inputs.pydantic ) || 'requirements/version_denylist.txt' }} UV_CONSTRAINT: ${{ inputs.napari == 'latest' && format('requirements/constraints_py{0}{1}.txt', inputs.python_version, inputs.pydantic ) || 'requirements/version_denylist.txt' }} From 953e11e99e5d5e584742771a6a4dddbbfec7acba Mon Sep 17 00:00:00 2001 From: Grzegorz Bokota Date: Wed, 11 Feb 2026 21:05:14 +0100 Subject: [PATCH 14/16] switch to pyvista/setup-headless-display-action --- .github/workflows/base_test_workflow.yml | 25 ++++++------------------ 1 file changed, 6 insertions(+), 19 deletions(-) diff --git a/.github/workflows/base_test_workflow.yml b/.github/workflows/base_test_workflow.yml index fe7959b76..f2bb66b33 100644 --- a/.github/workflows/base_test_workflow.yml +++ b/.github/workflows/base_test_workflow.yml @@ -67,20 +67,11 @@ jobs: cache: 'pip' cache-dependency-path: 'pyproject.toml' -# - name: Install ubuntu libraries -# if: runner.os == 'Linux' -# run: | -# sudo apt update -# sudo apt-get install -y libegl1 libdbus-1-3 libxkbcommon-x11-0 libxcb-icccm4 libxcb-image0 libxcb-keysyms1 libxcb-randr0 libxcb-render-util0 libxcb-xinerama0 libxcb-xinput0 libxcb-xfixes0 x11-utils libxcb-cursor0 - - - uses: awalsh128/cache-apt-pkgs-action@latest - if: runner.os == 'Linux' + - name: Setup headless display + uses: pyvista/setup-headless-display-action@7d84ae825e6d9297a8e99bdbbae20d1b919a0b19 # v4.2 with: - packages: libegl1 libdbus-1-3 libxkbcommon-x11-0 libxcb-icccm4 libxcb-image0 libxcb-keysyms1 libxcb-randr0 libxcb-render-util0 libxcb-xinerama0 libxcb-xinput0 libxcb-xfixes0 x11-utils libxcb-cursor0 libhdf5-dev - version: 1.0 - - - name: Install Windows OpenGL - uses: pyvista/setup-headless-display-action@v4 + qt: true + wm: herbstluftwm - name: Download test data if: ${{ inputs.test_data }} @@ -110,20 +101,16 @@ jobs: - name: Test with tox PartSeg if: ${{ inputs.napari == 'latest' }} - uses: aganders3/headless-gui@v2 timeout-minutes: ${{ inputs.timeout }} - with: - run: python -m tox $TOX_ARGS -- package/tests/test_PartSeg $PYTEST_ARGS + run: python -m tox $TOX_ARGS -- package/tests/test_PartSeg $PYTEST_ARGS env: PIP_CONSTRAINT: ${{ inputs.napari == 'latest' && format('requirements/constraints_py{0}{1}.txt', inputs.python_version, inputs.pydantic ) || 'requirements/version_denylist.txt' }} UV_CONSTRAINT: ${{ inputs.napari == 'latest' && format('requirements/constraints_py{0}{1}.txt', inputs.python_version, inputs.pydantic ) || 'requirements/version_denylist.txt' }} - name: Test with tox all if: ${{ inputs.napari != 'latest' }} - uses: aganders3/headless-gui@v2 timeout-minutes: ${{ inputs.timeout }} - with: - run: python -m tox $TOX_ARGS ${PYTEST_ARGS:+-- $PYTEST_ARGS} + run: python -m tox $TOX_ARGS ${PYTEST_ARGS:+-- $PYTEST_ARGS} env: PIP_CONSTRAINT: ${{ inputs.napari == 'latest' && format('requirements/constraints_py{0}{1}.txt', inputs.python_version, inputs.pydantic ) || 'requirements/version_denylist.txt' }} UV_CONSTRAINT: ${{ inputs.napari == 'latest' && format('requirements/constraints_py{0}{1}.txt', inputs.python_version, inputs.pydantic ) || 'requirements/version_denylist.txt' }} From 3e594396c28feb51e6b7d5c6593e6ba6a21dbd7d Mon Sep 17 00:00:00 2001 From: Grzegorz Bokota Date: Wed, 11 Feb 2026 21:15:15 +0100 Subject: [PATCH 15/16] nforce shell and silence shellcheck --- .github/workflows/base_test_workflow.yml | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/.github/workflows/base_test_workflow.yml b/.github/workflows/base_test_workflow.yml index f2bb66b33..ae7bf2710 100644 --- a/.github/workflows/base_test_workflow.yml +++ b/.github/workflows/base_test_workflow.yml @@ -87,6 +87,8 @@ jobs: - name: Test with tox PartSegImage if: ${{ inputs.napari == 'latest' }} + shell: bash + # shellcheck disable=SC2086 run: python -m tox $TOX_ARGS -- package/tests/test_PartSegImage $PYTEST_ARGS env: PIP_CONSTRAINT: ${{ inputs.napari == 'latest' && format('requirements/constraints_py{0}{1}.txt', inputs.python_version, inputs.pydantic ) || 'requirements/version_denylist.txt' }} @@ -94,6 +96,8 @@ jobs: - name: Test with tox PartSegCore if: ${{ inputs.napari == 'latest' }} + shell: bash + # shellcheck disable=SC2086 run: python -m tox $TOX_ARGS -- package/tests/test_PartSegCore $PYTEST_ARGS env: PIP_CONSTRAINT: ${{ inputs.napari == 'latest' && format('requirements/constraints_py{0}{1}.txt', inputs.python_version, inputs.pydantic ) || 'requirements/version_denylist.txt' }} @@ -102,6 +106,8 @@ jobs: - name: Test with tox PartSeg if: ${{ inputs.napari == 'latest' }} timeout-minutes: ${{ inputs.timeout }} + shell: bash + # shellcheck disable=SC2086 run: python -m tox $TOX_ARGS -- package/tests/test_PartSeg $PYTEST_ARGS env: PIP_CONSTRAINT: ${{ inputs.napari == 'latest' && format('requirements/constraints_py{0}{1}.txt', inputs.python_version, inputs.pydantic ) || 'requirements/version_denylist.txt' }} @@ -110,6 +116,8 @@ jobs: - name: Test with tox all if: ${{ inputs.napari != 'latest' }} timeout-minutes: ${{ inputs.timeout }} + shell: bash + # shellcheck disable=SC2086 run: python -m tox $TOX_ARGS ${PYTEST_ARGS:+-- $PYTEST_ARGS} env: PIP_CONSTRAINT: ${{ inputs.napari == 'latest' && format('requirements/constraints_py{0}{1}.txt', inputs.python_version, inputs.pydantic ) || 'requirements/version_denylist.txt' }} From 622b890535facae43a4fe421947096d37a7c26b2 Mon Sep 17 00:00:00 2001 From: Grzegorz Bokota Date: Wed, 11 Feb 2026 21:44:34 +0100 Subject: [PATCH 16/16] silence shellcheck v2 --- .github/workflows/base_test_workflow.yml | 20 ++++++++++++-------- 1 file changed, 12 insertions(+), 8 deletions(-) diff --git a/.github/workflows/base_test_workflow.yml b/.github/workflows/base_test_workflow.yml index ae7bf2710..43e5ec2df 100644 --- a/.github/workflows/base_test_workflow.yml +++ b/.github/workflows/base_test_workflow.yml @@ -88,8 +88,9 @@ jobs: - name: Test with tox PartSegImage if: ${{ inputs.napari == 'latest' }} shell: bash - # shellcheck disable=SC2086 - run: python -m tox $TOX_ARGS -- package/tests/test_PartSegImage $PYTEST_ARGS + run: | + # shellcheck disable=SC2086 + python -m tox $TOX_ARGS -- package/tests/test_PartSegImage $PYTEST_ARGS env: PIP_CONSTRAINT: ${{ inputs.napari == 'latest' && format('requirements/constraints_py{0}{1}.txt', inputs.python_version, inputs.pydantic ) || 'requirements/version_denylist.txt' }} UV_CONSTRAINT: ${{ inputs.napari == 'latest' && format('requirements/constraints_py{0}{1}.txt', inputs.python_version, inputs.pydantic ) || 'requirements/version_denylist.txt' }} @@ -97,8 +98,9 @@ jobs: - name: Test with tox PartSegCore if: ${{ inputs.napari == 'latest' }} shell: bash - # shellcheck disable=SC2086 - run: python -m tox $TOX_ARGS -- package/tests/test_PartSegCore $PYTEST_ARGS + run: | + # shellcheck disable=SC2086 + python -m tox $TOX_ARGS -- package/tests/test_PartSegCore $PYTEST_ARGS env: PIP_CONSTRAINT: ${{ inputs.napari == 'latest' && format('requirements/constraints_py{0}{1}.txt', inputs.python_version, inputs.pydantic ) || 'requirements/version_denylist.txt' }} UV_CONSTRAINT: ${{ inputs.napari == 'latest' && format('requirements/constraints_py{0}{1}.txt', inputs.python_version, inputs.pydantic ) || 'requirements/version_denylist.txt' }} @@ -107,8 +109,9 @@ jobs: if: ${{ inputs.napari == 'latest' }} timeout-minutes: ${{ inputs.timeout }} shell: bash - # shellcheck disable=SC2086 - run: python -m tox $TOX_ARGS -- package/tests/test_PartSeg $PYTEST_ARGS + run: | + # shellcheck disable=SC2086 + python -m tox $TOX_ARGS -- package/tests/test_PartSeg $PYTEST_ARGS env: PIP_CONSTRAINT: ${{ inputs.napari == 'latest' && format('requirements/constraints_py{0}{1}.txt', inputs.python_version, inputs.pydantic ) || 'requirements/version_denylist.txt' }} UV_CONSTRAINT: ${{ inputs.napari == 'latest' && format('requirements/constraints_py{0}{1}.txt', inputs.python_version, inputs.pydantic ) || 'requirements/version_denylist.txt' }} @@ -117,8 +120,9 @@ jobs: if: ${{ inputs.napari != 'latest' }} timeout-minutes: ${{ inputs.timeout }} shell: bash - # shellcheck disable=SC2086 - run: python -m tox $TOX_ARGS ${PYTEST_ARGS:+-- $PYTEST_ARGS} + run: | + # shellcheck disable=SC2086 + python -m tox $TOX_ARGS ${PYTEST_ARGS:+-- $PYTEST_ARGS} env: PIP_CONSTRAINT: ${{ inputs.napari == 'latest' && format('requirements/constraints_py{0}{1}.txt', inputs.python_version, inputs.pydantic ) || 'requirements/version_denylist.txt' }} UV_CONSTRAINT: ${{ inputs.napari == 'latest' && format('requirements/constraints_py{0}{1}.txt', inputs.python_version, inputs.pydantic ) || 'requirements/version_denylist.txt' }}