Commons:Bots/Requests/SamoaBot

From Wikimedia Commons, the free media repository
Jump to: navigation, search

SamoaBot (talk · contribs)

Operator: Ricordisamoa (talk · contributions · Number of edits · recent activity · block log · User rights log · uploads · Global account information)

Bot's tasks for which permission is being sought: Add the "wallpaper" parameter to {{Assessments}} if the image is suitable for that purpose (based on the image's width and height)

Automatic or manually assisted: Automatic, supervised

Edit type (e.g. Continuous, daily, one time run): intermittently, at operator's discretion

Maximum edit rate (eg edits per minute): 3 edits/minute

Bot flag requested: (Y/N): Y

Programming language(s): JavaScript (with Ajax, own code)

Ricordisamoa 10:39, 17 March 2013 (UTC)

Discussion

Done 22 test edits. --Ricordisamoa 12:18, 17 March 2013 (UTC)
Seems OK for me. --EugeneZelenko (talk) 14:45, 17 March 2013 (UTC)
Are you only looking for 4:3 images or widescreen wallpapers as well? What is the criterion for selecting an image, is there a tolerance, if so how high? Could you please link to the source? --Dschwen (talk) 19:58, 18 March 2013 (UTC)
  • I programmed it also for widescreen wallpapers, but at the moment it doesn't seem to have ever added "wallpaper=2";
  • If the image is at least 1024×768, it checks the aspect ratio: exactly 4:3 or 5:4 for normal wallpaper, 16:9 or 16:10 or 8:5 for widescreen;
  • User:Ricordisamoa/FPwallpaper.js is the source. --Ricordisamoa 00:49, 19 March 2013 (UTC)
I am still waiting for a response. --Ricordisamoa 18:54, 25 March 2013 (UTC)
I looked at the images where the test edits were done. They all were large enough and had a 4:3 or 5:4 aspect ratio, so I agree with EugeneZelenko that what the bot has done is correct. It would be nice, though, if the wide-screen images were classified too.
Also it strikes me that if someone has a screen with a 4:3 aspect ratio, images with a 5:4 aspect ratio won't fit it exactly, but for {{Assessments}} these are both classified as wallpaper=1. An image with, say, an aspect ratio of 13:10, which is between 4:3 and 5:4, would be counted as unsuitable. Perhaps four distinct values would be better in the template, rather than two. I found Category:Images - aspect ratio 4:3 which only has 23 files in it. Would it be desirable to add categories like that? The message generated by the template says "has an aspect ratio of approximately 4:3 or 5:4" whereas this script more conservatively identifies images with exactly one of those aspect ratios. It seems fine. Rybec (talk) 01:02, 31 March 2013 (UTC)

If there are no objections, I think bot status should be granted. --EugeneZelenko (talk) 14:36, 2 April 2013 (UTC)