Skip to content

Commit ac313b6

Browse files
committed
Update black to latest stable in both pre-commit and pyproject.toml
1 parent a59aa31 commit ac313b6

File tree

3 files changed

+15
-11
lines changed

3 files changed

+15
-11
lines changed

.pre-commit-config.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,6 @@ repos:
1919
- id: mypy
2020
args: [--ignore-missing-imports, --no-strict-optional]
2121
- repo: https://github.com/python/black
22-
rev: stable
22+
rev: 20.8b1
2323
hooks:
2424
- id: black

graphene_pydantic/converters.py

Lines changed: 13 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -262,15 +262,19 @@ def convert_generic_python_type(
262262
return convert_union_type(
263263
type_, field, registry, parent_type=parent_type, model=model
264264
)
265-
elif origin in (
266-
T.Tuple,
267-
T.List,
268-
T.Set,
269-
T.Collection,
270-
T.Iterable,
271-
list,
272-
set,
273-
) or issubclass(origin, collections.abc.Sequence):
265+
elif (
266+
origin
267+
in (
268+
T.Tuple,
269+
T.List,
270+
T.Set,
271+
T.Collection,
272+
T.Iterable,
273+
list,
274+
set,
275+
)
276+
or issubclass(origin, collections.abc.Sequence)
277+
):
274278
# TODO: find a better way of divining that the origin is sequence-like
275279
inner_types = getattr(type_, "__args__", [])
276280
if not inner_types: # pragma: no cover # this really should be impossible

pyproject.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ pytest = "~4.6.4"
2929
pytest-cov = "~2.7.1"
3030
tox = "~3.12.0" # sync with tox.ini
3131
mypy = "0.720"
32-
black = "19.3b0"
32+
black = "20.8b1"
3333
pre-commit = "~1.17.0"
3434
tox-gh-actions = "^1.3.0"
3535

0 commit comments

Comments
 (0)