Tianshou/.github/workflows/lint_and_docs.yml
n+e b284ace102
type check in unit test (#200)
Fix #195: Add mypy test in .github/workflows/docs_and_lint.yml.

Also remove the out-of-the-date api
2020-09-13 19:31:50 +08:00

33 lines
764 B
YAML

name: PEP8, Types and Docs Check
on: [push, pull_request]
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: Set up Python 3.8
uses: actions/setup-python@v2
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: Type check
run: |
mypy
- name: Documentation test
run: |
pydocstyle tianshou
doc8 docs --max-line-length 1000
cd docs
make html SPHINXOPTS="-W"
cd ..