Talk:Babel extension

From Meta, a Wikimedia project coordination wiki
Bugs ? Feature requests ? → BugZilla(?)
Questions/Support → mw:Extension:Babel

I think we should submit a bug to request to enable this extension. Currently it is waiting for final work and review (bug 15308) and there are some bug requests from several wikis to enable it there, but I think it's better to request it Wikimedia-wide (i.e. opt-out instead of opt-in). SPQRobin (talk) 19:19, 28 May 2011 (UTC)[reply]

Krinkle has submitted a bug request: bug 29647. SPQRobin (talk) 12:49, 30 June 2011 (UTC)[reply]

Deployment[edit]

Crosswiki[edit]

As can be read on bugzilla:29647 and Special:Version, Babel has been deployed.

We need to take of a few things though. Look here for an example.

  • On most wikis "Template:User xx" are existing templates
    • Problem: Babel recognizes them as matching MediaWiki:Babel-template and uses it. The layout and messages in these templates are likely not as up to date or localized as the ones in the extension. They should be deleted on most wikis.
  • One some wikis "Template:User xx" are redirects to a localized template naming format
  • On Meta-Wiki "Template:User xx" is marked deprecated
    • Causing weird effects like shown here here. On that page I used {{#babel:nl-N|en-3|de-3}} and some of them show "Deperacted, use {{user language}} instead".

So there's a few things I thought we should do

  • Get rid of the deprecation message on Meta-Wiki
  • Change {{Babel}} on all wikis to instead just call {{#babel:}}.

But then I thought again, and realize this is likely going to be a problem since users have custom templates like {{User toolserver}} which would no longer work in the extension, but do work with the wiki template. Many of the implementations of the Babel template also support things like custom colors etc. which users use to make these beautiful custom use page designs, we should not brake those. Alternative plan:

  • Instead of changing {{Babel}} on all wikis, let's instead write a bot that
    • changes the actual usages of these templates on user pages to use the extension. Making sure the bot skips user pages where it is called with values that are not valid language codes (such as "IRC" or "toolserver"). As well as calls where parameters like color=, align=, border=, style= etc. are used.
    • Check the usages of all "User $1" templates (where $1 is any of the valid language codes and levels) on the local wiki and make a list of those that are unused, save it to a wiki page, for a local admin to go through and (mass)delete if they want.
  • Then leave it up to the local community to decide whether they want to keep their template for custom usages or deprecate it and fix remaining usages.
  • Inform wikis that have this template on their wiki via their village pump offering to run this bot on their wiki.

I'm posting this here to gather feedback on how we can best approach this. –Krinkletalk 00:06, 22 September 2011 (UTC)[reply]

There seems to be an alignment problem with the templates within the Babel box. In this test on my Meta userpage they do not line up in a column, they spread horizontally and are truncated where they fall outside the box. (Cf. this problem I had previously with alignment of {{User language}} within {{Userboxtop}}.) Is there a way to make the templates align correctly in the Babel box and align as expected where they have been used separately at the same time? It will/would be nice when/if the templates worked consistently across all WM projects, but there is a ways to go before this happens. ~ Ningauble 14:26, 22 September 2011 (UTC)[reply]
Such a bot would be great! --UV 21:53, 23 September 2011 (UTC)[reply]
For what it's worth, here on Meta the 4th-level boxes also have a problem, they're displayed like on Translatewiki in contrast to other levels. Perhaps they're not coded specially yet? --Microcell 16:32, 22 September 2011 (UTC)[reply]
  • I think that most wikis will need #Header and footer to be fixed for a complete transition.
  • If you can remove header and footer, you can replace all usages with a bot without the user even noticing; otherwise, someone will certainly complain because you broke his userboxes and you didn't ask etc. A global bot for such a replacement will anyway face process obstacles, and even the local babel template is often protected and will need a local sysop (or [ab]use of steward bits). It's also difficult to find all usages, because there are different babel systems ({{Babel}}, {{Babel-x}} from the era when we didn't have parserfunctions, direct usage of the individual templates or different wrapping templates).
  • If you run a bot, instead of mass-deleting template or list them for mass-deletion (which the local users might not be able to do, and anyway clutters the logs), I suggest to redirect them to some template with a deprecation notice.
  • There's no need to delete the local templates for the extension to work: on it.quote I just put an unlikely template title in MediaWiki:babel-template so that none is found. This could probably be done by you, Krinkle, on all wikis (with a link to further instructions) so that local templates are used by the extension only if they know what they're doing. Nemo 17:28, 2 October 2011 (UTC)[reply]
  • Is it the final desicion to employ the layout from Translatewiki? To me, the Incubator design looks less rough and has more resemblance to what we've been using so far. I'd opt (personally) for the latter variant or at least ask the global community, which the change is going to concern, what is the optimal outcome on this point. --Microcell 15:01, 22 September 2011 (UTC)[reply]
    Is this a problem? Can't the layout be changed via local CSS? Nemo 17:28, 2 October 2011 (UTC)[reply]

Babel AutoCreate bot[edit]

Is User:Babel AutoCreate at en.qw and other wikis part of this deployment, or is a rogue? It is creating malformed (uncategorized) empty categories and it has been blocked on some wikis for contravening the policies governing bots. ~ Ningauble 14:53, 23 September 2011 (UTC)[reply]

Babel AutoCreate is part of the extension; its username is set by MediaWiki:babel-autocreate-user, and it creates categories based on MediaWiki:babel-autocreate-text-levels and MediaWiki:babel-autocreate-text-main. —Pathoschild 14:19:22, 25 September 2011 (UTC)
I sort of guessed that was the case. It seems to require a bit of customization to work correctly, which puts small wikis in a bit of a quandary. One can try to opt in by requesting developer customization, or one can try to muster a quorum to opt out, but the default is to have auto-generation of spurious and/or malformed category pages. If it makes very many more broken categories at my home wiki then I will just block the account. ~ Ningauble 17:19, 25 September 2011 (UTC)[reply]
Where the language-names can be modified? I've found some errors in Spanish that would love to fix. —Marco Aurelio (disputatio) 18:59, 27 September 2011 (UTC)[reply]
The translated language names come from mw:Extension:CLDR which gets its data from http://cldr.unicode.org/ It's quite difficult to get something fixed there, I once tried it for an error in a Dutch name but finally submitted a bug report there instead. SPQRobin (talk) 21:34, 27 September 2011 (UTC)[reply]

On Metawiki[edit]

These tasks need to be completed for the deployment on Metawiki:

Pathoschild 15:52:47, 01 October 2011 (UTC)

Categories are currently disabled on Meta because of our different system: what are we going to do? I'd try to stick to the current system but this requires bug 31311 to be fixed (or #babel to be used through templates). Nemo 17:28, 2 October 2011 (UTC)[reply]
The extension does not support some languages used on Meta: eur/Europanto (2 users), de-arz/Erzgebirgisch (2 users), de-hess/Hessian dialects (1 user). —Pathoschild 19:26:11, 18 October 2011 (UTC)

Header and footer[edit]

Is there a way to suppress the header and footer of the Babel box? If not, could we please have a parameter to switch them off? Thanks. ~ Ningauble 14:31, 22 September 2011 (UTC)[reply]

This is currently not supported. Feature requests and bug reports should be reported at bugzilla: (?). Questions and support can be asked at the extensions' talk page on mw:Extension:Babel at MediaWiki.org. –Krinkletalk 16:18, 24 September 2011 (UTC)[reply]
They can be hidden with CSS, either for an entire wiki (MediaWiki:Common.css) or per-user (User:username/common.css):
.mw-babel-header { display:none; }
.mw-babel-footer { display:none; }
There's no way to hide it for all users visiting your user page. —Pathoschild 14:24:34, 25 September 2011 (UTC)
I've filed bug 31309. Nemo 17:28, 2 October 2011 (UTC)[reply]
There actually is a way to display a standalone language templates using an HTML hack with <div class="babel-plain"> as described at User language#Custom layout. If a parameterized enhancement is not forthcoming at Bugzilla then it might be a good idea to templatize the hack locally as {{Babel-plain}}. ~ Ningauble 17:05, 3 October 2011 (UTC)[reply]
This only works on Meta, due to its custom CSS. I adjusted the page to clarify this. —Pathoschild 17:54:35, 03 October 2011 (UTC)

1.18 Problem?[edit]

Since the 1.18 deployment many things have gone wrong, see my test about Babel at the end of the page. Anything we should do on local page? --Bencmq 15:01, 6 October 2011 (UTC)[reply]

This problem happens when the first line of the user box code is a wiki table ({|). This can be fixed by pushing it onto the second line (see example fix). —Pathoschild 04:01:12, 22 October 2011 (UTC)