#NEWLINE# def log_request( self ) : #NEWLINE# #INDENT# start = datetime . fromtimestamp ( self . time_start ) #NEWLINE# finish = datetime . fromtimestamp ( self . time_finish ) #NEWLINE# response_time = ( finish - start ) #NEWLINE# resp_headers = getattr ( self , 'response_headers' , { #NEWLINE# #INDENT# #NEWLINE# #UNINDENT# } ) #NEWLINE# resp = GeventResponse ( self . status , resp_headers , self . response_length ) #NEWLINE# if hasattr ( self , 'headers' ) : #NEWLINE# #INDENT# req_headers = [ h . split ( ':' , 1 ) for h in self . headers . headers ] #NEWLINE# #UNINDENT# else : #NEWLINE# #INDENT# req_headers = [ ] #NEWLINE# #UNINDENT# self . server . log . access ( resp , req_headers , self . environ , response_time )