Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
22 changes: 11 additions & 11 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ repos:
- id: no_optional

- repo: https://github.com/astral-sh/ruff-pre-commit.git
rev: v0.15.9
rev: v0.16.10
hooks:
- id: ruff-check
args:
Expand All @@ -48,7 +48,7 @@ repos:
- --show-fixes

- repo: https://github.com/astral-sh/ruff-pre-commit.git
rev: v0.15.9
rev: v0.16.10
hooks:
- id: ruff-format
alias: ruff-format-first-pass
Expand All @@ -60,7 +60,7 @@ repos:
- id: add-trailing-comma

- repo: https://github.com/astral-sh/ruff-pre-commit.git
rev: v0.15.9
rev: v0.16.10
hooks:
- id: ruff-format
alias: ruff-format-second-pass
Expand All @@ -72,7 +72,7 @@ repos:
- id: remove-tabs

- repo: https://github.com/python-jsonschema/check-jsonschema.git
rev: 0.37.1
rev: 0.38.2
hooks:
- id: check-github-workflows
files: ^\.github/workflows/[^/]+$
Expand Down Expand Up @@ -131,7 +131,7 @@ repos:
- id: debug-statements

- repo: https://github.com/codespell-project/codespell.git
rev: v2.4.2
rev: v2.4.3
hooks:
- id: codespell

Expand All @@ -151,17 +151,17 @@ repos:
- id: bashate

- repo: https://github.com/shellcheck-py/shellcheck-py.git
rev: v0.11.0.1
rev: v0.11.0.1-1
hooks:
- id: shellcheck

- repo: https://github.com/Lucas-C/pre-commit-hooks-lxml.git
rev: v1.1.0
rev: v1.1.1
hooks:
- id: forbid-html-img-without-alt-text

- repo: https://github.com/PyCQA/flake8.git
rev: 7.3.0
rev: 7.4.1
hooks:
- id: flake8
additional_dependencies:
Expand All @@ -179,7 +179,7 @@ repos:
language_version: python3

- repo: https://github.com/pre-commit/mirrors-mypy.git
rev: v1.19.1
rev: v2.4.0
hooks:
- id: mypy
alias: mypy-py315
Expand Down Expand Up @@ -285,7 +285,7 @@ repos:
pass_filenames: false

- repo: https://github.com/PyCQA/pylint.git
rev: v3.3.9
rev: v4.1.2
hooks:
- id: pylint
additional_dependencies:
Expand All @@ -297,7 +297,7 @@ repos:
- tox [testing] >= 4.54.0

- repo: https://github.com/rhysd/actionlint.git
rev: v1.7.10
rev: v1.7.12
hooks:
- id: actionlint
additional_dependencies:
Expand Down
14 changes: 7 additions & 7 deletions .ruff.toml
Original file line number Diff line number Diff line change
Expand Up @@ -13,14 +13,14 @@ external = [
"WPS", # Do not remove noqa for wemake-python-style (WPS) checks
]
ignore = [
"CPY001", # Skip copyright notice requirement at top of files
"missing-copyright-notice", # Skip copyright notice requirement at top of files

# Refs:
# * https://github.com/astral-sh/ruff/issues/6606
# * https://github.com/astral-sh/ruff/pull/13286
"DOC201", # Ruff doesn't understand sphinx-native param lists
"DOC402", # Ruff doesn't understand sphinx-native param lists
"DOC501", # docstring-missing-exception # Ruff doesn't understand sphinx-native param lists
"docstring-missing-returns", # Ruff doesn't understand sphinx-native param lists
"docstring-missing-yields", # Ruff doesn't understand sphinx-native param lists
"docstring-missing-exception", # docstring-missing-exception # Ruff doesn't understand sphinx-native param lists
]
preview = true # Live dangerously
select = [
Expand Down Expand Up @@ -84,9 +84,9 @@ testing = [
# If other ignores are added for a specific file in the section following this,
# these will need to be added to that line as well.

"PLC2701", # Allow importing internal files needed for testing
"PLR0913", # Allow parametrized + fixture test signatures with many args
"S101", # Allow use of `assert` in test files
"import-private-name", # Allow importing internal files needed for testing
"too-many-arguments", # Allow parametrized + fixture test signatures with many args
"assert", # Allow use of `assert` in test files
]

[lint.pydocstyle]
Expand Down
1 change: 1 addition & 0 deletions pytest.ini
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
[pytest]
usefixtures = check_os_environ_stable _isolate_user_environment
addopts =
# `pytest-xdist`:
--numprocesses=auto
Expand Down
3 changes: 0 additions & 3 deletions src/tox_plugins/pre_commit/_plugin.py
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,6 @@
if _t.TYPE_CHECKING:
from collections import abc as _c # noqa: WPS347

from tox.config.sets import ConfigSet
from tox.session.state import State


Expand All @@ -38,12 +37,10 @@ def tox_extend_envs() -> _c.Iterable[str]:

@impl
def tox_add_core_config(
core_conf: ConfigSet, # noqa: ARG001 # pylint: disable=unused-argument
state: State,
) -> None:
"""Inject default configuration for the pre-commit environment.

:param core_conf: The core tox configuration set (unused).
:param state: The tox session state to inject environments into.
"""
pos_args = state.conf.pos_args(to_path=None)
Expand Down
2 changes: 1 addition & 1 deletion tests/conftest.py
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
pytest_plugins = ('tox.pytest',)


@pytest.fixture(autouse=True)
@pytest.fixture
def _isolate_user_environment(monkeypatch: pytest.MonkeyPatch) -> None:
"""Isolate the tests from the user's tox configuration.

Expand Down
Loading