From cb3eaa093dbd830d55dd6ab538c7bc27d9ed4dd7 Mon Sep 17 00:00:00 2001 From: Henry Schreiner Date: Thu, 12 May 2022 12:43:35 -0400 Subject: [PATCH] chore: minor style check additions --- .pre-commit-config.yaml | 16 ++++++++++++++++ tests/test_env.py | 4 ++-- tox.ini | 1 + 3 files changed, 19 insertions(+), 2 deletions(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 0bc08df8..16ae1536 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -26,6 +26,11 @@ repos: rev: 22.3.0 hooks: - id: black +- repo: https://github.com/asottile/blacken-docs + rev: v1.12.1 + hooks: + - id: blacken-docs + additional_dependencies: [black==22.3.0] - repo: https://github.com/PyCQA/isort rev: 5.10.1 hooks: @@ -45,3 +50,14 @@ repos: hooks: - id: codespell args: ["-L", "sur"] +- repo: https://github.com/pre-commit/pygrep-hooks + rev: "v1.9.0" + hooks: + - id: python-check-blanket-noqa + - id: python-check-blanket-type-ignore + - id: python-no-log-warn + - id: python-no-eval + - id: python-use-type-annotations + - id: rst-backticks + - id: rst-directive-colons + - id: rst-inline-touching-normal diff --git a/tests/test_env.py b/tests/test_env.py index 37446ca7..a1ee0cbe 100644 --- a/tests/test_env.py +++ b/tests/test_env.py @@ -82,7 +82,7 @@ def test_isolated_env_abstract(): def test_isolated_env_has_executable_still_abstract(): - class Env(build.env.IsolatedEnv): # noqa + class Env(build.env.IsolatedEnv): @property def executable(self): raise NotImplementedError @@ -92,7 +92,7 @@ def executable(self): def test_isolated_env_has_install_still_abstract(): - class Env(build.env.IsolatedEnv): # noqa + class Env(build.env.IsolatedEnv): def install(self, requirements): raise NotImplementedError diff --git a/tox.ini b/tox.ini index f3d6d57a..1d3e9eef 100644 --- a/tox.ini +++ b/tox.ini @@ -107,3 +107,4 @@ depends = {py311, py310, py39, py38, py37, py36, pypy37, pypy38, pypy39} max-line-length = 127 max-complexity = 10 extend-ignore = E203 +extend-select = B9