Wikipedia:Bots/Requests for approval/EarwigBot 17


 * 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.

EarwigBot 17
Operator:

Automatic or Manually assisted: Automatic, unsupervised

Programming language(s): Python

Source code available: from ~earwig/earwigbot: infoboxshipimagebot_run.py

Function overview: The bot will remove File:No Photo Available.svg from all transclusions of Infobox ship image.

Links to relevant discussions (where appropriate): Bot requests/Archive 35

Edit period(s): One time run.

Estimated number of pages affected: ~3,500

Exclusion compliant (Y/N): Y

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

Function details: See function overview. The bot will loop through all imagelinks to File:No Photo Available.svg (list obtained using a MySQL query), and will blank the Ship image parameter of Infobox ship image if that template happens to be on the page, and also happens to contain the image. &mdash; The Earwig   (talk)  22:05, 23 April 2010 (UTC)

Discussion
There sees to be a small amount of objection to this, although at TT:Infobox ship begin there seems to be support. Anyhow, surely with some clever template coding, we can come up with a template that can check if the image parameter is ]? And if so add it to the category. - Kingpin13 (talk) 06:45, 27 April 2010 (UTC)
 * Two things about that; for one, I'm pretty sure that the point of the BOTREQ (at least from my understanding of it) is to remove the image itself, not simply to ensure that all pages without images are categorized, so categorizing them would not fix the problem completely; and two, from my understanding of templates, any proposed fix would be very hackish and ugly, because it would need to account for,  ,  ,  , as well as any number of variations involving both the comment and the size – I have seen multiple versions in use as I was writing the bot, and there is no conceivable way for the template to account for all of them. &mdash;  The Earwig   (talk)  20:41, 27 April 2010 (UTC)
 * Curiously I just analysed the number of uses of various infoboxes in the last dump, Infobox ship image comes in around the 19000 mark. I would suggest you use a too to create lists of "what transculdes here" for the image template, and what links here for the image, and take the intersection. AWB can do this. It will speed the bot run considerably.   Rich Farmbrough, 05:20, 28 April 2010 (UTC).
 * I don't know about that. The significant majority of the imagelinks to pages in the mainspace for File:No Photo Available.svg are to pages using Infobox ship begin; I'm not sure if it will save me that much time at all, but I suppose I could implement it if you really think it is necessary. &mdash; The Earwig   (talk)  10:43, 28 April 2010 (UTC)
 * Hi, just wanted to add some background. The purpose of removing the  usage from articles where it is using the Infobox ship begin is because the template code has recently been updated to automatically add the page to Category:Ship infoboxes without an image which therefore makes the use of the image redundant. The BOTREQ was to remove the usage of the image so that the Category automatically picks up the requirement for an image to be added to the infobox/article rather than leaving it down to manual/human intervention to tag the article. JonEastham (talk) 12:42, 28 April 2010 (UTC)
 * BAGAssistanceNeeded I see. Note this recent comment; I think it is safe to proceed with a trial of sorts, and this has not had any real BAG attention for some time. Thanks. &mdash; The Earwig   (talk)  10:25, 30 April 2010 (UTC)

- Kingpin13 (talk) 05:13, 1 May 2010 (UTC)
 * &mdash; The Earwig   (talk)  06:56, 1 May 2010 (UTC)
 * Nice work. - Kingpin13 (talk) 07:07, 1 May 2010 (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.