Skip to content

Commit d0307f6

Browse files
authored
Merge pull request #2030 from praw-dev/update/pre-commit-hooks
Update pre-commit hooks
2 parents 83c2a8d + 58cf677 commit d0307f6

File tree

2 files changed

+10
-16
lines changed

2 files changed

+10
-16
lines changed

.pre-commit-config.yaml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ repos:
1818
types: [ python ]
1919

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

4444
- repo: https://github.com/astral-sh/ruff-pre-commit
45-
rev: v0.6.2
45+
rev: v0.6.9
4646
hooks:
4747
- id: ruff
4848
args: [ --exit-non-zero-on-fix, --fix ]
@@ -51,9 +51,9 @@ repos:
5151
- repo: https://github.com/psf/black
5252
hooks:
5353
- id: black
54-
rev: 24.8.0
54+
rev: 24.10.0
5555

5656
- repo: https://github.com/LilSpazJoekp/docstrfmt
5757
hooks:
5858
- id: docstrfmt
59-
rev: v1.8.0
59+
rev: v1.9.0

docs/package_info/contributing.rst

Lines changed: 6 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -133,8 +133,7 @@ Linting_:
133133
arg1,
134134
arg2,
135135
optional_arg1=None,
136-
):
137-
...
136+
): ...
138137
139138
There is some exceptions to this:
140139

@@ -144,8 +143,7 @@ Linting_:
144143
.. code-block:: python
145144
146145
class ExampleClass:
147-
def pair(self, left, right):
148-
...
146+
def pair(self, left, right): ...
149147
150148
- If there is one or two mandatory arguments and some optional arguments, then the
151149
mandatory arguments may be positional (as long as it adheres to the previous point),
@@ -171,8 +169,7 @@ Linting_:
171169
send_replies=True,
172170
spoiler=False,
173171
url=None,
174-
):
175-
...
172+
): ...
176173
177174
Testing
178175
-------
@@ -250,18 +247,15 @@ Examples:
250247
@pytest.mark.recorder_kwargs(allow_playback_repeats=True)
251248
class TestClass:
252249
@pytest.mark.recorder_kwargs(match_requests_on=["uri", "method", "body"])
253-
def test_example(self):
254-
...
250+
def test_example(self): ...
255251
256252
@pytest.mark.cassette_name("TestClass.test_example")
257253
@pytest.mark.recorder_kwargs(match_requests_on=["uri", "method", "body"])
258-
def test_example__different_assertion(self):
259-
...
254+
def test_example__different_assertion(self): ...
260255
261256
@pytest.mark.add_placeholder(generated_data_a=generate_data_a())
262257
@pytest.mark.add_placeholder(generated_data_b=generate_data_b())
263-
def test_example__with_generated_placeholders(self):
264-
...
258+
def test_example__with_generated_placeholders(self): ...
265259
266260
Documentation
267261
-------------

0 commit comments

Comments
 (0)