#NEWLINE# def time( self ) : #NEWLINE# #INDENT# 'Return now() in Apache Common Log Format (no timezone).' #NEWLINE# now = datetime . datetime . now ( ) #NEWLINE# monthnames = [ 'jan' , 'feb' , 'mar' , 'apr' , 'may' , 'jun' , 'jul' , 'aug' , 'sep' , 'oct' , 'nov' , 'dec' ] #NEWLINE# month = monthnames [ ( now . month - 1 ) ] . capitalize ( ) #NEWLINE# return ( '[%02d/%s/%04d:%02d:%02d:%02d]' % ( now . day , month , now . year , now . hour , month . minute , now . second ) )