>>> import datetime >>> datetime.datetime.now().strftime("%Y-%m-%d %H:%M:%S") '2011-11-03 18:21:26'
import time def current_milli_time(): return round(time.time() * 1000)