black formatting

This commit is contained in:
kadarakos 2022-10-27 17:13:10 +00:00
parent e42079a4bd
commit 6a6c001cf7

View File

@ -1738,9 +1738,7 @@ def all_equal(iterable):
def require_annotation( def require_annotation(
annotations: Sequence[Union[str, int]], annotations: Sequence[Union[str, int]], *, require_complete: Sequence[bool] = None
*,
require_complete: Sequence[bool] = None
) -> Callable: ) -> Callable:
""" """
To be used as a decorator for functions whose first argument To be used as a decorator for functions whose first argument
@ -1788,7 +1786,9 @@ def require_annotation(
msg += " (complete)" msg += " (complete)"
else: else:
msg = "" msg = ""
for i, (attr, complete) in enumerate(zip(annotations, require_complete)): for i, (attr, complete) in enumerate(
zip(annotations, require_complete)
):
if i != 0: if i != 0:
msg += " " msg += " "
msg += str(attr) msg += str(attr)
@ -1803,5 +1803,7 @@ def require_annotation(
) )
else: else:
return func(doclike, *args, **kwargs) return func(doclike, *args, **kwargs)
return func_with_require return func_with_require
return require_annotation_decorator return require_annotation_decorator