#NEWLINE# def _pop_new_chunk( self ) : #NEWLINE# #INDENT# if self . chunks_exhausted : #NEWLINE# #INDENT# return b'' #NEWLINE# #UNINDENT# try : #NEWLINE# #INDENT# chunk = self . content [ self . index ] #NEWLINE# #UNINDENT# except IndexError : #NEWLINE# #INDENT# chunk = b'' #NEWLINE# self . chunks_exhausted = True #NEWLINE# #UNINDENT# else : #NEWLINE# #INDENT# self . index += 1 #NEWLINE# #UNINDENT# chunk = self . _encode_chunk ( chunk ) #NEWLINE# if ( not isinstance ( chunk , bytes ) ) : #NEWLINE# #INDENT# chunk = chunk . encode ( ) #NEWLINE# #UNINDENT# return chunk