We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent a58ff32 commit 477230fCopy full SHA for 477230f
redis/connection.py
@@ -1425,15 +1425,11 @@ def __init__(
1425
self.reset()
1426
1427
def __repr__(self) -> str:
1428
- arg = ""
1429
- if "host" in self.connection_kwargs:
1430
- arg = f"{self.connection_kwargs['host']}:{self.connection_kwargs['port']}"
1431
- elif "path" in self.connection_kwargs:
1432
- arg = self.connection_kwargs["path"]
1433
-
+ conn_kwargs = ",".join([f"{k}={v}" for k, v in self.connection_kwargs.items()])
1434
return (
1435
f"<{type(self).__module__}.{type(self).__name__}"
1436
- f"({self.connection_class.__name__}<{arg}>)>"
+ f"({self.connection_class.__module__}.{self.connection_class.__name__}"
+ f"({conn_kwargs}))>"
1437
)
1438
1439
def get_protocol(self):
0 commit comments