Skip to content

Commit f5e4fa6

Browse files
committed
Use SaslAuthenticationFailedError in kafka.conn connection failure
Drop unused AuthenticationFailedError
1 parent cf1a999 commit f5e4fa6

File tree

2 files changed

+1
-5
lines changed

2 files changed

+1
-5
lines changed

Diff for: kafka/conn.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -813,7 +813,7 @@ def _sasl_authenticate(self, future):
813813
log.info('%s: %s', self, self._sasl_mechanism.auth_details())
814814
return future.success(True)
815815
else:
816-
return future.failure(Errors.AuthenticationFailedError('Failed to authenticate via SASL %s' % self.config['sasl_mechanism']))
816+
return future.failure(Errors.SaslAuthenticationFailedError('Failed to authenticate via SASL %s' % self.config['sasl_mechanism']))
817817

818818
def blacked_out(self):
819819
"""

Diff for: kafka/errors.py

-4
Original file line numberDiff line numberDiff line change
@@ -85,10 +85,6 @@ class AuthenticationMethodNotSupported(KafkaError):
8585
pass
8686

8787

88-
class AuthenticationFailedError(KafkaError):
89-
retriable = False
90-
91-
9288
class BrokerResponseError(KafkaError):
9389
errno = None
9490
message = None

0 commit comments

Comments
 (0)