Wikipedia:Bots/Requests for approval/Ahechtbot 6


 * 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

Ahechtbot 6
Operator:

Time filed: 03:36, Friday, June 7, 2019 (UTC)

Automatic, Supervised, or Manual: automatic

Programming language(s): python

Source code available: User:Ahechtbot/transclusioncount.py

Function overview: Create lua-formatted lists of highly transcluded templates.

Links to relevant discussions (where appropriate): Template talk:High-use

Edit period(s): Weekly

Estimated number of pages affected: 27

Exclusion compliant (Yes/No): No

Already has a bot flag (Yes/No): Yes

Function details: Will run a script similar to that used to generate Database reports/Templates transcluded on the most pages (which is no longer regularly updated). All edits will be to subpages of a single module. No more than 27 edits will be made per week outside of the bot's userspace.

Discussion

 * If I understand correctly, Module:Transclusion count, when it is created, will be redundant to Module:Data. * Pppery * it has begun... 11:43, 7 June 2019 (UTC)

PAGE ]]) 14:12, 7 June 2019 (UTC) PAGE ]]) 13:47, 9 June 2019 (UTC) PAGE ]]) 16:54, 20 June 2019 (UTC) PAGE ]]) 03:13, 22 July 2019 (UTC) PAGE ]]) 00:28, 12 August 2019 (UTC) PAGE ]]) 15:13, 3 September 2019 (UTC) BAGAssistanceNeeded Trial was completed two weeks ago. --Ahecht (TALK PAGE ) 14:52, 16 September 2019 (UTC)
 * Not exactly. The module will take a template name as input, extract the first character, load the appropriate data table based on that character (either "A"–"Z" or "other"), and return the transclusion count. I could have the bot load the data into a submodule of Module:Data and leave the name parsing to Wikitext (e.g. ), but since that requires spinning up Lua twice it seemed cleaner to do it all in one step in a new module and just call  . --Ahecht ([[User talk:Ahecht|TALK
 * Well, I don't see the benefit of splitting the data pages by letter either and the code you posted falls far below my standard of "merits a Lua module" -- but its probably better to let TfD decide this rather than arguing about it on a bot request. * Pppery * it has begun... 19:00, 7 June 2019 (UTC)
 * Splitting pages by letter code was mainly due to the size. Most of the Database reports tend to split lists with over a thousand entries, and splitting by letter makes lookup of any particular template straightforward. There are thousands of templates that will end up on this list, and having the documentation page for each of the thousands of pages using high use loading and parsing a giant table weekly seemed inefficient from a server load standpoint. --Ahecht ([[User talk:Ahecht|TALK
 * , I know it might take a bit to create the module and related content, so run the 4 weeks from whenever the bot starts editing. As far as implementation goes I'll leave that to you, but from a "proof of concept" I think replacing a few calls to high risk with a sandbox version that invokes the module will work. Primefac (talk) 12:49, 15 June 2019 (UTC)
 * The trial is currently on hold. There is currently an issue with the toolforge database replicas, and the transclusions query that had been taking about 15 minutes is now timing out after 30 minutes or so (the same query, which had run successfully at https://quarry.wmflabs.org/ is also now failing there, so this appears to be a global issue, not a bot-specific one). I will run the trial once this gets resolved. --Ahecht ([[User talk:Ahecht|TALK
 * Just a quick update: The database replica issue seems to be resolved (and, according to the phab:T226050, future slow-downs should last hours, not days), but I will be away from the internet next week so I don't want to start a 4-week trial before that. I will re-activate this BRFA when I return. --Ahecht ([[User talk:Ahecht|TALK
 * I started the first run on Friday, and had to make a few tweaks to get it working properly when saving in the Module: namespace. It's now set to run each Sunday morning for the next few weeks. --Ahecht ([[User talk:Ahecht|TALK
 * The bot has now completed 4 weekly runs. I have implemented the sandbox template on Template:R from sort name/doc, Template:WikiProject Albums/doc, Template:Taxobox/doc, Template:Small Solar System bodies/doc, Template:Portal/doc, and Template:Memory Alpha/doc, which should represent a variety of use cases (5-digit count, 6-digit count using "+" notation", 6-digit count using "approximately" text, 4-digit count, 7-digit count with percent, and a template that is not indexed by the bot). --Ahecht ([[User talk:Ahecht|TALK
 * Sorry for the delay. I don't see any major issues. Primefac (talk) 16:40, 22 September 2019 (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.