Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update pre-commit hooks #2030

Merged
merged 1 commit into from
Oct 20, 2024
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
8 changes: 4 additions & 4 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ repos:
types: [ python ]

- repo: https://github.com/pre-commit/pre-commit-hooks
rev: v4.6.0
rev: v5.0.0
hooks:
- id: check-added-large-files
- id: check-executables-have-shebangs
Expand All @@ -42,7 +42,7 @@ repos:
files: ^(.*\.toml)$

- repo: https://github.com/astral-sh/ruff-pre-commit
rev: v0.6.2
rev: v0.6.9
hooks:
- id: ruff
args: [ --exit-non-zero-on-fix, --fix ]
Expand All @@ -51,9 +51,9 @@ repos:
- repo: https://github.com/psf/black
hooks:
- id: black
rev: 24.8.0
rev: 24.10.0

- repo: https://github.com/LilSpazJoekp/docstrfmt
hooks:
- id: docstrfmt
rev: v1.8.0
rev: v1.9.0
18 changes: 6 additions & 12 deletions docs/package_info/contributing.rst
Original file line number Diff line number Diff line change
Expand Up @@ -133,8 +133,7 @@ Linting_:
arg1,
arg2,
optional_arg1=None,
):
...
): ...

There is some exceptions to this:

Expand All @@ -144,8 +143,7 @@ Linting_:
.. code-block:: python

class ExampleClass:
def pair(self, left, right):
...
def pair(self, left, right): ...

- If there is one or two mandatory arguments and some optional arguments, then the
mandatory arguments may be positional (as long as it adheres to the previous point),
Expand All @@ -171,8 +169,7 @@ Linting_:
send_replies=True,
spoiler=False,
url=None,
):
...
): ...

Testing
-------
Expand Down Expand Up @@ -250,18 +247,15 @@ Examples:
@pytest.mark.recorder_kwargs(allow_playback_repeats=True)
class TestClass:
@pytest.mark.recorder_kwargs(match_requests_on=["uri", "method", "body"])
def test_example(self):
...
def test_example(self): ...

@pytest.mark.cassette_name("TestClass.test_example")
@pytest.mark.recorder_kwargs(match_requests_on=["uri", "method", "body"])
def test_example__different_assertion(self):
...
def test_example__different_assertion(self): ...

@pytest.mark.add_placeholder(generated_data_a=generate_data_a())
@pytest.mark.add_placeholder(generated_data_b=generate_data_b())
def test_example__with_generated_placeholders(self):
...
def test_example__with_generated_placeholders(self): ...

Documentation
-------------
Expand Down
Loading