diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index c2d7be7..8ef135f 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -1,6 +1,6 @@ repos: - repo: https://github.com/pre-commit/pre-commit-hooks - rev: v4.6.0 + rev: v6.0.0 hooks: - id: check-added-large-files args: ["--maxkb=1000"] @@ -24,26 +24,26 @@ repos: - id: mixed-line-ending - repo: https://github.com/astral-sh/ruff-pre-commit - rev: v0.5.7 + rev: v0.15.12 hooks: - id: ruff args: [--fix, --exit-non-zero-on-fix] types_or: [python, pyi, jupyter] - - repo: https://github.com/psf/black - rev: 24.8.0 + - repo: https://github.com/psf/black-pre-commit-mirror + rev: 26.3.1 hooks: - id: black language_version: python3 - repo: https://github.com/asottile/blacken-docs - rev: 1.18.0 + rev: 1.20.0 hooks: - id: blacken-docs additional_dependencies: [black==24.4.2] - repo: https://github.com/pycqa/flake8 - rev: 7.1.1 + rev: 7.3.0 hooks: - id: flake8 exclude: docs/source/conf.py, __pycache__ @@ -62,7 +62,7 @@ repos: ] - repo: https://github.com/pre-commit/mirrors-mypy - rev: v1.11.1 + rev: v1.20.2 hooks: - id: mypy files: predictably-core/ @@ -89,7 +89,7 @@ repos: # additional_dependencies: ["bandit[toml]"] - repo: https://github.com/codespell-project/codespell - rev: v2.3.0 + rev: v2.4.2 hooks: - id: codespell types_or: [python, rst, markdown] @@ -97,19 +97,19 @@ repos: - tomli - repo: https://github.com/PyCQA/doc8 - rev: v1.1.1 + rev: v2.0.0 hooks: - id: doc8 args: ["--max-line-length=88", "--config=pyproject.toml", "docs"] additional_dependencies: ["tomli"] - repo: https://github.com/sphinx-contrib/sphinx-lint - rev: v0.9.1 + rev: v1.0.2 hooks: - id: sphinx-lint - repo: https://github.com/numpy/numpydoc - rev: v1.8.0 + rev: v1.10.0 hooks: - id: numpydoc-validation exclude: | diff --git a/predictably_core/core/_pprint/_object_html_repr.py b/predictably_core/core/_pprint/_object_html_repr.py index bbef64e..a9f47ad 100644 --- a/predictably_core/core/_pprint/_object_html_repr.py +++ b/predictably_core/core/_pprint/_object_html_repr.py @@ -342,11 +342,7 @@ def _write_base_object_html( #$id div.sk-text-repr-fallback { display: none; } -""".replace( - " ", "" -).replace( - "\n", "" -) +""".replace(" ", "").replace("\n", "") def _object_html_repr(base_object: prc._base.BaseOBject) -> str: diff --git a/predictably_core/utils/_utils.py b/predictably_core/utils/_utils.py index f022796..26ed58c 100644 --- a/predictably_core/utils/_utils.py +++ b/predictably_core/utils/_utils.py @@ -44,7 +44,7 @@ def remove_type_text(input_: str | type) -> str: if not isinstance(input_, str): input_ = str(input_) - m = re.match("^$", input_) + m = re.match(r"^$", input_) if m: return m[1]