Last modified: 2013-01-29 01:42:49 UTC
In response to my feature request (bug 4870) Rob Church kindly added a <sort>
feature to MediaWiki. Since AFAICT it's not enabled on enwiki, I bet it's not
other Wikipedias / Wikibooks / etc. It would be great if you could enable it.
Rob, I'm cc'ing you. Hope you don't mind.
*** This bug has been marked as a duplicate of 9395 ***
That bug is about enwiki. This bug is about all other MediaWiki wikis. Reopening.
If you're asking for it to be enabled on all wikis then there shouldn't be a
separate bug for it being enabled on enwiki. You might as well add the request
for all other wikis in the other bug.
*** Bug 9395 has been marked as a duplicate of this bug. ***
Who is a person with appropriate sysadmin powers that I could reassign this to? :)
(In reply to comment #5)
> Who is a person with appropriate sysadmin powers that I could reassign this to?
Do we even know if the code is ready to be deployed? If not, then the shell keyword is pointless, since more coding is needed.
Seems to use natsort()...
$a = array(-5,-2,3,9);
Array (  => -2  => -5  => 0  => 3  => 9 )
...which is odd...
Also, the is no reverse natsort(), so it just reverses the items afterwards.
Gah, typo in test input above. Corrected:
C:\Users\Aaron>php -r "$a=array(-5,-2,0,3,9); natsort($a); print_r($a);"
 => -2
 => -5
 => 0
 => 3
 => 9
The above issue is due to a lack of context. It should be specified in the <sort> tag it it is numeric or alphanumeric.
Also, the array_reverse() seems excessive; instead the array_keys should be done manually, and in a reverse for loop in that case.
Closing for now.
Once the issues pointed out by Aaron are solved, each wiki community should decide whether they consider this extension as useful.
After those problems are fixed, is there any reason why any wiki community wouldn't want a <sort> extension? :) Those who don't want sorted lists can simply not use the <sort> tag.
Once Rob fixes those problems, is there any reason why any wiki community wouldn't want a <sort> extension? :) Those who don't want sorted lists can simply not use the <sort> tag.
(In reply to comment #13)
> Once Rob fixes those problems, is there any reason why any wiki community
> wouldn't want a <sort> extension? :) Those who don't want sorted lists can
> simply not use the <sort> tag.
As an aside, I don't think Rob is actively doing any mediawiki dev work at the moment (or for quite some time).
WONTFIX as long as comment 7 isn't handled which might be worth a separate bug report.
(In reply to comment #15)
> WONTFIX as long as comment 7 isn't handled which might be worth a separate
> bug report.
Andre, I just filed a separate bug report. Bug 44451: "Extension:Sort doesn't handle negative numbers well; maybe it needs a special 'numeric mode'."
But Extension:Sort was designed for alphabetic sorting, which is fine for ordinary use cases like "See also" lists. Why do you want numeric sorting? And are you sure you want this bug to remain WONTFIX just because the extension is optimized for alphabetic sorting?
note sorting multilingually properly is hard. I personally think it would be nice if such an extension used the collation class to sort stuff (at least by default) in order to be consistent with categories.
as for wontfix-once (and if) this extension is modified to meet above criticism it can be reopened easily enough.
People can keep on providing more requirements for Extension:Sort. But it is what it is. It was designed to handle the most common use cases, such as "See also" lists. You can install it on enwiki if you like, and enjoy its current (useful) functionality. Or you can go without it. :)
I'm not the maintainer. I'm not even a contributor. But I think that if you install it, then it's much more likely that contributors will step up and add the additional features you want.
Please do not file Extension:Sort feature requests here. Instead, please file them at <https://bugzilla.wikimedia.org/enter_bug.cgi?product=MediaWiki%20extensions&component=Sort>.