From 5bec7d1bb9d3a2e0eb2f689cd7dd78e92bf81966 Mon Sep 17 00:00:00 2001 From: "pre-commit-ci[bot]" <66853113+pre-commit-ci[bot]@users.noreply.github.com> Date: Thu, 26 Jun 2025 18:49:25 +0545 Subject: [PATCH] [pre-commit.ci] pre-commit autoupdate (#10786) Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com> --- .pre-commit-config.yaml | 2 +- dvc/parsing/context.py | 2 +- dvc/repo/checkout.py | 5 ++++- dvc/repo/experiments/queue/base.py | 2 +- dvc/repo/plots/__init__.py | 2 +- pyproject.toml | 2 +- tests/utils/__init__.py | 2 +- 7 files changed, 10 insertions(+), 7 deletions(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 5a4e7985a..672764347 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -22,7 +22,7 @@ repos: - id: sort-simple-yaml - id: trailing-whitespace - repo: https://github.com/astral-sh/ruff-pre-commit - rev: 'v0.11.13' + rev: 'v0.12.0' hooks: - id: ruff-check args: [--fix, --exit-non-zero-on-fix] diff --git a/dvc/parsing/context.py b/dvc/parsing/context.py index c13bb74cf..0a5d09621 100644 --- a/dvc/parsing/context.py +++ b/dvc/parsing/context.py @@ -155,7 +155,7 @@ class Value(Node): PRIMITIVES = (int, float, str, bytes, bool) -class Container(Node, ABC): +class Container(Node, ABC): # noqa: PLW1641 meta: Meta data: Union[list, dict] _key_transform = staticmethod(identity) diff --git a/dvc/repo/checkout.py b/dvc/repo/checkout.py index 176749a4a..06cff4e38 100644 --- a/dvc/repo/checkout.py +++ b/dvc/repo/checkout.py @@ -149,7 +149,10 @@ def checkout( # noqa: C901 def checkout_onerror(src_path, dest_path, _exc): logger.debug( - "failed to create '%s' from '%s'", dest_path, src_path, exc_info=True + "failed to create '%s' from '%s'", + dest_path, + src_path, + exc_info=True, # noqa: LOG014 ) for out_path in out_paths: diff --git a/dvc/repo/experiments/queue/base.py b/dvc/repo/experiments/queue/base.py index 79a7d8e70..c74c801d5 100644 --- a/dvc/repo/experiments/queue/base.py +++ b/dvc/repo/experiments/queue/base.py @@ -38,7 +38,7 @@ logger = logger.getChild(__name__) @dataclass(frozen=True) -class QueueEntry: +class QueueEntry: # noqa: PLW1641 dvc_root: str scm_root: str stash_ref: str diff --git a/dvc/repo/plots/__init__.py b/dvc/repo/plots/__init__.py index 9412abbe3..30813e9e4 100644 --- a/dvc/repo/plots/__init__.py +++ b/dvc/repo/plots/__init__.py @@ -32,7 +32,7 @@ logger = logger.getChild(__name__) def onerror_collect(result: dict, exception: Exception, *args, **kwargs): - logger.debug("", exc_info=True) + logger.debug("", exc_info=True) # noqa: LOG014 result["error"] = exception diff --git a/pyproject.toml b/pyproject.toml index 8a7a52f09..d88ac7517 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -267,7 +267,7 @@ show-fixes = true [tool.ruff.lint] ignore = [ "N818", "S101", "A005", "PT007", "RET502", "RET503", "SIM105", "SIM108", "SIM117", - "TRY003", "TRY300", "PERF203", "PLR2004", "PLW2901", "LOG007", + "TRY003", "TRY300", "PERF203", "PLC0415", "PLR2004", "PLW2901", "LOG007", ] select = [ "F", "E", "W", "C90", "I", "N", "UP", "YTT", "ASYNC", "S", "BLE", "B", "A", "C4", "DTZ", "T10", diff --git a/tests/utils/__init__.py b/tests/utils/__init__.py index 762828fbf..f6a3db733 100644 --- a/tests/utils/__init__.py +++ b/tests/utils/__init__.py @@ -59,7 +59,7 @@ def console_width(console, width): console._width = con_width -class ANY: +class ANY: # noqa: PLW1641 def __init__(self, expected_type): self.expected_type = expected_type