mirror of
https://github.com/p2p-ld/numpydantic.git
synced 2025-01-10 13:54:26 +00:00
python 3.9 compat
This commit is contained in:
parent
fbc7d2914b
commit
a345cc6504
2 changed files with 3 additions and 1 deletions
|
@ -101,6 +101,8 @@ select = [
|
||||||
]
|
]
|
||||||
ignore = [
|
ignore = [
|
||||||
"ANN101", "ANN102", "ANN401", "ANN204",
|
"ANN101", "ANN102", "ANN401", "ANN204",
|
||||||
|
# explicit strict arg for zip
|
||||||
|
"B905",
|
||||||
# builtin type annotations
|
# builtin type annotations
|
||||||
"UP006", "UP035",
|
"UP006", "UP035",
|
||||||
# | for Union types (only supported >=3.10
|
# | for Union types (only supported >=3.10
|
||||||
|
|
|
@ -44,7 +44,7 @@ def list_of_lists_schema(shape: Shape, array_type_handler: dict) -> ListSchema:
|
||||||
shape_labels = reversed(split_parts)
|
shape_labels = reversed(split_parts)
|
||||||
shape_args = reversed(shape.prepared_args)
|
shape_args = reversed(shape.prepared_args)
|
||||||
list_schema = None
|
list_schema = None
|
||||||
for arg, label in zip(shape_args, shape_labels, strict=False):
|
for arg, label in zip(shape_args, shape_labels):
|
||||||
# which handler to use? for the first we use the actual type
|
# which handler to use? for the first we use the actual type
|
||||||
# handler, everywhere else we use the prior list handler
|
# handler, everywhere else we use the prior list handler
|
||||||
inner_schema = array_type_handler if list_schema is None else list_schema
|
inner_schema = array_type_handler if list_schema is None else list_schema
|
||||||
|
|
Loading…
Reference in a new issue