diff --git a/.github/workflows/pre-commit.yml b/.github/workflows/pre-commit.yml index 210ff5bb..5749da1f 100644 --- a/.github/workflows/pre-commit.yml +++ b/.github/workflows/pre-commit.yml @@ -48,7 +48,7 @@ jobs: pyproject.toml uv.lock - name: Install Dependencies - run: uv sync --locked + run: uv sync --locked --extra standard - name: Run prek - pre-commit id: precommit run: uvx prek run --from-ref origin/${GITHUB_BASE_REF} --to-ref HEAD --show-diff-on-failure diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 8717a7c6..c5e3bdb6 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -26,3 +26,10 @@ repos: require_serial: true language: unsupported types: [python] + + - id: local-mypy + name: mypy check + entry: uv run mypy src tests + require_serial: true + language: unsupported + pass_filenames: false diff --git a/tests/test_utils_cli.py b/tests/test_utils_cli.py index 422e515f..db8a9e19 100644 --- a/tests/test_utils_cli.py +++ b/tests/test_utils_cli.py @@ -1,4 +1,5 @@ import logging +from logging.config import dictConfig from pytest import LogCaptureFixture @@ -63,7 +64,7 @@ def test_log_config_does_not_disable_existing_loggers( logger1.setLevel(logging.INFO) logger1.info("Message before configuration") - logging.config.dictConfig(get_uvicorn_log_config()) + dictConfig(get_uvicorn_log_config()) logger2 = logging.getLogger(__name__)