Skip to content

Commit 6d4f7d7

Browse files
[pre-commit.ci] pre-commit autoupdate (#497)
* [pre-commit.ci] pre-commit autoupdate updates: - [github.com/python-jsonschema/check-jsonschema: 0.29.3 → 0.29.4](0.29.3...0.29.4) - [github.com/sirosen/slyp: 0.7.1 → 0.8.1](sirosen/slyp@0.7.1...0.8.1) - [github.com/asottile/pyupgrade: v3.17.0 → v3.18.0](asottile/pyupgrade@v3.17.0...v3.18.0) * [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci --------- Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
1 parent fdea0de commit 6d4f7d7

File tree

5 files changed

+11
-9
lines changed

5 files changed

+11
-9
lines changed

.pre-commit-config.yaml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
repos:
22
# dogfood
33
- repo: https://github.com/python-jsonschema/check-jsonschema
4-
rev: 0.29.3
4+
rev: 0.29.4
55
hooks:
66
- id: check-dependabot
77
- id: check-github-workflows
@@ -31,15 +31,15 @@ repos:
3131
- 'flake8-typing-as-t==0.0.3'
3232
- 'flake8-comprehensions==3.15.0'
3333
- repo: https://github.com/sirosen/slyp
34-
rev: 0.7.1
34+
rev: 0.8.1
3535
hooks:
3636
- id: slyp
3737
- repo: https://github.com/PyCQA/isort
3838
rev: 5.13.2
3939
hooks:
4040
- id: isort
4141
- repo: https://github.com/asottile/pyupgrade
42-
rev: v3.17.0
42+
rev: v3.18.0
4343
hooks:
4444
- id: pyupgrade
4545
args: ["--py37-plus"]

src/check_jsonschema/cachedownloader.py

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -100,7 +100,9 @@ class FailedDownloadError(Exception):
100100

101101

102102
class CacheDownloader:
103-
def __init__(self, cache_dir: str | None = None, disable_cache: bool = False):
103+
def __init__(
104+
self, cache_dir: str | None = None, disable_cache: bool = False
105+
) -> None:
104106
if cache_dir is None:
105107
self._cache_dir = _resolve_cache_dir()
106108
else:
@@ -170,7 +172,7 @@ def __init__(
170172
downloader: CacheDownloader,
171173
*,
172174
validation_callback: t.Callable[[bytes], t.Any] | None = None,
173-
):
175+
) -> None:
174176
self._file_url = file_url
175177
self._filename = filename or file_url.split("/")[-1]
176178
self._downloader = downloader

src/check_jsonschema/checker.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@
1717

1818

1919
class _Exit(Exception):
20-
def __init__(self, code: int):
20+
def __init__(self, code: int) -> None:
2121
self.code = code
2222

2323

@@ -31,7 +31,7 @@ def __init__(
3131
format_opts: FormatOptions | None = None,
3232
traceback_mode: str = "short",
3333
fill_defaults: bool = False,
34-
):
34+
) -> None:
3535
self._schema_loader = schema_loader
3636
self._instance_loader = instance_loader
3737
self._reporter = reporter

src/check_jsonschema/cli/param_types.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -117,7 +117,7 @@ def __init__(
117117
encoding: str | None = None,
118118
errors: str | None = "strict",
119119
atomic: bool = False,
120-
):
120+
) -> None:
121121
self.name: str = os.fspath(filename)
122122
self.mode = mode
123123
self.encoding = encoding

src/check_jsonschema/transforms/base.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ def __init__(
1010
self,
1111
*,
1212
on_data: t.Callable[[list | dict], list | dict] | None = None,
13-
):
13+
) -> None:
1414
self.on_data = on_data
1515

1616
def modify_yaml_implementation(self, implementation: ruamel.yaml.YAML) -> None:

0 commit comments

Comments
 (0)