⬆️ Bump ruff from 0.14.1 to 0.14.2 in the actions group (#957) #2129
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 | |
| permissions: read-all | |
| on: | |
| pull_request: | |
| push: | |
| branches: [master] | |
| workflow_dispatch: | |
| concurrency: | |
| group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }} | |
| cancel-in-progress: true | |
| env: | |
| UV_LOCKED: 1 | |
| jobs: | |
| lint: | |
| runs-on: ubuntu-latest | |
| timeout-minutes: 2 | |
| steps: | |
| - uses: actions/[email protected] | |
| - uses: scientific-python/[email protected] | |
| with: | |
| plugins: sp-repo-review | |
| - name: dprint | |
| uses: dprint/[email protected] | |
| - name: typos | |
| uses: crate-ci/[email protected] | |
| - uses: astral-sh/[email protected] | |
| with: | |
| python-version: "3.13" | |
| activate-environment: true | |
| - name: ruff check | |
| run: uv run ruff check --output-format=github | |
| - name: ruff format | |
| run: uv run ruff format --check | |
| # mypy_primer expects pyright to pass | |
| - name: pyright | |
| uses: jakebailey/[email protected] | |
| validate_stubs: | |
| runs-on: ubuntu-latest | |
| timeout-minutes: 5 | |
| steps: | |
| - uses: actions/[email protected] | |
| - name: setup uv | |
| uses: astral-sh/[email protected] | |
| with: | |
| python-version: "3.13" | |
| - name: check version literals | |
| run: uv run scripts/check_version_literals.py | |
| - name: check for unstubbed modules | |
| run: uv run scripts/unstubbed_modules.py | |
| # avoid stubdefaulter checking the tests as if they were stubs | |
| - name: exclude tests | |
| run: rm -rf tests | |
| - name: run stubdefaulter | |
| run: uv run stubdefaulter --check --exit-zero --packages . | |
| typecheck: | |
| runs-on: ubuntu-latest | |
| timeout-minutes: 5 | |
| strategy: | |
| fail-fast: false | |
| matrix: | |
| py: ["3.11"] | |
| np: ["1.25", "2.0", "2.1", "2.2", "2.3"] | |
| steps: | |
| - uses: actions/[email protected] | |
| # NOTE: mypy ignores `uv run --with=...` (and `--isolated` does not help), so we | |
| # manually (re)install the desired version directly in the environment. | |
| - name: setup uv | |
| uses: astral-sh/[email protected] | |
| with: | |
| activate-environment: true | |
| python-version: ${{ matrix.py }} | |
| - name: install dependencies | |
| run: uv pip install --exact --group type numpy==${{ matrix.np }}.* . | |
| - name: pyrefly check scipy-stubs | |
| run: pyrefly check scipy-stubs | |
| - name: basedpyright scipy-stubs | |
| run: basedpyright scipy-stubs | |
| - name: mypy scipy-stubs | |
| run: mypy --no-incremental --cache-dir=/dev/null scipy-stubs | |
| - name: stubtest scipy | |
| run: stubtest --ignore-disjoint-bases --allowlist=.mypyignore scipy | |
| typetest: | |
| runs-on: ubuntu-latest | |
| timeout-minutes: 5 | |
| strategy: | |
| fail-fast: false | |
| matrix: | |
| py: ["3.11", "3.12", "3.13", "3.14"] | |
| np: ["1.25", "2.0", "2.1", "2.2", "2.3"] | |
| exclude: | |
| - py: "3.12" | |
| np: "1.25" | |
| - py: "3.13" | |
| np: "1.25" | |
| - py: "3.13" | |
| np: "2.0" | |
| - py: "3.14" | |
| np: "1.25" | |
| - py: "3.14" | |
| np: "2.0" | |
| - py: "3.14" | |
| np: "2.1" | |
| - py: "3.14" | |
| np: "2.2" | |
| steps: | |
| - uses: actions/[email protected] | |
| - uses: astral-sh/[email protected] | |
| with: | |
| activate-environment: true | |
| python-version: ${{ matrix.py }} | |
| - name: install dependencies | |
| run: uv pip install --exact --group type numpy==${{ matrix.np }}.* . | |
| - name: pyrefly check tests | |
| run: pyrefly check tests | |
| - name: basedpyright tests | |
| run: basedpyright tests | |
| - name: mypy tests | |
| run: mypy --no-incremental --cache-dir=/dev/null tests |