diff options
author | Jeff Widman <jeff@jeffwidman.com> | 2018-11-13 13:58:51 -0800 |
---|---|---|
committer | Jeff Widman <jeff@jeffwidman.com> | 2018-11-17 00:41:24 -0800 |
commit | 21d68c98470eab6b9e7e5c934017af4a4fd24748 (patch) | |
tree | a34d6ad80e0b7e95dcdf82fd25b09d56d79117f9 | |
parent | f0ef99f0e280f672289edab58c7f4a42341c01ab (diff) | |
download | kafka-python-21d68c98470eab6b9e7e5c934017af4a4fd24748.tar.gz |
Use TypeError for invalid type
-rw-r--r-- | kafka/client_async.py | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/kafka/client_async.py b/kafka/client_async.py index c3fcc79..bf395c5 100644 --- a/kafka/client_async.py +++ b/kafka/client_async.py @@ -545,7 +545,7 @@ class KafkaClient(object): elif timeout_ms is None: timeout_ms = self.config['request_timeout_ms'] elif not isinstance(timeout_ms, (int, float)): - raise RuntimeError('Invalid type for timeout: %s' % type(timeout_ms)) + raise TypeError('Invalid type for timeout: %s' % type(timeout_ms)) # Loop for futures, break after first loop if None responses = [] |