Improved typing and reduced duplication #2172
Workflow file for this run
This file contains 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: PEP8, Types and Docs Check | |
on: [push, pull_request] | |
jobs: | |
check: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Cancel previous run | |
uses: styfle/[email protected] | |
with: | |
access_token: ${{ github.token }} | |
- uses: actions/checkout@v3 | |
- name: Set up Python 3.8 | |
uses: actions/setup-python@v4 | |
with: | |
python-version: 3.8 | |
- name: Upgrade pip | |
run: | | |
python -m pip install --upgrade pip setuptools wheel | |
- name: Install dependencies | |
run: | | |
python -m pip install ".[dev]" --upgrade | |
- name: Lint with flake8 | |
run: | | |
flake8 . --count --show-source --statistics | |
- name: Code formatter | |
run: | | |
yapf -r -d . | |
isort --check . | |
- name: Type check | |
run: | | |
mypy | |
- name: Documentation test | |
run: | | |
make check-docstyle | |
make spelling |