Wikipedia:Bots/Requests for approval/Erwin85Bot 8
- The following discussion is an archived debate. Please do not modify it. Subsequent comments should be made in a new section. The result of the discussion was Approved.
Operator: Erwin
Automatic or Manually Assisted: Automatic, unsupervised.
Programming Language(s): Python
Function Overview: Notify the creator and major contributors of an article that's been nominated for deletion.
Edit period(s): Daily
Already has a bot flag (Y/N): Y
Function Details: At 01:00 UTC retrieve Wikipedia:Articles for deletion/Log/<yesterday> and get all the AfD discussion pages. For each AfD get the article's title by looking for {{la|Title}}. For each article get the creator (via Wikipedia) and major contributors (> 5 non-minor edits, via Toolserver). Then for all these users check if they have been notified for their articles and if not, do so using User:Erwin/AfDNote.
Discussion
[edit]See Wikipedia:Bot_requests (permlink). The edits limit is of course arbitrary. I could also limit this to the X users with the most edits (> Y?) to the article. --Erwin (talk) 11:02, 22 May 2009 (UTC)[reply]
- If this bot notifies me that an article I created is going to be deleted... but I don't care about it, and I delete the notice from my talkpage... will the bot notify me again the next morning? – Quadell (talk) 13:45, 22 May 2009 (UTC)[reply]
- No, it won't treat AfD's twice. It would notify you of a new nomination though. --Erwin (talk) 17:19, 22 May 2009 (UTC)[reply]
- Great! How will it know? Does it keep its own list of who it notified? Or would it look at the edit history of my talk page? – Quadell (talk) 18:12, 22 May 2009 (UTC)[reply]
- It's a one time run for each day's AfD's. So today it would treat all pages at Wikipedia:Articles for deletion/Log/2009 May 21. Let's say you get a message which you remove. Tomorrow it will treat the pages at Wikipedia:Articles for deletion/Log/2009 May 22 and it wouldn't run into the same AfD again. If someone else notifies you and you remove the message before the end of the day you will get a new message. As I don't expect this to happen often it's probably not worth the effort to check the talk page history for each user. --Erwin (talk) 18:40, 22 May 2009 (UTC)[reply]
- Great! How will it know? Does it keep its own list of who it notified? Or would it look at the edit history of my talk page? – Quadell (talk) 18:12, 22 May 2009 (UTC)[reply]
- No, it won't treat AfD's twice. It would notify you of a new nomination though. --Erwin (talk) 17:19, 22 May 2009 (UTC)[reply]
Approved for trial (5 days). Please provide a link to the relevant contributions and/or diffs when the trial is complete. – Quadell (talk) 14:43, 24 May 2009 (UTC)[reply]
- Thanks. It's doing yesterday's AfD's now and will run at 01:00 UTC for the next four days. It messed up the article, AfD and nominator in some links, but that's been fixed. --Erwin (talk) 20:59, 24 May 2009 (UTC)[reply]
- Done. Since the last run I've updated the code to ignore closed AfD's and users who're already taking part in the AfD discussion. I might decide to include closed AfD's where the article was deleted though. --Erwin85 (talk) 08:35, 28 May 2009 (UTC)[reply]
- I don't think that would be useful. – Quadell (talk) 18:43, 29 May 2009 (UTC)[reply]
- Done. Since the last run I've updated the code to ignore closed AfD's and users who're already taking part in the AfD discussion. I might decide to include closed AfD's where the article was deleted though. --Erwin85 (talk) 08:35, 28 May 2009 (UTC)[reply]
Looking through the bot contribs, I'm confused. Here you notified User:ShootinPutin109 about the nomination of Cecil Anthony Ince for deletion. But in the history, it looks like all ShootinPutin109 did in the article was to add {{nofootnotes}}
with Friendly. Shouldn't User:Cecilince have been notified instead? – Quadell (talk) 18:43, 29 May 2009 (UTC)[reply]
- Cecilince wasn't notified because a link to the AfD was found on the talk page. However, I'm not sure why ShootinPutin109 was notified. Have you come across a similar case? --Erwin (talk) 20:06, 3 June 2009 (UTC)[reply]
- The query I use is:
SELECT rev_user_text
FROM enwiki_p.revision
LEFT JOIN enwiki_p.page
ON page_id = rev_page
WHERE page_namespace = %s
AND page_title = %s
AND rev_timestamp < %s
AND rev_minor_edit = 0
GROUP BY rev_user_text
HAVING COUNT(1) > 5;
- where the arguments are the namespace number, page title and timestamp of the AfD. --Erwin (talk) 20:08, 3 June 2009 (UTC)[reply]
Looking through the contribs, I can't find any others like the ShootinPutin incident. Can you find out why your bot notified him, or if it would do so again? I also found two possible discrepancies:
- User talk:Superpipeman was notified about MacTalla Mor, even though he'd been previously notified.
- User talk:AntonioMartin was not notified about List of fatalities from aviation incidents, even though he created the article.
Are these features or bugs? :) – Quadell (talk) 15:01, 4 June 2009 (UTC)[reply]
- For the record: my bot made a run last night because I was trying to find another ShootinPutin incident in debug mode and hadn't removed the job from cron. I figured the error could be in getting the history, but I couldn't simply check cause the page was deleted. However, the AntonioMartin case the problem. I checked the log and my bot thinks someone else created the article. (I added this to the log cause of the ShootinPutin case.) Apparently there was a bug in pywikipedia that caused it not to get the first versions if the total number of versions exceeded 500. Anyway, I've fixed that in r6937.
- Superpipeman was notified because the link to the AfD looks like [[Wikipedia:Articles for deletion/{{str trim|MacTalla Mor}}]]. Is it common for that template not to be substituted? If so I can have my bot recognize it. --Erwin (talk) 20:21, 4 June 2009 (UTC)[reply]
- I don't know, but it couldn't hurt to check for this. – Quadell (talk) 13:19, 8 June 2009 (UTC)[reply]
This task's edits are very difficult to check, since the bot is very active in performing other tasks as well. I believe I'm the only person to have gone through any of the diffs on this task, and I only went through a dozen, but I found three separate bugs: the ShootinPutin bug (not fixed), the Superpipeman subst bug (pending), and the AntonioMartin bug (fixed). Please go through the bot's edits and look for any remaining bugs. – Quadell (talk) 13:19, 8 June 2009 (UTC)[reply]
- Will do as soon as I find some time. The ShootinPutin bug is the same as the AntonioMartin one though. --Erwin (talk) 20:03, 10 June 2009 (UTC)[reply]
How's this coming? – Quadell (talk) 13:08, 25 June 2009 (UTC)[reply]
- I haven't found the time yet, so I'm planning to simply do a new run (w/o editing) and check those results. --Erwin (talk) 19:06, 1 July 2009 (UTC)[reply]
- I let my bot treat yesterday's list just now and found no errors. The history bug (both ShootinPutin and AntonioMartin) was a bug in pywikipedia which I fixed before and I fixed the Superpipeman one today by just checking the database for links from user talk pages to the relevant AfD page. That way it doesn't rely on the ability to parse templates. --Erwin (talk) 11:17, 5 July 2009 (UTC)[reply]
- I haven't found the time yet, so I'm planning to simply do a new run (w/o editing) and check those results. --Erwin (talk) 19:06, 1 July 2009 (UTC)[reply]
- I think I am ready to approve this, is there anything I am missing? MBisanz talk 22:05, 18 July 2009 (UTC)[reply]
- All known bugs are fixed. If you're indeed missing something then we both are. --Erwin (talk) 06:59, 19 July 2009 (UTC)[reply]
- Q: Is this opt-in? If not, are there specific opt-out flags? –Whitehorse1 07:05, 19 July 2009 (UTC)[reply]
- Approving. MBisanz talk 19:20, 23 July 2009 (UTC)[reply]
- The above discussion is preserved as an archive of the debate. Please do not modify it. Subsequent comments should be made in a new section.