summaryrefslogtreecommitdiff
path: root/kafka/client_async.py
diff options
context:
space:
mode:
authorJeff Widman <jeff@jeffwidman.com>2018-05-10 16:12:19 -0700
committerJeff Widman <jeff@jeffwidman.com>2018-05-23 15:19:01 -0700
commit11cf3973bfc64ab0b4e471fc56dae911df1ec8d9 (patch)
tree474937a8c01bb32a3b12a944d9a9ad6b32d81800 /kafka/client_async.py
parent9221fcf83528b5c3657e43636cb84c1d18025acd (diff)
downloadkafka-python-11cf3973bfc64ab0b4e471fc56dae911df1ec8d9.tar.gz
Stop shadowing `ConnectionError`
In Python3, `ConnectionError` is a native exception. So rename our custom one to `KafkaConnectionError` to prevent accidentally shadowing the native one. Note that there are still valid uses of `ConnectionError` in this code. They already expect a native Python3 `ConnectionError`, and also already handle the Python2 compatibility issues.
Diffstat (limited to 'kafka/client_async.py')
-rw-r--r--kafka/client_async.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/kafka/client_async.py b/kafka/client_async.py
index 9556eca..a9704fa 100644
--- a/kafka/client_async.py
+++ b/kafka/client_async.py
@@ -602,7 +602,7 @@ class KafkaClient(object):
log.warning('Protocol out of sync on %r, closing', conn)
except socket.error:
pass
- conn.close(Errors.ConnectionError('Socket EVENT_READ without in-flight-requests'))
+ conn.close(Errors.KafkaConnectionError('Socket EVENT_READ without in-flight-requests'))
continue
self._idle_expiry_manager.update(conn.node_id)