Skip to content

Commit

Permalink
build: add type-checkers to CI (#18)
Browse files Browse the repository at this point in the history
* build: add type-checkers to CI

* fix: add slotscheck to lint deps

* fix: slotscheck command

* fix: type errors

* fix: isort first party names
  • Loading branch information
peterschutt authored May 16, 2024
1 parent 57b83a9 commit e7e1064
Show file tree
Hide file tree
Showing 6 changed files with 298 additions and 51 deletions.
69 changes: 69 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,75 @@ jobs:
- name: Execute Pre-Commit
run: pre-commit run --show-diff-on-failure --color=always --all-files

mypy:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4

- uses: actions/setup-python@v5
with:
python-version: "3.9"

- uses: pdm-project/setup-pdm@v4
name: Set up PDM
with:
python-version: "3.9"
cache: true
cache-dependency-path: |
./pdm.lock
- name: Install dependencies
run: pdm install -G:all

- name: Run mypy
run: pdm run mypy

pyright:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4

- uses: actions/setup-python@v5
with:
python-version: "3.9"

- uses: pdm-project/setup-pdm@v4
name: Set up PDM
with:
python-version: "3.9"
cache: true
cache-dependency-path: |
./pdm.lock
- name: Install dependencies
run: pdm install -G:all

- name: Run pyright
run: pdm run pyright

slotscheck:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4

- uses: actions/setup-python@v5
with:
python-version: "3.9"

- uses: pdm-project/setup-pdm@v4
name: Set up PDM
with:
python-version: "3.9"
cache: true
cache-dependency-path: |
./pdm.lock
- name: Install dependencies
run: pdm install -G:all

- name: Run slotscheck
run: pdm run slotscheck type_lens

test:
runs-on: ubuntu-latest
strategy:
Expand Down
Loading

0 comments on commit e7e1064

Please sign in to comment.