From 0451d8d92e15ad08e7fcf9d4b3c0428f62c1a6f8 Mon Sep 17 00:00:00 2001 From: Jonathan Frawley Date: Thu, 18 Sep 2014 11:49:14 +0100 Subject: [PATCH] Passing is_master flag through on reset - is_master is not passed through when recreating the ConnectionPool. - This was causing unexpected behaviour where we would specifiy that we wish to connect to the slave, but the master would be read from instead. --- redis/sentinel.py | 1 + 1 file changed, 1 insertion(+) diff --git a/redis/sentinel.py b/redis/sentinel.py index 2f30062cd2..be10180407 100644 --- a/redis/sentinel.py +++ b/redis/sentinel.py @@ -129,6 +129,7 @@ def _checkpid(self): self.disconnect() self.reset() self.__init__(self.service_name, self.sentinel_manager, + is_master=self.is_master, connection_class=self.connection_class, max_connections=self.max_connections, **self.connection_kwargs)