Wikipedia:Bots/Requests for approval/PearBOT 14: Difference between revisions
Trialpears (talk | contribs) m fix link |
Trialpears (talk | contribs) lots of ce |
||
Line 11: | Line 11: | ||
'''[[Programming language]](s):''' Pywikibot |
'''[[Programming language]](s):''' Pywikibot |
||
'''[[Source code]] available:''' Will add and upload when |
'''[[Source code]] available:''' Will add and upload when finished. It is in PearBOT II's workspace for the time being |
||
'''Function overview:''' Adds {{tl|Other TfDs}} boxes with links to all previous TfD discussions concerning a nominated template. |
'''Function overview:''' Adds {{tl|Other TfDs}} boxes with links to all previous TfD discussions concerning a nominated template. |
||
Line 19: | Line 19: | ||
'''Edit period(s):''' Checks the daily TfD subpage once an hour for new discussions, actually edits a few times a week. Also a large one time addition for all past discussion. |
'''Edit period(s):''' Checks the daily TfD subpage once an hour for new discussions, actually edits a few times a week. Also a large one time addition for all past discussion. |
||
'''Estimated number of pages affected:''' Maybe 2000-2500 when applying boxes to discussions |
'''Estimated number of pages affected:''' Maybe 2000-2500 when applying boxes to discussions (one time only). When in use maybe dozen a week. |
||
'''[[Template:bots|Exclusion compliant]]''' ''(Yes/No)''''':''' Yes |
'''[[Template:bots|Exclusion compliant]]''' ''(Yes/No)''''':''' Yes |
||
Line 25: | Line 25: | ||
'''Already has a bot flag''' ''(Yes/No)''''':''' Yes |
'''Already has a bot flag''' ''(Yes/No)''''':''' Yes |
||
'''Function details:''' The bot consists of 3 parts. One script that goes through all [[Templates for discussion/Log]] subpages and scrapes what templates were discussed (linked in {{tl| |
'''Function details:''' The bot consists of 3 parts. One script that goes through all [[Templates for discussion/Log]] subpages and scrapes what templates were discussed (linked in {{tl| links}}), the result and the link to the discussion. This information is added to a 14 MB python dictionary. Relists are ignored. Part two goes through all the same pages and adds an {{tl|Other TfDs}} box if one of the templates has been discussed some other time (either previously or later) as determined by the dictionary. There are up to ~3000 discussions out of ~56,000 that could get such a box, but the real number will be less due to identical mass noms and templates nominated more than twice being double counted. The third script would check the TfD subpage of the day for new discussions each hour and adds them to the dictionary. If any discussion needs a box it adds one there and updates previous discussions to include a link to the new one. This script isn't written yet, but will mostly consist of parts from the other two scripts. These user pages have a small number of successful test edits: [[User:PearBOT/TfD test 1|1]], [[User:PearBOT/TfD test 2|2]], and [[User:PearBOT/TfD test 3|3]]. |
||
===Discussion=== |
===Discussion=== |
Revision as of 20:12, 28 December 2023
Operator: Trialpears (talk · contribs · SUL · edit count · logs · page moves · block log · rights log · ANI search)
Time filed: 20:06, Thursday, December 28, 2023 (UTC)
Automatic, Supervised, or Manual: automatic
Programming language(s): Pywikibot
Source code available: Will add and upload when completely finished. It is in PearBOT II's PAWS workspace for the time being.
Function overview: Adds {{Other TfDs}} boxes with links to all previous TfD discussions concerning a nominated template.
Links to relevant discussions (where appropriate): Wikipedia talk:Templates for discussion#Automatically listing old discussions
Edit period(s): Checks the daily TfD subpage once an hour for new discussions, actually edits a few times a week. Also a large one time addition for all past discussion.
Estimated number of pages affected: Maybe 2000-2500 when applying boxes to discussions retroactively (one time only). When in continuous use maybe a dozen a week.
Exclusion compliant (Yes/No): Yes
Already has a bot flag (Yes/No): Yes
Function details: The bot consists of 3 parts. One script that goes through all Wikipedia:Templates for discussion/Log subpages and scrapes what templates were discussed (linked in {{Tfd links}}), the result and the link to the discussion. This information is added to a 14 MB python dictionary. Relists are ignored. Part two goes through all the same pages and adds an {{Other TfDs}} box if one of the templates has been discussed some other time (either previously or later) as determined by the dictionary. There are up to ~3000 discussions out of ~56,000 that could get such a box, but the real number will be less due to identical mass noms and templates nominated more than twice being double counted. The third script would check the TfD subpage of the day for new discussions each hour and adds them to the dictionary. If any discussion needs a box it adds one there and updates previous discussions to include a link to the new one. This script isn't written yet, but will mostly consist of parts from the other two scripts. These user pages have a small number of successful test edits: 1, 2, and 3.