Wikipedia:Bots/Requests for approval/AnomieBOT 52


 * The following discussion is an archived debate. Please do not modify it. To request review of this BRFA, please start a new section at WT:BRFA. The result of the discussion was Symbol keep vote.svg Approved

AnomieBOT 52
Operator: Anomie⚔

Time filed: 19:17, Friday August 26, 2011 (UTC)

Automatic or Manual: Automatic, unsupervised

Programming language(s): Perl

Source code available: User:AnomieBOT/source/tasks/FlagIconRemover.pm

Function overview: Remove flag icons from infoboxes or other layout templates, where consensus exists that the template should not contain flag icons.

Links to relevant discussions (where appropriate): User talk:AnomieBOT/Archive 3, Template talk:Infobox company, Template talk:Infobox power station, WT:MOSFLAG, Template talk:Infobox World Heritage Site, Template talk:Infobox World Heritage Site, WP:MOSFLAG

Edit period(s): Periodic

Estimated number of pages affected: There are currently 7248 articles transcluding both one of the target infoboxes and a flag template. Not all of these will actually be edited, for example Eolica Mihai Viteazu Wind Farm contains both an infobox and a flag template but the flag template is not in the infobox. If additional templates are added, that would increase the number of pages to be affected.

Exclusion compliant (Y/N): Yes

Already has a bot flag (Y/N): Yes

Function details: The bot will do the following:
 * 1) Get a list of articles that transclude both one of its target templates and any of the templates in Category:Flag templates or Category:Flag template system.
 * 2) Load the text of each article.
 * 3) Go through all the parameters of the target infoboxes in the text.
 * 4) Use   to obtain the wikitext of any flag template invocations found, and replace the flag template invocation with this wikitext minus any flag icon images.

Discussion
Just to be 100% clear, this will not remove flag icons arbitrarily. It will only remove flag icons within the parameters of certain specific infoboxes or other layout templates. At the moment, the target templates are Infobox company, Infobox power station, and Infobox World Heritage Site. If discussions show consensus for this same task to be done for more infoboxes or other layout templates, those may be added to the list.

What I am calling a "layout template" is a template that displays structured data, even if it isn't technically an infobox. For example, Video game table would be a layout template. I don't know if there are any that will want this treatment, but if one comes up it would be nice to be able to handle it.

There may be cases where consensus determines that WP:IAR applies to the general rule to not use flag icons in these templates. I'm open to suggestions on how to handle this; options I see are adding a comment such as  next to the flag template (simple but difficult to search for); adding a dummy parameter to the flag template invocation, e.g.  (somewhat cryptic, possible to search for if someone adds a tracking category to the template); or adding another template such as keep flag per consensus next to the flag template (a whole extra template, but easily tracked using Special:WhatLinksHere). Anomie⚔ 19:17, 26 August 2011 (UTC)

Discussions suggest consenus for this. Also, I prefer method. — HELL KNOWZ  ▎TALK 14:01, 28 August 2011 (UTC)
 * Also, a sandbox edit to test yes. Anomie⚔ 23:44, 28 August 2011 (UTC)


 * Edits seem good. Will leave open for a little longer to gather some feedback/input may be. — HELL KNOWZ  ▎TALK 07:17, 29 August 2011 (UTC)
 * Looks good to me too, maybe the edit summary could be a bit shorter. --Elekhh (talk) 01:02, 4 September 2011 (UTC)
 * I'm open to suggestions, but do keep in mind this recent discussion. Anomie⚔ 01:32, 4 September 2011 (UTC)
 * I see, and agree it should stay as informative as is. I was thinking that maybe the the instructions for the exceptional IAR cases could be simply linked to (for instance to this page per Sven's suggestion), rather then repeating it in each edit summary. Is so much nicer when an edit summary fits into one line. It is a minor thing though which should not defer the implementation. --Elekhh (talk) 01:53, 4 September 2011 (UTC)
 * After some reflection, I've decided to take your suggestion. Except I'll create User:AnomieBOT/docs/FlagIconRemover instead of linking to fragmented discussions. Anomie⚔ 00:14, 12 September 2011 (UTC)

BAGAssistanceNeeded It seems no one cared enough to comment on the removals. Shall we proceed? Anomie⚔ 00:14, 12 September 2011 (UTC)

All appears to be in order, no further core task related comments were made after the trial. Trusted bot-op, task follows only consensus discussions. — HELL KNOWZ  ▎TALK 08:07, 12 September 2011 (UTC)


 * The above discussion is preserved as an archive of the debate. Please do not modify it. To request review of this BRFA, please start a new section at WT:BRFA.