Skip to content

Commit 619ee8b

Browse files
authored
Merge pull request #160 from amotzop/fix_tapify_typing
Fixed the typing of the function
2 parents f8d477c + 3c3ee97 commit 619ee8b

File tree

1 file changed

+2
-3
lines changed

1 file changed

+2
-3
lines changed

src/tap/tapify.py

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -32,10 +32,9 @@
3232

3333
from tap import Tap
3434

35-
InputType = TypeVar("InputType")
3635
OutputType = TypeVar("OutputType")
3736

38-
_ClassOrFunction = Union[Callable[[InputType], OutputType], type[OutputType]]
37+
_ClassOrFunction = Union[Callable[..., OutputType], type[OutputType]]
3938

4039

4140
@dataclasses.dataclass
@@ -296,7 +295,7 @@ def to_tap_class(class_or_function: _ClassOrFunction) -> type[Tap]:
296295

297296

298297
def tapify(
299-
class_or_function: Union[Callable[[InputType], OutputType], type[OutputType]],
298+
class_or_function: Union[Callable[..., OutputType], type[OutputType]],
300299
known_only: bool = False,
301300
command_line_args: Optional[list[str]] = None,
302301
explicit_bool: bool = False,

0 commit comments

Comments
 (0)