Skip to content

Commit

Permalink
Fixed type annotations to support Python 2.7
Browse files Browse the repository at this point in the history
  • Loading branch information
JGabrielGruber committed Sep 22, 2022
1 parent 1882872 commit 0c64bc7
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion kafka/producer/kafka.py
Original file line number Diff line number Diff line change
Expand Up @@ -538,7 +538,8 @@ def _estimate_size_in_bytes(self, key, value, headers=[]):
return LegacyRecordBatchBuilder.estimate_size_in_bytes(
magic, self.config['compression_type'], key, value)

def send(self, topic, value=None, key=None, headers=None, partition=None, timestamp_ms=None) -> RecordMetadata:
def send(self, topic, value=None, key=None, headers=None, partition=None, timestamp_ms=None):
# type: (str, bytes, bytes, list, int, int) -> RecordMetadata
"""Publish a message to a topic.
Arguments:
Expand Down

0 comments on commit 0c64bc7

Please sign in to comment.