Page MenuHomePhabricator

issue with the way special type Date treats pre-1582 years
Closed, ResolvedPublic

Description

There appears to be an issue with the way that special Type:Date handles pre-1582 (pre-Gregorian) dates. For instance, when the value specified is "1500", SMW somehow translates this as "1499". Perhaps 1500 gets interpreted as 1 January minus one day = 31 December, 1499?

Btw, this is not a new issue. In fact, I remember the exact same problem occurring on a different system about a year ago.

Specifications: MW 1.17, MySQL 5.5.23, Php 5.3.10, SMW 1.7.1


Version: unspecified
Severity: normal
OS: Linux

Details

Reference
bz37038

Event Timeline

bzimport raised the priority of this task from to Medium.Nov 22 2014, 12:28 AM
bzimport set Reference to bz37038.
bzimport added a subscriber: Unknown Object (MLST).

Update. I just got a different (related?) error: some of the values are instead set to 1 January 1970, for no apparent reason.

You can probably safely ignore the second comment, which does appear to be unrelated.

I've looked at some 'SMWs of the month' and noticed that Familypedia is having the same issue. Is it perhaps a PHP problem?

Could it be that "1500" is shown as "1499" because it is interpreted as "1 January 1500" and the year didn't necessarily start on 1 January?

The problem should be fixed in the current development version with change https://gerrit.wikimedia.org/r/#/c/28666/ See also the comments for Bug 41126.