diff --git a/.github/workflows/docs.yaml b/.github/workflows/docs.yaml index 6009ffb7d..0cb5e0cfc 100644 --- a/.github/workflows/docs.yaml +++ b/.github/workflows/docs.yaml @@ -17,6 +17,20 @@ on: - 'requirements.txt' - '.github/workflows/docs.yaml' jobs: + pydocstyle: + name: pydocstyle + runs-on: ubuntu-latest + steps: + - name: Clone repo + uses: actions/checkout@v2 + - name: Set up python + uses: actions/setup-python@v2 + with: + python-version: 3.9 + - name: Install pydocstyle + run: pip install 'pydocstyle[toml]>=6.1' + - name: Run pydocstyle checks + run: pydocstyle sphinx: name: sphinx runs-on: ubuntu-latest diff --git a/pyproject.toml b/pyproject.toml index d53a09402..e63e0924b 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -59,6 +59,11 @@ warn_return_any = true no_implicit_reexport = true strict_equality = true +[tool.pydocstyle] +convention = "google" +match = '(?!setup).*\.py' +match_dir = '(datasets|samplers|torchgeo|trainers|transforms)' + [tool.pytest.ini_options] norecursedirs = [ "*.egg*",