mktime, how to handle dates before 01-01-1970 ?

Christian Heimes lists at cheimes.de
Tue Oct 6 17:11:44 EDT 2009


Ben Finney wrote:
> If you're committed to changing the epoch anyway, I would recommend
> using <URL:http://en.wikipedia.org/wiki/Astronomical_year_numbering>
> (epoch at 4004 BCE) since it is widely used to unify dates referring to
> human history.

I prefer JDN or MJD (http://en.wikipedia.org/wiki/JDN) for dates long
before or after the unix epoch. The conversion from JDN as float to a
datetime object is trivial.

Christian




More information about the Python-list mailing list