Description

Dates before 1970-01-01T00:00:00 cause an internal exception in MoinMoin which produces a purple error page.

Furthermore, the date 1970-01-01T00:00:00 is displayed as the current time, and not itself.

Steps to reproduce

  1. Insert text below on a page and press "Preview"

Example

[[Date(1969-01-01T00:00:00)]]
[[Date(1970-01-01T00:00:00)]]

Details

This Wiki.

Workaround

Write your dates out in full and hope that your users can understand your format unambiguously.

Discussion

I am running a genealogy wiki. I am writing about people born in dates like 1520-04-23. I need to write dates long in the past. I can't even write my mother's birthday!

This is likely to not get fixed (well, we can catch the backtrace, but implementing a new time system is not planned).

The internal timing calculations, formatting routines etc. build on the libc time functions, that is UNIX time. UNIX time is measured in seconds since 1970, so it simply wasn't designed to represent times before 1970 (and, as long as 32bit unsigned integers are used, also not for times far in the future).

So simply use strings like 1345-12-31 for your dates.

Additionally to that underlying system limitations, moin does some special stuff to avoid problems with times around 1970-1-1 due to timezone differences and maybe uses the value 0 to represent "calculate current time", this explains your 1970-1-1 trouble.

Things we can fix easily:

Since the time module can't represent dates before the epoch or after 2038, we should move to use the datetime module, which support sane dates. We have about 20 years to do this, we should do this as soon as we require Python 2.3. -- NirSoffer 2005-02-22 20:27:07

Plan


CategoryMoinMoinBugFixed

MoinMoin: MoinMoinBugs/DatesBefore1970BreakPages (last edited 2007-10-29 19:06:57 by localhost)