Skip to content

Commit

Permalink
[KIP-54] Disable no-member and not-an-iterable checks for assignment …
Browse files Browse the repository at this point in the history
…variables
  • Loading branch information
aynroot committed May 26, 2020
1 parent 02b8635 commit 5611809
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions kafka/coordinator/assignors/sticky/sticky_assignor.py
Original file line number Diff line number Diff line change
Expand Up @@ -643,7 +643,7 @@ def parse_member_metadata(cls, metadata):
)

member_partitions = []
for topic, partitions in decoded_user_data.previous_assignment:
for topic, partitions in decoded_user_data.previous_assignment: # pylint: disable=no-member
member_partitions.extend([TopicPartition(topic, partition) for partition in partitions])
return StickyAssignorMemberMetadataV1(
# pylint: disable=no-member
Expand All @@ -658,7 +658,7 @@ def metadata(cls, topics):
else:
log.debug("Member assignment is available, generating the metadata: generation {}".format(cls.generation))
partitions_by_topic = defaultdict(list)
for topic_partition in cls.member_assignment:
for topic_partition in cls.member_assignment: # pylint: disable=not-an-iterable
partitions_by_topic[topic_partition.topic].append(topic_partition.partition)
data = StickyAssignorUserDataV1(six.iteritems(partitions_by_topic), cls.generation)
user_data = data.encode()
Expand Down

0 comments on commit 5611809

Please sign in to comment.