diff --git a/.github/workflows/make_release.yml b/.github/workflows/make_release.yml index 763c64ea5..a0d7193ae 100644 --- a/.github/workflows/make_release.yml +++ b/.github/workflows/make_release.yml @@ -35,14 +35,12 @@ jobs: - uses: actions/setup-python@v6 with: python-version: "3.12" - - uses: tlambert03/setup-qt-libs@v1 - - name: Install Windows OpenGL - if: runner.os == 'Windows' - run: | - git clone --depth 1 https://github.com/pyvista/gl-ci-helpers.git - powershell gl-ci-helpers/appveyor/install_opengl.ps1 - if (Test-Path -Path "C:\Windows\system32\opengl32.dll" -PathType Leaf) {Exit 0} else {Exit 1} - shell: powershell + - name: Setup headless display + uses: pyvista/setup-headless-display-action@7d84ae825e6d9297a8e99bdbbae20d1b919a0b19 # v4.2 + with: + qt: true + wm: herbstluftwm + - name: Install PartSeg run: python -m pip install --editable ".[pyinstaller]" --constraint requirements/constraints_py3.12.txt @@ -56,9 +54,7 @@ jobs: path: dist2 - name: Test PartSeg bundle - uses: aganders3/headless-gui@v2 - with: - run: dist/PartSeg/PartSeg _test || dist/PartSeg/PartSeg _test || dist/PartSeg/PartSeg _test + run: dist/PartSeg/PartSeg _test || dist/PartSeg/PartSeg _test || dist/PartSeg/PartSeg _test create_release: diff --git a/.github/workflows/test_napari_repo.yml b/.github/workflows/test_napari_repo.yml index 4a2d6a0e3..fe0749f93 100644 --- a/.github/workflows/test_napari_repo.yml +++ b/.github/workflows/test_napari_repo.yml @@ -44,15 +44,11 @@ jobs: with: python-version: ${{ matrix.python }} - - name: Install Windows OpenGL - if: runner.os == 'Windows' - run: | - git clone --depth 1 git://github.com/pyvista/gl-ci-helpers.git - powershell gl-ci-helpers/appveyor/install_opengl.ps1 - if (Test-Path -Path "C:\Windows\system32\opengl32.dll" -PathType Leaf) {Exit 0} else {Exit 1} - shell: powershell - - - uses: tlambert03/setup-qt-libs@v1 + - name: Setup headless display + uses: pyvista/setup-headless-display-action@7d84ae825e6d9297a8e99bdbbae20d1b919a0b19 # v4.2 + with: + qt: true + wm: herbstluftwm - name: Install dependencies run: | @@ -67,10 +63,8 @@ jobs: - name: Test with tox # run tests using pip install --pre - uses: aganders3/headless-gui@v2 timeout-minutes: 60 - with: - run: tox + run: tox env: PLATFORM: ${{ matrix.platform }} NAPARI: ${{ matrix.napari_version }} diff --git a/.github/workflows/test_prereleases.yml b/.github/workflows/test_prereleases.yml index 91ef12d20..804863960 100644 --- a/.github/workflows/test_prereleases.yml +++ b/.github/workflows/test_prereleases.yml @@ -62,10 +62,11 @@ jobs: cache: 'pip' cache-dependency-path: 'pyproject.toml' - - name: Install Windows OpenGL - uses: pyvista/setup-headless-display-action@v4 - - - uses: tlambert03/setup-qt-libs@v1 + - name: Setup headless display + uses: pyvista/setup-headless-display-action@7d84ae825e6d9297a8e99bdbbae20d1b919a0b19 # v4.2 + with: + qt: true + wm: herbstluftwm - name: Download test data uses: actions/download-artifact@v7 @@ -80,10 +81,8 @@ jobs: - name: Test with tox base # run tests using pip install --pre - uses: aganders3/headless-gui@v2 timeout-minutes: 60 - with: - run: python -m tox run -v -- -v package/tests/test_PartSegImage package/tests/test_PartSegCore + run: python -m tox run -v -- -v package/tests/test_PartSegImage package/tests/test_PartSegCore env: PLATFORM: ${{ matrix.platform }} PYVISTA_OFF_SCREEN: True # required for opengl on windows @@ -94,10 +93,8 @@ jobs: - name: Test with tox linux # run tests using pip install --pre - uses: aganders3/headless-gui@v2 timeout-minutes: 60 - with: - run: python -m tox run -v -- -v package/tests/test_PartSeg + run: python -m tox run -v -- -v package/tests/test_PartSeg env: PLATFORM: ${{ matrix.platform }} PYVISTA_OFF_SCREEN: True # required for opengl on windows @@ -125,19 +122,21 @@ jobs: runs-on: "ubuntu-latest" steps: - uses: actions/checkout@v6 - - uses: actions/setup-python@v6 - name: Install Python + - name: Install the latest version of uv + uses: astral-sh/setup-uv@v7 + with: + activate-environment: 'true' + python-version: '3.12' + - name: Setup headless display + uses: pyvista/setup-headless-display-action@7d84ae825e6d9297a8e99bdbbae20d1b919a0b19 # v4.2 with: - python-version: 3.x - - uses: tlambert03/setup-qt-libs@v1 - - name: Install uv - run: pip install uv + qt: true + wm: herbstluftwm - name: Compile PyInstaller requirements run: | uv pip compile --prerelease allow --python-version 3.12 --upgrade -o requirements.txt pyproject.toml requirements/pre_test_problematic_version.txt --extra pyinstaller - name: Install dependencies run: | - uv venv --python 3.12 uv pip install -r requirements.txt uv pip install . - name: upload requirements @@ -147,7 +146,6 @@ jobs: path: requirements.txt - name: Run PyInstaller run: | - source .venv/bin/activate python build_utils/create_and_pack_executable.py - name: Upload bundle uses: actions/upload-artifact@v7 @@ -155,10 +153,8 @@ jobs: name: bundle path: dist2/ - name: Test bundle - uses: aganders3/headless-gui@v2 timeout-minutes: 60 - with: - run: dist/PartSeg/PartSeg _test + run: dist/PartSeg/PartSeg _test # If something goes wrong, we can open an issue in the repo - name: Report Failures