diff --git a/redis/asyncio/cluster.py b/redis/asyncio/cluster.py index aedbd90456..7198abebd4 100644 --- a/redis/asyncio/cluster.py +++ b/redis/asyncio/cluster.py @@ -275,7 +275,7 @@ def __init__( ssl_min_version: Optional[ssl.TLSVersion] = None, ssl_ciphers: Optional[str] = None, protocol: Optional[int] = 2, - address_remap: Optional[Callable[[str, int], Tuple[str, int]]] = None, + address_remap: Optional[Callable[[Tuple[str, int]], Tuple[str, int]]] = None, cache_enabled: bool = False, client_cache: Optional[AbstractCache] = None, cache_max_size: int = 100, @@ -1152,7 +1152,7 @@ def __init__( startup_nodes: List["ClusterNode"], require_full_coverage: bool, connection_kwargs: Dict[str, Any], - address_remap: Optional[Callable[[str, int], Tuple[str, int]]] = None, + address_remap: Optional[Callable[[Tuple[str, int]], Tuple[str, int]]] = None, ) -> None: self.startup_nodes = {node.name: node for node in startup_nodes} self.require_full_coverage = require_full_coverage diff --git a/redis/cluster.py b/redis/cluster.py index e792d51867..6fde3530ef 100644 --- a/redis/cluster.py +++ b/redis/cluster.py @@ -506,7 +506,7 @@ def __init__( read_from_replicas: bool = False, dynamic_startup_nodes: bool = True, url: Optional[str] = None, - address_remap: Optional[Callable[[str, int], Tuple[str, int]]] = None, + address_remap: Optional[Callable[[Tuple[str, int]], Tuple[str, int]]] = None, **kwargs, ): """ @@ -1347,7 +1347,7 @@ def __init__( lock=None, dynamic_startup_nodes=True, connection_pool_class=ConnectionPool, - address_remap: Optional[Callable[[str, int], Tuple[str, int]]] = None, + address_remap: Optional[Callable[[Tuple[str, int]], Tuple[str, int]]] = None, **kwargs, ): self.nodes_cache = {}