Last modified: 2014-08-27 13:51:19 UTC
I encountered many times now on wikis (usually the small wikis) that there are 100s of local MediaWiki pages with translations from before translatewiki.net covered that language. And even after twn covered it, there may have been local improvements that over time make it into twn, but then the local page stales. To avoid translations from going out of sync (the longer we wait with this, the harder it is to clean them up as the difference between an override and an outdated translation becomes harder to tell), and also to avoid migration issues when messages change. Lets run this asap.
This is a subset of the general task "clean-up local messages". What we have now: [[mw:Localisation#Old_local_translation_system]] https://toolserver.org/~robin/?tool=cleanuplocalmsgs
Can the old [[User:MediaWiki default]] be used for this task? (Please note that since it does not run since 2006 it has been deflagged from the bot group from some projects). I understand this is going to affect messages pre-betawiki. However I wonder what would happen with messages that we decided to customize localy. Those should not be deleted as they're likely going to be recreated later... Only a minor issue, though.
(In reply to comment #2) > Can the old [[User:MediaWiki default]] be used for this task? The script I wrote uses that user and ensures it is in the bot group (that is, add if not present) before it runs. (In reply to comment #2) > I understand this is going to affect messages pre-betawiki. No, it is not. (In reply to comment #2) > However I what would happen with messages that we decided to customize Nothing.
See bug 43915.
Any progress on running this?
I could run it, but I'd like to not execute my own request without a little more consensus from people. They aren't permanent or hidden actions in any way (regular wiki deletions, it's a bot basically), but they would be a horror to undo. I wouldn't know why someone would disagree, but then again, there've only been a few people involved so far that all agreed.
(In reply to comment #6) > I could run it, but I'd like to not execute my own request without a little > more consensus from people. > > They aren't permanent or hidden actions in any way (regular wiki deletions, > it's a bot basically), but they would be a horror to undo. > Can you dry run it and make a list of the pages that will be deleted so they can be reviewed before deletion?
(In reply to comment #7) > (In reply to comment #6) > > I could run it, but I'd like to not execute my own request without a little > > more consensus from people. > > > > They aren't permanent or hidden actions in any way (regular wiki deletions, > > it's a bot basically), but they would be a horror to undo. > > > > Can you dry run it and make a list of the pages that will be deleted so they > can be reviewed before deletion? I'm not sure what there is to review regarding individual pages. They all follow the same description, whatever reasoning one would use about them doesn't specify for any particular page: Pages in the MediaWiki namespace that exist and override a system message of which the wiki page contents are equal to the system message of the site language (in other words, there is no longer a reason fo the override page to exist). Deleting these pages has no visible effect as the effective value of the interface message will still be the same. The advantage is saving maintenance work later on by not having to update these messages when the software upgrades, and for consistency across wikis. A common scenario is the following: * 3 wikis in language x * 1 of the wikis overrides a message (making an improvement) * the message is fixed in translatewiki * the message update is deployed * users of all 800 wikis using language x now see the new version of the message * another update is made to the message and deployed * all wikis use it, except the wiki where the first change came from which is now out of sync without it being intentionally so. Alright, I'm biased as it was my own idea. But that doesn't mean the script itself has to be controversial. I'll run this next week if no objections are raised before then.
Related URL: https://gerrit.wikimedia.org/r/62159 (Gerrit Change I2680413c276365a44c935a6f6fdd740daa86341e)
Related URL: https://gerrit.wikimedia.org/r/64991 (Gerrit Change I2680413c276365a44c935a6f6fdd740daa86341e)
(In reply to comment #10) > Related URL: https://gerrit.wikimedia.org/r/64991 (Gerrit Change > I2680413c276365a44c935a6f6fdd740daa86341e) Merged a month ago. Given bug 14176 (bug 49793), the script should also delete blank messages and be run as soon as possible; unless a separate script is prepared and run for that only.
(In reply to comment #11) > (In reply to comment #10) > > Related URL: https://gerrit.wikimedia.org/r/64991 (Gerrit Change > > I2680413c276365a44c935a6f6fdd740daa86341e) > > Merged a month ago. > > Given bug 14176 (bug 49793), the script should also delete blank messages and > be run as soon as possible; unless a separate script is prepared and run for > that only. Since blank messages no longer mean showing the default, deleting them seems inappropriate. Yes, there are likely some pages out there that are blank and currently causing bugs due the message being empty instead of the default. However it would be a mistake to unconditionally delete all blank pages in the MediaWiki namespace. For maintenance scripts like deleteEqualMessages it is important that they do not affect the interface. It should only delete things that are non-controversial. If a script to delete empty messages existed in the past, we could've run it once globally after we reverted the feature to have blank messages mean default. But it has been to long to do this now. And one could also argue that it was dangerous even then because there might be existing pages that are blank for other reasons.
(In reply to comment #12) > If a script to delete empty messages existed in the past, we could've run it > once globally after we reverted the feature to have blank messages mean > default. But it has been to long to do this now. What do you mean too long? It's been today for Wikipedias (1.22wmf7). Blank message has always meant "equal to default", so it doesn't seem out of scope for the script, which should be run by third parties before upgrading to MediaWiki 1.22. If you consider it out of scope I'd file a bug for another script to be created, but nobody would be working on it so it would become too late so I'll just add a warning on [[MediaWiki 1.22]] and let sysops sort it out manually.
(In reply to comment #13) > (In reply to comment #12) >> If a script to delete empty messages existed in the past, we could've run it >> once globally after we reverted the feature to have blank messages mean >> default. But it has been to long to do this now. > > What do you mean too long? It's been today for Wikipedias (1.22wmf7). Blank > message has always meant "equal to default", so it doesn't seem out of scope > for the script, which should be run by third parties before upgrading to > MediaWiki 1.22. Not always. The behavior has switched a few times now. There's no good answer here. It's impossible to determine intent simply by page_len being equal to 0. I tend to agree with Krinkle that it's better to be cautious here. Even the "redundant" messages getting deleted makes me a little sad, given how useful some of that page history can be (including being linked from active bug reports). But I understand that it's better future-proofing. Alas. > [...] [[MediaWiki 1.22]] [...] You mean [[mw:MediaWiki 1.22]], of course.
I've run this on a single wiki where I'm also a local sysop (nlwiki) and noticed the script has a minor flaw. It incorrectly deleted MediaWiki:Sitenotice (if it is empty), which is undesirable. So we should probably change the script to make an exception for empty messages. Those are most unlikely to change anyway because there is no message content to update or change, it is empty.
> Even the "redundant" messages getting deleted makes me a little sad, given > how useful some of that page history can be (including being linked from active > bug reports). But I understand that it's better future-proofing. Alas. I remember blanking some MediaWiki messages precisely to use the default but keep the history. Maybe the script should edit the messages to whatever is used now to mean "use the default" ("-" ?) when there are several edits to the page.
(In reply to comment #15) > I've run this on a single wiki where I'm also a local sysop (nlwiki) and > noticed the script has a minor flaw. > > It incorrectly deleted MediaWiki:Sitenotice. Fixed in I5b416cda25a3641862df9919c46ae59ad5d5d6e0.
(In reply to comment #16) > > Even the "redundant" messages getting deleted makes me a little sad, given > > how useful some of that page history can be (including being linked from active > > bug reports). But I understand that it's better future-proofing. Alas. > > I remember blanking some MediaWiki messages precisely to use the default but > keep the history. > Maybe the script should edit the messages to whatever is used now to mean > "use > the default" ("-" ?) when there are several edits to the page. Sometimes '', sometimes '-' (handled by Message:isBlank and Message::isDisabled) however those are not generic APIs. The message system does not use these methods. They are available for local code to use if they want to. So there's no way of knowing whether an individual message "supports" that behaviour, and even then we currently have some use '' and some use '-' ('' is a safe bet for both).
I'm confused by comment #12 and #13 then, I understood from them that '' no longer meant default.
Blanking a message no longer disables it (bug 14176), so all pre-12.06.2013 blankings should be transformed in deletions.
The short version of the long story (that is partially outlined in previous comments by all of you) is that it: * Was never consistent to be begin with. * It has changed over time. So we can't reliably know now what to do with a message. You'd have to account for deployment dates for different wikis and assume a community member intentionally left a message override untouched knowing the new behaviour. More likely it was forgotten about and is actually still assuming the old logic. * It can vary by message whether it is blankable or disableable. If the code calls isBlank first (like Sitenotice) then it can be blanked with '' without leaving a gap in the interface because the feature checks it first. If the code calls isDisabled first, and then falls back or something, then it can be blanked with '' or '-' and it will use the default. However by far the default behaviour for the majority of messages is that if you create a local page, it replaces the message with that page. And if you put '' or '-' in it, it will appear as a gap in the interface. Either way, those pages are there with empty content for a reason, so it doesn't make sense to delete them en mass as part of this maintenance script.
Krinkle, are you still planning to work on this?
This was requested to be run on wuuwiki: https://meta.wikimedia.org/w/index.php?title=Steward_requests/Miscellaneous&oldid=7913568#Remove_useless_system_messages_on_wuu_wikipedia
Done! $ mwscript deleteEqualMessages.php --wiki wuuwiki --delete Checking for pages with default message... ... fetching message info for content language 352 pages in the MediaWiki namespace override messages. 110 pages are equal to the default message (+ 0 talk pages). ...deleting equal messages (this may take a long time!)... * [[MediaWiki:Sitematrix]] * [[MediaWiki:Cite]] * [[MediaWiki:Searchfulltext]] * [[MediaWiki:Createarticle]] * [[MediaWiki:Categorytree-mode-categories]] * [[MediaWiki:Categorytree-expand]] * [[MediaWiki:Categorytree-no-pages]] * [[MediaWiki:Sitesupport]] * [[MediaWiki:Fri]] * [[MediaWiki:January-gen]] * [[MediaWiki:March-gen]] * [[MediaWiki:May-gen]] * [[MediaWiki:September-gen]] * [[MediaWiki:October-gen]] * [[MediaWiki:November-gen]] * [[MediaWiki:Mypage]] * [[MediaWiki:History short]] * [[MediaWiki:Print]] * [[MediaWiki:Mainpage]] * [[MediaWiki:Nstab-template]] * [[MediaWiki:Logout]] * [[MediaWiki:Userlogout]] * [[MediaWiki:Notloggedin]] * [[MediaWiki:Loginerror]] * [[MediaWiki:Loginsuccesstitle]] * [[MediaWiki:Wrongpassword]] * [[MediaWiki:Bold sample]] * [[MediaWiki:Bold tip]] * [[MediaWiki:Savearticle]] * [[MediaWiki:Loginreqtitle]] * [[MediaWiki:Loginreqlink]] * [[MediaWiki:Yourdiff]] * [[MediaWiki:Nohistory]] * [[MediaWiki:Nextrevision]] * [[MediaWiki:Rev-delundel]] * [[MediaWiki:Prevn]] * [[MediaWiki:Prefs-personal]] * [[MediaWiki:Prefs-rc]] * [[MediaWiki:Prefs-watchlist]] * [[MediaWiki:Prefs-watchlist-days]] * [[MediaWiki:Prefs-watchlist-edits]] * [[MediaWiki:Saveprefs]] * [[MediaWiki:Searchresultshead]] * [[MediaWiki:Savedprefs]] * [[MediaWiki:Yourlanguage]] * [[MediaWiki:Badsig]] * [[MediaWiki:Userrights-user-editname]] * [[MediaWiki:Rclistfrom]] * [[MediaWiki:Diff]] * [[MediaWiki:Hist]] * [[MediaWiki:Show]] * [[MediaWiki:Minoreditletter]] * [[MediaWiki:Newpageletter]] * [[MediaWiki:Uploadbtn]] * [[MediaWiki:Uploadnologin]] * [[MediaWiki:Uploaderror]] * [[MediaWiki:Uploadlog]] * [[MediaWiki:Uploadlogpagetext]] * [[MediaWiki:Filedesc]] * [[MediaWiki:Uploadedfiles]] * [[MediaWiki:Uploadwarning]] * [[MediaWiki:Savefile]] * [[MediaWiki:Destfilename]] * [[MediaWiki:Uploadnewversion-linktext]] * [[MediaWiki:Download]] * [[MediaWiki:Listredirects]] * [[MediaWiki:Randompage]] * [[MediaWiki:Statistics]] * [[MediaWiki:Brokenredirects]] * [[MediaWiki:Popularpages]] * [[MediaWiki:Mostlinked]] * [[MediaWiki:Mostlinkedcategories]] * [[MediaWiki:Mostimages]] * [[MediaWiki:Shortpages]] * [[MediaWiki:Longpages]] * [[MediaWiki:Listusers]] * [[MediaWiki:Newpages-username]] * [[MediaWiki:Log]] * [[MediaWiki:Emailsend]] * [[MediaWiki:Emailsent]] * [[MediaWiki:Emailsenttext]] * [[MediaWiki:Watchthispage]] * [[MediaWiki:Unwatchthispage]] * [[MediaWiki:Created]] * [[MediaWiki:Confirm]] * [[MediaWiki:Deletionlog]] * [[MediaWiki:Rollback]] * [[MediaWiki:Rollback short]] * [[MediaWiki:Rollbackfailed]] * [[MediaWiki:Protectlogpage]] * [[MediaWiki:Restriction-edit]] * [[MediaWiki:Restriction-move]] * [[MediaWiki:Undeletepage]] * [[MediaWiki:Mycontris]] * [[MediaWiki:Blocklink]] * [[MediaWiki:Blocklogpage]] * [[MediaWiki:Movepagebtn]] * [[MediaWiki:Cantmove-titleprotected]] * [[MediaWiki:Thumbnail-more]] * [[MediaWiki:Newimages]] * [[MediaWiki:Variantname-zh-tw]] * [[MediaWiki:Watchlistall2]] * [[MediaWiki:Namespacesall]] * [[MediaWiki:Descending abbrev]] * [[MediaWiki:Table pager next]] * [[MediaWiki:Table pager prev]] * [[MediaWiki:Table pager first]] * [[MediaWiki:Table pager limit]] * [[MediaWiki:Autoredircomment]] * [[MediaWiki:Version]] done!
Ran mwscript deleteEqualMessages.php --delete --delete-talk on the following wikis: * afwiki * amwiki * brwiki * euwiktionary * gvwiki * hrwiki * hrwiktionary * iawiki * miwiki * mlwiki
Thanks! I'd suggest to avoid touching talk pages, so that the operation is truly no-op. Those talk pages are unlikely to exist but wikis have different policies on the matter.
(In reply to Nemo from comment #26) > Thanks! I'd suggest to avoid touching talk pages, so that the operation is > truly no-op. Those talk pages are unlikely to exist but wikis have different > policies on the matter. Good point. We have orphan tools to detect those and are indeed not always trivial/uncontroversial. Will keep them from now on.
Spread over the past two weeks, mwscript deleteEqualMessages.php was ran[1] on the following wikis while performing other routine maintenance and interface fixes: abwiki afwiki afwikiquote alswiki bat-smgwiki bpywiki cswiki cswikiversity cswiktionary cvwiki lnwiki nahwiktionary newwiki nlwiki rowiktionary simplewiki sqwiki suwiki tlwiki [1] https://wikitech.wikimedia.org/wiki/Server_admin_log
Ran for commonswiki per my own request there as sysop (could've deleted them by hand): > 279 pages in the MediaWiki namespace override messages. > 1 pages are equal to the default message (+ 0 talk pages). > > List: > * [[MediaWiki:Visualeditor-ca-editsource]]