#NEWLINE# def _read_forever( self , data ) : #NEWLINE# #INDENT# '\n        Read until the connection closes.\n        ' #NEWLINE# if ( not self . _requests ) : #NEWLINE# #INDENT# return #NEWLINE# #UNINDENT# request = self . _requests [ 0 ] #NEWLINE# response = request . response #NEWLINE# self . _reset_timer ( ) #NEWLINE# response . length += len ( data ) #NEWLINE# if response . _decoder : #NEWLINE# #INDENT# data = response . _decoder . decompress ( data ) #NEWLINE# #UNINDENT# response . _receive ( data ) #NEWLINE# self . _safely_call ( request . session . on_progress , response , response . length , 0 )