diff --git a/.flake8 b/.flake8 deleted file mode 100644 index 5a1bf64..0000000 --- a/.flake8 +++ /dev/null @@ -1,4 +0,0 @@ -[flake8] -select = DAR -docstring-convention = google -max-line-length = 88 diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 48338a4..0c5de07 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -5,6 +5,8 @@ ci: autofix_prs: true autoupdate_schedule: monthly autoupdate_commit_msg: 'chore(deps): pre-commit autoupdate' + skip: + - check-dependabot default_language_version: python: python3.11 @@ -19,7 +21,7 @@ repos: - id: check-added-large-files - repo: https://github.com/python-jsonschema/check-jsonschema - rev: 0.27.3 + rev: 0.27.4 hooks: - id: check-dependabot - id: check-github-workflows @@ -27,18 +29,14 @@ repos: - repo: https://github.com/astral-sh/ruff-pre-commit # Ruff version. - rev: v0.1.9 + rev: v0.2.0 hooks: - id: ruff args: [--fix, --exit-non-zero-on-fix] - -- repo: https://github.com/psf/black - rev: 23.12.1 - hooks: - - id: black + - id: ruff-format - repo: https://github.com/tox-dev/pyproject-fmt - rev: "1.5.3" + rev: "1.7.0" hooks: - id: pyproject-fmt @@ -49,8 +47,3 @@ repos: additional_dependencies: - typing-extensions - sqlalchemy[mypy] - -- repo: https://github.com/pycqa/flake8 - rev: 6.1.0 - hooks: - - id: flake8 diff --git a/pyproject.toml b/pyproject.toml index 6c222c5..8691c37 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -28,6 +28,10 @@ python_version = "3.9" warn_unused_configs = true [tool.ruff] +line-length = 88 +target-version = "py38" + +[tool.ruff.lint] select = [ "F", "W", @@ -86,28 +90,26 @@ ignore = [ unfixable = [ "ERA", # commented-out-code ] -line-length = 88 -target-version = "py37" -[tool.ruff.flake8-import-conventions] +[tool.ruff.lint.flake8-import-conventions] banned-from = ["typing"] -[tool.ruff.flake8-import-conventions.extend-aliases] +[tool.ruff.lint.flake8-import-conventions.extend-aliases] "typing" = "t" -[tool.ruff.isort] +[tool.ruff.lint.isort] required-imports = ["from __future__ import annotations"] -[tool.ruff.per-file-ignores] +[tool.ruff.lint.per-file-ignores] "tests/*" = ["S101"] -[tool.ruff.pydocstyle] +[tool.ruff.lint.pydocstyle] convention = "google" [build-system] build-backend = "poetry.core.masonry.api" requires = [ - "poetry-core==1.6.*", + "poetry-core==1.9", ] [tool.poetry.scripts] diff --git a/tests/conftest.py b/tests/conftest.py index 4133230..3a8eaea 100644 --- a/tests/conftest.py +++ b/tests/conftest.py @@ -1,4 +1,5 @@ """Test Configuration.""" + from __future__ import annotations pytest_plugins = ("singer_sdk.testing.pytest_plugin",) diff --git a/tests/test_core.py b/tests/test_core.py index 6c6fbf1..e7c9a8b 100644 --- a/tests/test_core.py +++ b/tests/test_core.py @@ -1,4 +1,5 @@ """Tests standard tap features using the built-in SDK tests library.""" + from __future__ import annotations import json