From fe243c2d8db9a00a55a273c4f656f15fa1c5a81f Mon Sep 17 00:00:00 2001 From: Dana Powers Date: Sat, 21 Oct 2017 15:46:33 -0700 Subject: Fixup for PR 1258 / _try_authenticate --- kafka/conn.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'kafka/conn.py') diff --git a/kafka/conn.py b/kafka/conn.py index 4c21b8c..da08eac 100644 --- a/kafka/conn.py +++ b/kafka/conn.py @@ -455,7 +455,10 @@ class BrokerConnection(object): sasl_response.add_callback(self._handle_sasl_handshake_response, future) sasl_response.add_errback(lambda f, e: f.failure(e), future) self._sasl_auth_future = future - self.recv() + + for r, f in self.recv(): + f.success(r) + # A connection error could trigger close() which will reset the future if self._sasl_auth_future is None: return False -- cgit v1.2.1