Skip to content
This repository has been archived by the owner on Mar 24, 2021. It is now read-only.

Commit

Permalink
Merge pull request #866 from Parsely/bugfix/unpack_form
Browse files Browse the repository at this point in the history
descriptive error message for buffer decode failures
  • Loading branch information
Emmett J. Butler committed Sep 17, 2018
2 parents 286b33d + abc9c38 commit 197fb48
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions pykafka/simpleconsumer.py
Original file line number Diff line number Diff line change
Expand Up @@ -812,6 +812,10 @@ def unlock_partitions(parts):
# If the broker dies while we're supposed to stop,
# it's fine, and probably an integration test.
return
except socket.error:
raise ValueError("Failed to decode IO buffer. Ensure that "
"the KafkaClient's broker_version kwarg "
"matches the version of the Kafka cluster.")
parts_by_error = build_parts_by_error(response, self._partitions_by_id)
handle_partition_responses(
self._default_error_handlers,
Expand Down

0 comments on commit 197fb48

Please sign in to comment.