-
Notifications
You must be signed in to change notification settings - Fork 0
Open
Description
Type hints using Callable cause errors, both with explicit argument list and with ellipsis.
Example error output from tensorsat:
ERROR: Parsing param 'order' type annotation 'str | Callable[[frozenset[int]], SupportsRichComparison] | None', <class 'ValueError'>: Found empty type name at start = 15, stop = 31, annotation[start:stop] = '[frozenset[int]]', annotation = 'str | Callable[[frozenset[int]], SupportsRichComparison] | None'
ERROR: Parsing param 'recipe' type annotation 'Callable[[DiagramBuilder], None]', <class 'ValueError'>: Found empty type name at start = 9, stop = 25, annotation[start:stop] = '[DiagramBuilder]', annotation = 'Callable[[DiagramBuilder], None]'
ERROR: Parsing param 'func' type annotation 'Callable[..., El | Point]', <class 'ValueError'>: Ellipsis found in args, but not in last position, at start = 9, stop = 24, annotation[start:stop] = '..., El | Point', annotation = 'Callable[..., El | Point]'
ERROR: Parsing return type annotation 'Sequence[Port]', <class 'ValueError'>: Ellipsis found in args, but not in last position, at start = 9, stop = 24, annotation[start:stop] = '..., El | Point', annotation = 'Callable[..., El | Point]'
Metadata
Metadata
Assignees
Labels
No labels