Message223840
Currently (tested on py3.4):
>>> from datetime import datetime, date
>>> d = datetime.now()
>>> date(d)
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
TypeError: an integer is required (got type datetime.datetime)
IMO, it's like doing int(float), a truncation of some info. For example, this is what I want to happen:
>>> d
datetime.datetime(2014, 7, 24, 11, 38, 44, 966613)
>>> date(d)
datetime.date(2014, 7, 24) |
|
Date |
User |
Action |
Args |
2014-07-24 14:41:32 | facundobatista | set | recipients:
+ facundobatista |
2014-07-24 14:41:32 | facundobatista | set | messageid: <1406212892.92.0.452471397422.issue22058@psf.upfronthosting.co.za> |
2014-07-24 14:41:32 | facundobatista | link | issue22058 messages |
2014-07-24 14:41:32 | facundobatista | create | |
|