Wikipedia:Bots/Requests for approval/AnomieBOT 37
[[User:AnomieBOT|AnomieBOT 37]]
{{Newbot|AnomieBOT|37}}
Automatic or Manually assisted: Automatic, unsupervised
Programming language(s): Perl
Source code available: User:AnomieBOT/source/tasks/SafesubstFixer.pm
Function overview: Replace
Links to relevant discussions (where appropriate): Wikipedia talk:Template messages/User talk namespace#safesubst:
Edit period(s): As needed
Estimated number of pages affected: Up to ~600 for the first run
Exclusion compliant (Y/N): Yes
Already has a bot flag (Y/N): Yes
Function details: Until recently, the only way to make a template work both when substed and when not substed while also not cluttering the substed output with parser functions (e.g. #if, #switch) was to require a parameter "subst=subst:" be specified when substing. Now we have safesubst: which can be used for the same purpose, and without requiring the oft-forgotten "subst" parameter.
Upon request, the bot will go through a well-defined list of templates and replace
=Discussion=
The first run will be for the user warning templates (i.e. Special:PrefixIndex/Template:Uw-). I'm making a generic request in case anyone comes up with another well-defined set of templates that need the same treatment. Anomie⚔ 16:54, 20 April 2010 (UTC)
{{BotTrial|edits=50}} — The Earwig (talk) 19:13, 25 April 2010 (UTC)
: {{BotTrialComplete}} [http://en.wikipedia.org/w/index.php?title=Special:Contributions&limit=50&target=AnomieBOT&offset=20100425201200] Anomie⚔ 20:20, 25 April 2010 (UTC)
:: What's the reason for the #ifeq:|yes|}}
at the bottom of [http://en.wikipedia.org/w/index.php?title=Template:Uw-dblock&diff=next&oldid=356426305] and [http://en.wikipedia.org/w/index.php?title=Template:Uw-dblock&diff=next&oldid=356426305]? — The Earwig (talk) 22:54, 26 April 2010 (UTC)
::: Hmm, I didn't consider that Mediawiki doesn't support nested includeonlys (and I missed seeing it looking at the diffs). [http://en.wikipedia.org/w/index.php?title=User:AnomieBOT/source/tasks/SafesubstFixer.pm&diff=358544645&oldid=357230549 This] should fix it. Anomie⚔ 01:33, 27 April 2010 (UTC)
:::: FWIW, I would recommend using
::::: How interesting that that works. Although it does have an issue if someone manages to type "
:::::: I got it from meta:Help:Safesubst, but it's really just the same mechanics the old subst=subst: thing used. And FWIW, someone at meta considers it a feature that one can opt for one-level substitution by using
, cryptic as it may be. :)
I just use it because it's significantly shorter, and makes for clearer code. Amalthea 23:42, 3 May 2010 (UTC)
::::::: Note though that this is only a suggestion and basically a matter of taste, and should not delay approval. In fact, seeing that MC10 had already manually made that change to a number of templates, which due to a misunderstanding led to some unnecessary reverts (WP:Administrators' noticeboard/Incidents#Massive template breakage), I urge that this job be approved so that it can be wrapped up cleanly. :)
Amalthea 11:24, 4 May 2010 (UTC)
{{tl|BAG assistance needed}}
Will the bot operate per the Function details, or per the Discussion? Josh Parris 14:20, 4 May 2010 (UTC)
: I can do it either way, I have no preference which. As far as the uw template edits, I'll probably finish them with the includeonly style for consistency with the 50 already done. Anomie⚔ 23:16, 4 May 2010 (UTC)
{{BotApproved}} Josh Parris 04:42, 5 May 2010 (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.