Skip to content

Commit

Permalink
Fix _check_shape str formatting for variadics
Browse files Browse the repository at this point in the history
  • Loading branch information
asford authored and patrick-kidger committed Mar 6, 2024
1 parent 1b3173a commit 5e2518c
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion jaxtyping/_array_types.py
Original file line number Diff line number Diff line change
Expand Up @@ -229,7 +229,7 @@ def _check_shape(
return _check_dims(cls.dims, obj.shape, single_memo, arg_memo)
else:
if obj.ndim < len(cls.dims) - 1:
return f"this array has {obj.ndim} dimensions, which is fewer than {len(cls.dims - 1)} that is the minimum expected by the type hint" # noqa: E501
return f"this array has {obj.ndim} dimensions, which is fewer than {len(cls.dims) - 1} that is the minimum expected by the type hint" # noqa: E501
i = cls.index_variadic
j = -(len(cls.dims) - i - 1)
if j == 0:
Expand Down

0 comments on commit 5e2518c

Please sign in to comment.