From 3298268bf4086428a97240f3a5a0baaa527da3dc Mon Sep 17 00:00:00 2001 From: "pre-commit-ci[bot]" <66853113+pre-commit-ci[bot]@users.noreply.github.com> Date: Mon, 7 Oct 2024 19:19:23 +0000 Subject: [PATCH] [pre-commit.ci] pre-commit suggestions (#50) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * [pre-commit.ci] pre-commit suggestions updates: - [github.com/pre-commit/pre-commit-hooks: v4.6.0 → v5.0.0](https://github.com/pre-commit/pre-commit-hooks/compare/v4.6.0...v5.0.0) - [github.com/pre-commit/mirrors-prettier: v3.1.0 → v4.0.0-alpha.8](https://github.com/pre-commit/mirrors-prettier/compare/v3.1.0...v4.0.0-alpha.8) - [github.com/astral-sh/ruff-pre-commit: v0.5.0 → v0.6.9](https://github.com/astral-sh/ruff-pre-commit/compare/v0.5.0...v0.6.9) - [github.com/tox-dev/pyproject-fmt: 2.1.3 → 2.2.4](https://github.com/tox-dev/pyproject-fmt/compare/2.1.3...2.2.4) - [github.com/abravalheri/validate-pyproject: v0.18 → v0.20.2](https://github.com/abravalheri/validate-pyproject/compare/v0.18...v0.20.2) * [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci * drop docformatter --------- Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com> Co-authored-by: Jirka Borovec <6035284+Borda@users.noreply.github.com> --- .pre-commit-config.yaml | 15 ++++----------- tests/collection_deprecate.py | 2 +- tests/test_classes.py | 2 +- tests/test_functions.py | 2 +- tests/test_utils.py | 1 + 5 files changed, 8 insertions(+), 14 deletions(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index ae5526f..f7e643f 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -9,7 +9,7 @@ ci: repos: - repo: https://github.com/pre-commit/pre-commit-hooks - rev: v4.6.0 + rev: v5.0.0 hooks: - id: end-of-file-fixer - id: trailing-whitespace @@ -37,13 +37,6 @@ repos: additional_dependencies: [tomli] #args: ["--write-changes"] # uncomment if you want to get automatic fixing - - repo: https://github.com/PyCQA/docformatter - rev: v1.7.5 - hooks: - - id: docformatter - additional_dependencies: [tomli] - args: [--in-place] - #- repo: https://github.com/pre-commit/mirrors-mypy # rev: v0.991 # hooks: @@ -60,7 +53,7 @@ repos: - mdformat_frontmatter - repo: https://github.com/astral-sh/ruff-pre-commit - rev: v0.5.0 + rev: v0.6.9 hooks: # try to fix what is possible - id: ruff @@ -71,11 +64,11 @@ repos: - id: ruff - repo: https://github.com/tox-dev/pyproject-fmt - rev: 2.1.3 + rev: 2.2.4 hooks: - id: pyproject-fmt additional_dependencies: [tox] - repo: https://github.com/abravalheri/validate-pyproject - rev: v0.18 + rev: v0.20.2 hooks: - id: validate-pyproject diff --git a/tests/collection_deprecate.py b/tests/collection_deprecate.py index c85e4ba..4577c47 100644 --- a/tests/collection_deprecate.py +++ b/tests/collection_deprecate.py @@ -1,8 +1,8 @@ """Copyright (C) 2020-2023 Jiri Borovec <...>.""" -from deprecate import deprecated, void from sklearn.metrics import accuracy_score +from deprecate import deprecated, void from tests.collection_targets import base_pow_args, base_sum_kwargs _SHORT_MSG_FUNC = "`%(source_name)s` >> `%(target_name)s` in v%(deprecated_in)s rm v%(remove_in)s." diff --git a/tests/test_classes.py b/tests/test_classes.py index 60e192c..9989ee6 100644 --- a/tests/test_classes.py +++ b/tests/test_classes.py @@ -5,9 +5,9 @@ from warnings import warn import pytest + from deprecate.deprecation import deprecated from deprecate.utils import no_warning_call - from tests.collection_targets import NewCls _deprecation_warning = partial(warn, category=DeprecationWarning) diff --git a/tests/test_functions.py b/tests/test_functions.py index 5663dd7..cdb0591 100644 --- a/tests/test_functions.py +++ b/tests/test_functions.py @@ -1,8 +1,8 @@ """Copyright (C) 2020-2023 Jiri Borovec <...>.""" import pytest -from deprecate.utils import no_warning_call +from deprecate.utils import no_warning_call from tests.collection_deprecate import ( depr_accuracy_extra, depr_accuracy_map, diff --git a/tests/test_utils.py b/tests/test_utils.py index 57c7de5..a14fec0 100644 --- a/tests/test_utils.py +++ b/tests/test_utils.py @@ -3,6 +3,7 @@ from warnings import warn import pytest + from deprecate.utils import no_warning_call