Add more type annotations

This commit is contained in:
Kovid Goyal
2021-10-27 12:31:10 +05:30
parent b22bda3cba
commit a26f041964
10 changed files with 43 additions and 38 deletions

View File

@@ -64,7 +64,7 @@ class PayloadGetter:
no_response = NoResponse()
payload_get = object()
ResponseType = Union[bool, str, None]
ResponseType = Union[bool, str, None, NoResponse]
CmdReturnType = Union[Dict[str, Any], List[Any], Tuple[Any, ...], str, int, float, bool]
CmdGenerator = Iterator[CmdReturnType]
PayloadType = Optional[Union[CmdReturnType, CmdGenerator]]