|
|
@ -377,7 +377,7 @@ def _extract_parameters_from_callback(func: Callable[..., Any], globalns: Dict[s |
|
|
|
parameters: List[CommandParameter] = [] |
|
|
|
for parameter in iterator: |
|
|
|
if parameter.annotation is parameter.empty: |
|
|
|
raise TypeError(f'annotation for {parameter.name} must be given in callback {func.__qualname__!r}') |
|
|
|
raise TypeError(f'parameter {parameter.name!r} is missing a type annotation in callback {func.__qualname__!r}') |
|
|
|
|
|
|
|
resolved = resolve_annotation(parameter.annotation, globalns, globalns, cache) |
|
|
|
param = annotation_to_parameter(resolved, parameter) |
|
|
|