use time.struct_time instead of time.strptime