Last modified: 2012-12-20 13:30:06 UTC

Wikimedia Bugzilla is closed!

Wikimedia has migrated from Bugzilla to Phabricator. Bug reports should be created and updated in Wikimedia Phabricator instead. Please create an account in Phabricator and add your Bugzilla email address to it.
Wikimedia Bugzilla is read-only. If you try to edit or create any bug report in Bugzilla you will be shown an intentional error message.
In order to access the Phabricator task corresponding to a Bugzilla report, just remove "static-" from its URL.
You could still run searches in Bugzilla or access your list of votes but bug reports will obviously not be up-to-date in Bugzilla.
Bug 11853 - you can no longer specify date format using the "units" technique
you can no longer specify date format using the "units" technique
Product: MediaWiki extensions
Classification: Unclassified
Semantic MediaWiki (Other open bugs)
All All
: Lowest minor (vote)
: ---
Assigned To: Markus Krötzsch
Depends on:
  Show dependency treegraph
Reported: 2007-11-02 11:03 UTC by S Page
Modified: 2012-12-20 13:30 UTC (History)
0 users

See Also:
Web browser: ---
Mobile Platform: ---
Assignee Huggle Beta Tester: ---


Description S Page 2007-11-02 11:03:20 UTC
SMW 0.7 let you specify a "unit" for dates either by adding something like [[primary display unit=%Y]] to an attribute page or in a query like [[Date of birth:=+]][[Date of birth:=%b %m]].  (The first results in seeing 2007 for a date, the second results in Nov 02.)

This overloading of the unit specifier is broken in 1.0  The new SMW_DV_Time.php simply ignores date formats.  The 0.7 SMW_DT_DateTime.php, if passed desired units, would use strftime($wantedFormat, $time) to format the date.

This is a significant regression.  However, I don't know how many installations use this feature.  It lets you control the precision of a date, and it lets you do things like show a birthday a certain way.

MediaWiki has its own way to format dates but you could still support the UNIX-y approach by looking for a % in the unit string.
Comment 1 Markus Krötzsch 2007-11-02 12:41:03 UTC
Since we plan to change the date processing code into something that supports the whole history of the universe also without 64bit support, we need to get away from PHP's (and thus, alas, also MediaWiki's) datetime processing/formatting.

The feature is cool and useful, so something simliar should be added in the future again. But maybe something less technical would be good (e.g. using a small set of predefined formatting constants that could be internationalised).

And, as you said, we may not need to be concerned about too many people using this. If they still pop up, they can contribute requirements to the new implementation ;-)
Comment 2 Andre Klapper 2012-12-20 13:30:06 UTC
[Removing RESOLVED LATER as discussed in and announced in . Reopening and setting priority to "Lowest". For future reference, please use either RESOLVED WONTFIX (for issues that will not be fixed), or simply set lowest priority. Thanks a lot!]

Note You need to log in before you can comment on or make changes to this bug.