Last modified: 2012-02-25 17:21:19 UTC

Wikimedia Bugzilla is closed!

Wikimedia migrated from Bugzilla to Phabricator. Bug reports are handled in Wikimedia Phabricator.
This static website is read-only and for historical purposes. It is not possible to log in and except for displaying bug reports and their history, links might be broken. See T36680, the corresponding Phabricator task for complete and up-to-date bug report information.
Bug 34680 - Make babel extension case aware in order to avoid clashes with existing user templates
Make babel extension case aware in order to avoid clashes with existing user ...
Status: RESOLVED FIXED
Product: MediaWiki extensions
Classification: Unclassified
Babel (Other open bugs)
unspecified
All All
: Normal normal (vote)
: ---
Assigned To: Robert Leverington
:
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2012-02-24 09:19 UTC by mabdul
Modified: 2012-02-25 17:21 UTC (History)
4 users (show)

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


Attachments

Description mabdul 2012-02-24 09:19:25 UTC
The commons babel template has the special feature "Bitmap graphics editors" (and others which are working, but it is not working with the babel extension because it is conflicting with Bulgarian (?). See also related discussion at 
https://commons.wikimedia.org/wiki/Category_talk:Graphics_abilities#update_tag

regards
Comment 2 Jarek Tuszynski 2012-02-24 12:37:20 UTC
Currently {{#babel}} function does not differentiate between upper and lower case codes. However at least on on commons and EN Wikipedia we seem to have many  existing user templates which only differ by the capitalization, for example [[commons:template:User BG-3]] gives 'This user is able to contribute at an advanced level to bitmap graphics (JPEG, PNG,...)." message and is unrelated to [[commons:template:User bg-3]] about user knowledge of Bulgarian language. 
See [[commons: User_talk:JarektBot#.22bitmap_graphics.22_and_.22audio_file.22_became_bulgarian_and_afrikaans]] and [[w:en:User:Jarekt/b ]]for more examples. As a result every box in {{Babel|BG-3|AF-1|ANI-3|VI|win|bot|CID|align=left}} {{#babel:BG-3|AF-1|ANI-3|VI|win|bot|CID}} would get rendered differently. 

In many cases the clash can be avoided if Babel extension would pay attention to capitalization. May be the ideal approach would be to use 3 step procedure:
1) treat lower case codes as language code, 
2) if the code uses any  capital letters than check if there is a match to existing template first
3) if no local template exist that matches the capitalization than convert the code to lower case and try matching to the language codes again.

In some cases the clashes can not be avoided since local templates commons:template:User bot or commons:template:User win use lower case and clash with Ho-Chunk and Bongo languages. However in those cases local template can be renamed to commons:template:User Bot or commons:template:User Win to keep them separate.
Comment 3 Robin Pepermans (SPQRobin) 2012-02-25 17:21:19 UTC
Fixed in r112402 (uses 3 steps as described in comment 2).

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


Navigation
Links