User:TedderBot/CurrentPruneBot

Objective
The Current and Current related templates are used to alert editors that articles that are connected to a current event and receiving so many edits in a short period of time that edit conflicts are likely, and that the information within the article may not be up-to-date. Unfortunately, some editors are unaware that the templates are not to be used simply to mark topics that happen to be in the news. Additionally, whether applied correctly or not, the templates sometimes remain in place well after the event when editing slows down to manageable levels.

At present, the way that forgotten Current and Current related templates get removed from articles is by editors going to the template's page, selecting "what links here" or Category:Current events, reviewing each article that the template is transcluded onto, and removing the template from those articles with few recent edits. This process is onerous and error-prone.

The CurrentPruneBot assists in the detection and removal of forgotten Current and Current related templates. It does this by regularly scanning for the template in article space, looking at the article history for the date and time of the last non-bot edit for each article with the template, and editing the article to remove the template if two or more hours have passed since the last non-bot edit. It leaves an edit message referring editors to the template's page and reminding editors that the template is to be used for articles experiencing rapid editing, not for marking topics that happen to be in the news.

Previous conversations

 * Template talk:Current
 * Bot requests/Archive 35

Features

 * Configuration:
 * Overall aging (no edits in past 2 hours)
 * Edit-warring backoff (don't remove if edited by TedderBot in past 24 hours)
 * List of current templates
 * (future) Aging for specific template (less than N edits in M time)

Plan

 * By someone who is not Tedder
 * ✅ Come up with a policy/guideline for the current templates that can be linked to in the summary. This might simply involve rewriting Template:Current.


 * By tedder
 * ✅ Scan WhatLinksHere for the template
 * ✅ Determine last edits, times
 * ✅ Does it meet the aging criteria?
 * ✅ If yes: remove template with editsummary: " Stale template removed by CurrentPruneBot, see guidelines for template use at TODO
 * edit summary: " remove stale current-event template, please see WP:CAFET. (bot edit) "
 * Log removal text and time at User:TedderBot/CurrentPruneBot/log?
 * Not logging, it can be seen in contribs.

Status

 * May 12 2010: census is up: /census. This runs hourly and shows what the bot sees ("M time").
 * May 15 2010: bot coded, committed to github. BRFA filed: Bots/Requests for approval/TedderBot 5.
 * May 20 2010: a trial was granted and was successful.
 * May 27 2010: bot was approved to run.