Every line of 'python record time' code snippets is scanned for vulnerabilities by our powerful machine learning engine that combs millions of open source libraries, ensuring your Python code is secure.
266 def time(self): 267 """Return now() in Apache Common Log Format (no timezone).""" 268 now = datetime.datetime.now() 269 monthnames = ['jan', 'feb', 'mar', 'apr', 'may', 'jun', 270 'jul', 'aug', 'sep', 'oct', 'nov', 'dec'] 271 month = monthnames[now.month - 1].capitalize() 272 return ('[%02d/%s/%04d:%02d:%02d:%02d]' % 273 (now.day, month, now.year, now.hour, now.minute, now.second))
80 def __time(self): 81 """Wrapper for time.time() to allow unit testing. 82 """ 83 return time.time()