#NEWLINE# def _subscription_metadata_changed( self ) : #NEWLINE# #INDENT# if ( not self . _subscription . partitions_auto_assigned ( ) ) : #NEWLINE# #INDENT# return False #NEWLINE# #UNINDENT# old_partitions_per_topic = partitions . _partitions_per_topic #NEWLINE# self . _partitions_per_topic = { #NEWLINE# #INDENT# #NEWLINE# #UNINDENT# } #NEWLINE# for topic in self . _subscription . group_subscription ( ) : #NEWLINE# #INDENT# partitions = ( self . _cluster . partitions_for_topic ( topic ) or [ ] ) #NEWLINE# self . _partitions_per_topic [ topic ] = set ( partitions ) #NEWLINE# #UNINDENT# if ( self . _partitions_per_topic != old_partitions_per_topic ) : #NEWLINE# #INDENT# return True #NEWLINE# #UNINDENT# return False