Wikipedia:Bots/Requests for approval/Bot1058 4


 * 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

Bot1058 4
Operator:

Time filed: 00:20, Monday, November 20, 2017 (UTC)

Automatic, Supervised, or Manual: Automatic

Programming language(s): PHP

Source code available:

Function overview: Sync unsynchronized disambiguation talk page redirects

Links to relevant discussions (where appropriate): Template talk:R from incomplete disambiguation

Edit period(s): One time big run, followed by periodic smaller runs as needed

Estimated number of pages affected: ~1,800 pages on initial run

Namespace(s): Talk

Exclusion compliant (Yes/No): No

Function details: This task is the cousin of Bot1058's task 3. That was done with AWB, but for this one I wrote a simple PHP program. The typical scenario goes like this... a parenthetically disambiguated title is created for a film, book or album, etc., for example Homework (film) disambiguates from Homework. That works fine until a second film is made with the same title. Then the first film is moved to a fully disambiguated title – Talk:Homework (film) moved to Talk:Homework (1989 film): to disambiguate against Homework (2011 film). Homework (film) is then redirected to Homework (disambiguation), but the talk redirect is often left unchanged, rendering it an "unsynchronized disambiguation talk page redirect". This bot's task is to re-sync these redirects by redirecting Talk:Homework (film) to Talk:Homework (disambiguation), if Talk:Homework (disambiguation) exists and is not blank. In rare cases (about three dozen on the first run), when the target talk page is a red-link or has no content, then I replace the redirect with Talk page of a redirect and WikiProject Disambiguation templates (like this).

Now I must make a confession. In the course of testing my code, I accidentally made a de facto 370-edit trial run. I was intending to make a dry run through to completion, and commented out lines of code which I expected to un-comment for an approved trial. Unfortunately, I neglected to comment out one key line; sorry about that. I noticed my mistake about three minutes later – it's amazing how many edits an unrestricted bot can make in 3 minutes. One line I had commented out was the sleep command that put a governor on the bot's editing speed. I'll try to be more careful in the future.

The bot works Category:Unsynchronized disambiguation talk page redirects in alphabetical order. So my trial has cleared A–H already, except for a few "red-link" cases, as I added the code to replace those with Talk page of a redirect and WikiProject Disambiguation after that bootleg-trial. Those will be the first done on the next run. – wbm1058 (talk) 00:20, 20 November 2017 (UTC)

Discussion

 * (as this has already been done). I'm reviewing the accidental trial now. In the future, for dry runs, it's a good idea to keep the sleep command uncommented as a precautionary measure. ~ Rob 13 Talk 10:08, 27 November 2017 (UTC)
 * ~ Rob 13 Talk 10:12, 27 November 2017 (UTC)
 * I reviewed the latest 50 edits and everything looked good to me. The extended trial is mostly to make sure the code is now operating at an appropriate rate. ~ Rob 13 Talk 10:11, 27 November 2017 (UTC)
 * 25 edits, at a more pedestrian speed. 19 of these are redirects, as in the first 370-edit trial (edit summary Syncing unsynchronized disambiguation talk page redirect). The other 6 are template placements (edit summary Fixing unsynchronized disambiguation { {Talk page of a redirect}}). Talk:Get It (song) is one of these pages. – wbm1058 (talk) 00:45, 29 November 2017 (UTC)
 * . ~ Rob 13 Talk 16:50, 22 December 2017 (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.