#NEWLINE# def _raise_if_offset_out_of_range( self ) : #NEWLINE# #INDENT# 'Check FetchResponses for offset out of range.\n\n        Raises:\n            OffsetOutOfRangeError: if any partition from previous FetchResponse\n                contains OffsetOutOfRangeError and the default_reset_policy is\n                None\n        ' #NEWLINE# if ( not self . _offset_out_of_range_partitions ) : #NEWLINE# #INDENT# return #NEWLINE# #UNINDENT# current_out_of_range_partitions = { #NEWLINE# #INDENT# #NEWLINE# #UNINDENT# } #NEWLINE# for ( partition , offset ) in self . _offset_out_of_range_partitions : #NEWLINE# #INDENT# if ( not self . _subscriptions . is_fetchable ( partition ) ) : #NEWLINE# #INDENT# log . debug ( 'Ignoring fetched records for %s since it is no longer fetchable' , partition ) #NEWLINE# continue #NEWLINE# #UNINDENT# position = self . _subscriptions . assignment [ partition ] . position #NEWLINE# if ( ( self is not None ) and ( offset == position ) ) : #NEWLINE# #INDENT# current_out_of_range_partitions [ partition ] = position #NEWLINE# #UNINDENT# #UNINDENT# self . _offset_out_of_range_partitions . clear ( ) #NEWLINE# if current_out_of_range_partitions : #NEWLINE# #INDENT# raise Errors . OffsetOutOfRangeError ( current_out_of_range_partitions )