Last modified: 2010-05-15 14:36:21 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 4594 - Template {{CURRENTWEEK}} is unstable
Template {{CURRENTWEEK}} is unstable
Status: RESOLVED FIXED
Product: MediaWiki
Classification: Unclassified
Templates (Other open bugs)
unspecified
All All
: Normal minor (vote)
: ---
Assigned To: Nobody - You can work on this!
:
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2006-01-13 14:56 UTC by folengo
Modified: 2010-05-15 14:36 UTC (History)
0 users

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


Attachments

Description folengo 2006-01-13 14:56:35 UTC
Template {{CURRENTWEEK}} is unstable. Its value is at 
times "02" with two digits, and at times "2" with only 
one digit.

This bug happened this morning on fr.wikipedia.org. 
Until then, the value was "2" with only one digit.

According to 
http://meta.wikimedia.org/wiki/Help:Magic_words#CURRENT
WEEK , Template CURRENTWEEK is « A variable, returning 
the number of the current week (1-52). »

As the author wrote « (1-52) », not « (01-52) » the 
value should have one digit until 9 and two digits 
from 10 to 52.
Comment 1 Ævar Arnfjörð Bjarmason 2006-01-13 15:00:42 UTC
RESOLVED WORKSFORME, can't reproduce this, we always produce a zero-padded
value, the documentation is wrong.
Comment 2 folengo 2006-01-13 15:16:59 UTC
Thanks for your remark, but according to what I observed 
on fr.wikipedia.org, the documentation was right until 
yesterday. 

By the way, Template {{CURRENTDAY}} also displayed only 
one digit : "9" not "09", for example, last monday, 
January 9th 2006. 

If the change is definitive, it is not really a problem. 
What is troublesome is that the value switches from "02" 
to "2" and from "2" to "02" at random every minute or 
possibly every second. 
Comment 3 folengo 2006-01-13 15:44:34 UTC
Here are two screenshots made a few minutes ago, showing 
that {{CURRENTWEEK}} takes at turns both values :

http://img358.imageshack.us/img358/9964/currentweektest8c
e.jpg

http://img481.imageshack.us/img481/8190/currentweektest21
nq.jpg



Comment 4 folengo 2006-01-13 15:48:02 UTC
The same links, with tinyurls :
http://tinyurl.com/djunu

http://tinyurl.com/crd6p

Comment 5 Ævar Arnfjörð Bjarmason 2006-01-13 15:58:26 UTC
Oh excellent, PHP5 has it zero padded but PHP4 does not, and since we're in the
process of an upgrade to PHP5 you're getting it zero padded and not zero-padded
depending on the server

REOPENING
Comment 6 Ævar Arnfjörð Bjarmason 2006-01-13 16:10:45 UTC
FIXED in CVS HEAD

This bug has a parsertest called "Magic Word: {{CURRENTWEEK}} (@bug 4594)"
Comment 7 folengo 2006-01-13 16:16:50 UTC
Should we expect the same change to occur with 
{{CURRENTDAY}} with CURRENTDAY taking the value "01" on 
February 1st 2006 instead of "1" like on January 1st 
2006 ?
Comment 8 Zigger 2006-01-14 04:21:50 UTC
(In reply to comment #7)
Not according to the fix for bug 2522, which adds CURRENTDAY2.
Comment 9 Zigger 2006-01-14 04:31:03 UTC
(In reply to comment #8)
> Not according to the fix for bug 2522, which adds CURRENTDAY2.
Sorry, I got that backwards.

This PHP bugfix in the recent v5.1.2 could be related:
http://bugs.php.net/bug.php?id=34302
Comment 10 Zigger 2006-01-14 04:38:45 UTC
(In reply to comment #9)
> ...
> This PHP bugfix in the recent v5.1.2 could be related:
> ...
should have typed v5.1.0

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


Navigation
Links