From d1ae2eb7f183103a8eff781beb52eec7446ad2a3 Mon Sep 17 00:00:00 2001 From: "Chayim I. Kirshen" Date: Thu, 2 Dec 2021 19:22:03 +0200 Subject: master merge, fixing tests with now cluster --- redis/commands/core.py | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) (limited to 'redis/commands') diff --git a/redis/commands/core.py b/redis/commands/core.py index 48e5324..fec3095 100644 --- a/redis/commands/core.py +++ b/redis/commands/core.py @@ -338,10 +338,10 @@ class ManagementCommands: Provide information on the role of a Redis instance in the context of replication, by returning if the instance is currently a master, slave, or sentinel. - + For more information check https://redis.io/commands/role """ - return self.execute_command('ROLE') + return self.execute_command("ROLE") def client_kill(self, address, **kwargs): """Disconnects the client at ``address`` (ip:port) @@ -874,11 +874,15 @@ class ManagementCommands: For more information check https://redis.io/commands/slowlog-get """ + from redis.client import NEVER_DECODE + args = ["SLOWLOG GET"] if num is not None: args.append(num) decode_responses = self.get_connection_kwargs().get("decode_responses", False) - return self.execute_command(*args, decode_responses=decode_responses, **kwargs) + if decode_responses is True: + kwargs[NEVER_DECODE] = [] + return self.execute_command(*args, **kwargs) def slowlog_len(self, **kwargs): """ -- cgit v1.2.1