Fix release workflow by update macos runner (#408) #1332
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: CI | |
| on: | |
| push: | |
| branches: [main] | |
| pull_request: {} | |
| workflow_dispatch: | |
| schedule: | |
| - cron: "0 0 * * 0" # run once a week | |
| concurrency: | |
| group: ${{ github.workflow }}-${{ github.ref }} | |
| cancel-in-progress: true | |
| jobs: | |
| check-manifest: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v6 | |
| - run: pipx run check-manifest | |
| test: | |
| name: Test ${{ matrix.qt }} ${{ matrix.os }} py${{ matrix.python-version }} mypyc-${{ matrix.compile }} | |
| runs-on: ${{ matrix.os }} | |
| env: | |
| HATCH_BUILD_HOOKS_ENABLE: ${{ matrix.compile }} | |
| UV_NO_SYNC: "1" | |
| strategy: | |
| fail-fast: false | |
| matrix: | |
| python-version: ["3.10", "3.12", "3.14"] | |
| os: [ubuntu-latest, macos-latest, windows-latest] | |
| compile: ["1", "0"] | |
| qt: [""] | |
| include: | |
| - os: ubuntu-latest | |
| python-version: "3.11" | |
| compile: "1" | |
| - os: ubuntu-latest | |
| python-version: "3.13" | |
| compile: "1" | |
| # qt stuff | |
| - os: macos-latest | |
| python-version: "3.11" | |
| qt: "PyQt5" | |
| compile: "0" | |
| - os: windows-latest | |
| python-version: "3.12" | |
| qt: "PySide6" | |
| compile: "1" | |
| - os: ubuntu-latest | |
| python-version: "3.14" | |
| qt: "PyQt6" | |
| compile: "1" | |
| steps: | |
| - uses: actions/checkout@v6 | |
| - uses: astral-sh/setup-uv@v7 | |
| with: | |
| enable-cache: true | |
| python-version: ${{ matrix.python-version }} | |
| cache-dependency-glob: "**/pyproject.toml" | |
| - name: Install the project | |
| run: | | |
| uv sync --no-dev --group test | |
| uv run python -c "import psygnal; print('compiled:', psygnal._compiled)" | |
| - if: matrix.qt != '' | |
| uses: pyvista/setup-headless-display-action@v4 | |
| with: | |
| qt: true | |
| - if: matrix.qt != '' | |
| run: | | |
| uv sync --no-dev --group testqt | |
| uv pip install ${{ matrix.qt }} | |
| - name: Test | |
| shell: bash | |
| run: uv run coverage run -p -m pytest -v | |
| - name: Upload coverage | |
| uses: actions/upload-artifact@v6 | |
| with: | |
| name: covreport-${{ matrix.os }}-py${{ matrix.python-version }}-mypyc${{ matrix.compile }}-${{ matrix.qt }} | |
| path: ./.coverage* | |
| include-hidden-files: true | |
| upload_coverage: | |
| if: always() | |
| needs: [test] | |
| uses: pyapp-kit/workflows/.github/workflows/upload-coverage.yml@v2 | |
| secrets: inherit | |
| test-magicgui: | |
| uses: pyapp-kit/workflows/.github/workflows/test-dependents.yml@main | |
| with: | |
| dependency-repo: pyapp-kit/magicgui | |
| dependency-group: "pyside2" | |
| qt: "pyside2" | |
| python-version: "3.10" | |
| typing: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v6 | |
| - uses: astral-sh/setup-uv@v7 | |
| with: | |
| enable-cache: true | |
| cache-dependency-glob: "**/pyproject.toml" | |
| - name: test | |
| run: uv run --no-dev --group test-typing pytest typesafety --mypy-only-local-stub --color=yes | |
| benchmarks: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v6 | |
| - uses: actions/setup-python@v6 | |
| with: | |
| python-version: "3.13" | |
| - name: Install the project | |
| run: | | |
| python -m pip install -U pip | |
| python -m pip install . --group test-codspeed | |
| python -c "import psygnal; print('compiled:', psygnal._compiled)" | |
| env: | |
| HATCH_BUILD_HOOKS_ENABLE: "1" | |
| - name: Run benchmarks | |
| uses: CodSpeedHQ/action@v4 | |
| with: | |
| run: pytest --codspeed -v | |
| mode: instrumentation |