Wikipedia:Bots/Requests for approval/EarwigBot 13


 * 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 13
Operator:

Automatic or Manually assisted: Automatic, supervised

Programming language(s): Python

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

Function overview: The bot goes through transclusions of Infobox person that have upscaled portraits, shrinking the image so that it is at its native resolution and there is no size distortion.

Links to relevant discussions (where appropriate): Bot requests/Archive 35 and Template talk:Infobox person

Edit period(s): One time initially, possible subsequent runs months later.

Estimated number of pages affected: Details soon. I originally calculated ~800 edits, but this is now inaccurate as the code has been changed.

Exclusion compliant (Y/N): Y

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

Function details: As stated in the function overview, the bot will go through pages like Paul Morrissey and Charles Whitman, where the portrait in the infobox is upscaled so that it causes an ugly distortion effect. It will correct the problem by shrinking the image so that it is at its native resolution; examples of what the bot would do here, here, and here. The correction is done by altering the image_size parameter; either replacing the value with another if it is too high, or specifying the parameter if it is unspecified (and thus the image size defaults to 225 pixels, which is too high in some cases).

I'm still not quite sure about the exact implementation. It's currently coded to fix the size in the live article, the only exception being if the correct size is within five pixels of the current one. I could always change this to a bot that tags the page with a template of some sort, without changing the size itself. I could also have the bot log all problems to a subpage. I was hoping we could work out exactly how this will be done here. &mdash; The Earwig   (talk)  01:56, 29 March 2010 (UTC)

Discussion
Serves a useful function and is non-controversial. I will approve for trial run in seven days if there are no objections. harej 02:10, 29 March 2010 (UTC)
 * Josh Parris 12:02, 10 April 2010 (UTC)
 * Sorry for the delay on this. I'll try to get to it in a day or so. &mdash; The Earwig   (talk)  20:01, 12 April 2010 (UTC)
 * Starting on this in an hour or so. &mdash; The Earwig   (talk)  21:06, 16 April 2010 (UTC)
 * Hold on. I was testing something, and accidentally let this slip through. It doesn't look like it's actually doing anything. Is it really necessary to process the page if the image size is not specified? &mdash; The Earwig   (talk)  01:54, 17 April 2010 (UTC)
 * I was actually hoping for some input on this... &mdash; The Earwig   (talk)  22:45, 25 April 2010 (UTC)
 * Better set the size. Some weird browsers may not like unspecified things. -- Magioladitis (talk) 23:06, 25 April 2010 (UTC)
 * Very well then; upon closer inspection, the edit above actually did have an effect! *slaps self* I will run the bot as designed; the trial should be done pretty soon. Thanks! &mdash; The Earwig   (talk)  20:17, 26 April 2010 (UTC)

I'm pretty pleased with the results. No glaring issues or bugs, and the edits appear to be doing their job. A portion of them were only slight changes to image sizes; I don't have a problem with this, because even though the oversizing is slight, it still needs to be fixed. I did notice this mid-trial, which is slightly worrying, and I tried to contact the editor about it, but I have not yet received a reply. &mdash; The Earwig   (talk)  21:34, 26 April 2010 (UTC)


 * this edit isn't in keeping with the style of the template usage on that page. Nor is this one.  Thoughts? Josh Parris 13:55, 4 May 2010 (UTC)


 * Yep, I noticed those too. I didn't expect such a style to be used by the template, and the bot didn't expect it either... so it didn't know how to break the line properly (it did format it correctly though – it's the break that's problematic). I'm not sure what to do about it... it's not as if the error is major, but it is annoying. Do you think I should have the bot specifically check for those types of styles in the template (which will require more work, yet is still possible) and then place the template correctly, or is it even worth it? ~7.1% of the edits in the trial had that problem. &mdash; The Earwig   (talk)  19:56, 4 May 2010 (UTC)
 * I'd certainly encourage you to make the bot as unobtrusive as possible; you might, as a stop-gap measure, detect the non-standard format and skip it; it could be re-processed once the code is tweaked to allow for this formatting. I'm sure you're aware of how sensitive some editors are about formatting issues such as this.
 * You've suggested the estimated number of edits is now wrong; do you have a more up-to-date figure? Josh Parris 03:01, 5 May 2010 (UTC)


 * Good point, I'll implement a catch to look for such a formatting. I'm really not that sure of the correct number of edits... I have some difficulty calculating it without going through a large number of pages (and I'd rather not). However, if I had to make a guesstimate, it's probably somewhere between 1000 and 2000 in total. Thanks. &mdash; The Earwig   (talk)  20:12, 6 May 2010 (UTC)

Josh Parris 09:35, 7 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.