#NEWLINE# def finish_response( self , response , request ) : #NEWLINE# #INDENT# self . active . remove ( request ) #NEWLINE# if isinstance ( response , Response ) : #NEWLINE# #INDENT# self . active_size -= max ( len ( response . body ) , self . MIN_RESPONSE_SIZE ) #NEWLINE# #UNINDENT# else : #NEWLINE# #INDENT# self . active_size -= response . MIN_RESPONSE_SIZE