Best way to receive the return value when the type hint is Union[Awaitable[int], int]? · Issue #2399 · redis/redis-py
I noticed the return value type hint of redis-py functions are always like: Union[Awaitable[int], int]: (e.g. redis.commands.core.py:L4824) def hlen(self, name: str) -> Union[Awaitable[int], int]: ...
GitHub