time, calendar, datetime, etc
tim.one at comcast.net
Fri Aug 1 04:49:28 CEST 2003
> The datetime module is a great piece of work, but I wonder why it
> wasn't made more compatible with the time module? It would seem to
> be simple enough to provide a sequence interface so the object
> supports the 9-tuple directly (for either naive or tz-aware, pick
> one,) and also supports the same attributes as the objects in the
> time package.
The time module consists of thin wrappers around C's mish-mash of quirky,
platform-dependent time manipulation functions. We eventually want to
pretend the time module never existed <0.9 wink>. 9-tuples are absurd.
> I also wonder why anyone made the choice to set the year origin at
> 1AD? That decision, by itself, makes it almost unusable for my hobby
> (astrological software, which is basically astronomical software
> with a different focus.)
The datetime design took place on a Zope Wiki:
and Zope Corp funded the work. If more astronomers used Zope, the outcome
may have been different. As things were, fast field extraction for
formatting and fiddling, compact memory representation and pickles,
"practical" dates, fast compaison, and exact arithmetic were goals. See
especially the SuggestedRequirements page in that Wiki. Astronomers were
dissed in its first bullet <wink>.
More information about the Python-list