#NEWLINE# def reduce_response( self , response , seen = None ) : #NEWLINE# #INDENT# ' Reduce response object to make it compatible with ``pickle``\n        ' #NEWLINE# if ( seen is None ) : #NEWLINE# #INDENT# seen = { #NEWLINE# #INDENT# #NEWLINE# #UNINDENT# } #NEWLINE# #UNINDENT# try : #NEWLINE# #INDENT# return seen [ id ( response ) ] #NEWLINE# #UNINDENT# except KeyError : #NEWLINE# #INDENT# pass #NEWLINE# #UNINDENT# result = _Store ( ) #NEWLINE# response . content #NEWLINE# for field in self . _response_attrs : #NEWLINE# #INDENT# setattr ( result , field , self . _picklable_field ( response , field ) ) #NEWLINE# #UNINDENT# seen [ id ( response ) ] = result #NEWLINE# result . history = tuple ( ( self . reduce_response ( r , seen ) for r in response . history ) ) #NEWLINE# return result