Skip to content

Commit

Permalink
update the return type of scan family
Browse files Browse the repository at this point in the history
Signed-off-by: amirreza <amir.rsf1380@gmail.com>
  • Loading branch information
amirreza8002 committed Dec 4, 2024
1 parent 9c67ddf commit bc11093
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions valkey/commands/core.py
Original file line number Diff line number Diff line change
Expand Up @@ -2987,7 +2987,7 @@ def scan(
count: Union[int, None] = None,
_type: Union[str, None] = None,
**kwargs,
) -> ResponseT:
) -> Tuple[int, List[bytes]]:
"""
Incrementally return lists of key names. Also return a cursor
indicating the scan position.
Expand Down Expand Up @@ -3047,7 +3047,7 @@ def sscan(
cursor: int = 0,
match: Union[PatternT, None] = None,
count: Union[int, None] = None,
) -> ResponseT:
) -> Tuple[int, List[bytes]]:
"""
Incrementally return lists of elements in a set. Also return a cursor
indicating the scan position.
Expand Down Expand Up @@ -3091,7 +3091,7 @@ def hscan(
match: Union[PatternT, None] = None,
count: Union[int, None] = None,
no_values: Union[bool, None] = None,
) -> ResponseT:
) -> Tuple[int, Dict[bytes, bytes]]:
"""
Incrementally return key/value slices in a hash. Also return a cursor
indicating the scan position.
Expand Down Expand Up @@ -3147,7 +3147,7 @@ def zscan(
match: Union[PatternT, None] = None,
count: Union[int, None] = None,
score_cast_func: Union[type, Callable] = float,
) -> ResponseT:
) -> Tuple[int, List[Tuple[bytes, float]]]:
"""
Incrementally return lists of elements in a sorted set. Also return a
cursor indicating the scan position.
Expand Down

0 comments on commit bc11093

Please sign in to comment.