Last modified: 2012-11-14 12:22:51 UTC
Current behavior: When trying to view a page by entering an invalid language code in the "uselang=" parameter, the wiki fallbacks to English. Desired behavior: When trying to view a page by entering an invalid language code in the "uselang=" parameter, the wiki fallbacks to the default language set for the wiki. Example to illustrate (see URL): In the French (fr) Wikipedia, when trying to view recent changes by entering abc as a language code (there is no language whose code is abc), the wiki fallbacks to English. In fact it should fallback to French (default language in wiki).
Created attachment 4652 [details] Fixes the mentioned bug This patch allows trying to fall back to the content language, before an effort to falling back to 'en'. I'm not applying it, because I both need it to be reviewed, and think acceptance of some more experienced developers is needed about such a change in the behaviour of wiki software.
Marking for review. Also, I want to credit Alexandre Emsenhuber (ialex) for his helping me finding where to fix. :)
Created attachment 4653 [details] other version other patch to fix that bug, does not throw an exception when the content language code is invalid.
Fixed in r31022
VasillievVV, The reason we didn't apply the second patch was that it didn't include the error logging features which were available in the first patch, although it was more straightforward. I didn't get the time to make a third patch which combines the two. I guess I'm going to add the debugging features right to the code, if you don't do it sooner than me.
Reverted, breaks Commons. <http://commons.wikimedia.org/w/index.php?title=Commons:Administrators%27_noticeboard&diff=10098444&oldid=10097694>
I see no good motivation for this change, and the commons would need a alternative way for their hack for this be changed.
I just checked with Krinkle; the patch had nothing wrong -- Commons is the one using uselang in a nonstandard way. The best approach would be to implement a different setup for the Special:Upload customization, but since the new uploader is coming around, we just need to wait until the current one is superseded and then this patch can be safely applied. I'm marking the bug as "fix later" rather than "wontfix".
Has LATER arrived?
(In reply to comment #9) > Has LATER arrived? I suppose... is the new uploader the default for everyone in Commons now? I know I got it last time I uploaded a file.
(In reply to comment #10) > (In reply to comment #9) > > Has LATER arrived? > > I suppose... is the new uploader the default for everyone in Commons now? I > know I got it last time I uploaded a file. This doesn't seem enough for the old system to be dropped. There's still no way to get the same customisation on wiki.
Switching from LATER to the second most relevant resolution for fear of information loss. http://article.gmane.org/gmane.science.linguistics.wikipedia.technical/65116