Wikipedia:Bots/Requests for approval/ProcBot 4
Note: If ProcBot is moving an editnotice you've created on a redirect, and you actually intend for the editnotice to be visible on the redirect page and not on the target, then include the |redirect=yes
parameter in your template call for {{editnotice}}. Example here. This says that the editnotice is intentionally on the redirect, and therefore ProcBot will not try to move the page.
- The following discussion is an archived debate. Please do not modify it. To request review of this BRFA, please start a new section at Wikipedia:Bots/Noticeboard. The result of the discussion was Approved.
Operator: ProcrastinatingReader (talk · contribs · SUL · edit count · logs · page moves · block log · rights log · ANI search)
Time filed: 13:31, Tuesday, September 15, 2020 (UTC)
Automatic, Supervised, or Manual: automatic
Programming language(s): Ruby (not written yet)
Source code available:
Function overview: Move editnotices when the underlying page has been moved
Links to relevant discussions (where appropriate): Wikipedia:Bot_requests#Move_editnotices_when_underlying_page_is_moved
Edit period(s): Continuous
Estimated number of pages affected: ~20k editnotices exist currently, of those number requiring move is unknown due to technical limitations
Exclusion compliant (Yes/No): No
Already has a bot flag (Yes/No): Yes
Function details: An editnotice is attached to a particular page. Sometimes that page gets moved, and often its editnotice does not get moved along with it. This is tracked by Category:Editnotices whose targets are redirects, but that is not updated quickly due to technical limitations. In any case, it's reasonably important to move the editnotice, as whatever its content is isn't intended for the redirect, but the page itself. In the case of DS notices, an editnotice not being moved causes general sanctions (like 1RR) to be invalid, as awareness criteria will not be met. Thus, say ABC is moved to CBA, this bot would automatically move the editnotice of the now-redirect ABC to Template:Editnotices/Page/CBA.
Technically speaking it'll do this either by applying null edits to the transclusions of {{Editnotice}}, and then looking over the (hopefully now-updated) tracking category and moving. Or, more ideally (as some editnotices don't transclude {{Editnotice}} for some reason) look for pages with prefix Special:PrefixIndex/Template:Editnotices/ and checking if the underlying page is a redirect (if so, recursively resolve redirect and move page to where it points).
Bot will maintain a log in its userspace of all editnotices it moves. I guess Special:Log/move/ProcBot exists.
Discussion
[edit]Okay, a few questions, in no particular order.
- I just checked the category, and came across Template:Editnotices/Page/Template:Syrian Civil War infobox, and in prepping to move to Template:Editnotices/Page/Template:Syrian civil war infobox I discovered that the latter was a redirect, meaning I had to delete it first. How will your bot deal with these sorts of conflicts?
- While checking all of the templates with the prefix (as I agree that's probably an easier method of determining which notices correspond to redirected pages), will it skip redirected edit notices, such as the one I created above?
- Will it leave a redirect?
- When you say it's continuous, are you planning on continuously cycling through the list of notices, or will it be a once-a-<timeframe> dump and check?
Nothing here necessarily is cause for concern, just looking at clarifying a few points. Primefac (talk) 14:24, 17 September 2020 (UTC)[reply]
- It'd just have to skip, I think. If I'm not mistaken only admins can deal with those, or a pagemover by doing a round robin swap whilst suppressing redirects, then tagging the leftover for deletion. But by that point an admin might as well have cleaned it up from the category themselves. I don't think special support for the case needs to be coded: the bot would try move, end up with an error and hence skip, leaving it in the cat for an admin to clean up.
- Yes, skip any editnotices which are redirects. To fetch by prefix it would use this API method, with "apprefix" set to "(Template:)Editnotices/" and "apfilterredir" to "nonredirects" - I believe that should make it so no redirect pages are returned.
- Suppress it. I think in almost all cases the notice is intended for the page itself, not the leftover redirect (eg "Use British English" doesn't apply to "#REDIRECT[]"). There are few cases where it's aimed at the redirect itself, such as Template:Editnotices/Page/Giants, but those have
|redirect=yes
set in the editnotice, so a regex on the page text looking for that would do the trick to skip. Generally when I'd manually move pages I'd nominate leftover redirect for G6 as well, and that seems to have been the standard beforehand also. e: looks like WP:PMRC#8 would explicitly support doing this - Hm, realistically I think it'll have to suffice with daily, since it'd have to cycle through each editnotice page.
- ProcrastinatingReader (talk) 16:18, 17 September 2020 (UTC)[reply]
Approved for trial (5 edits). Please provide a link to the relevant contributions and/or diffs when the trial is complete. I suspect this will be a bit of a slow process, so please don't feel like it has to be done right away. Don't worry about redirect suppression right now, we can debate the merits of giving the bot PGM later. Primefac (talk) 15:00, 25 September 2020 (UTC)[reply]
- Thanks Primefac. Can the bot be given TE for the trial? (needed to edit editnotices) ProcrastinatingReader (talk) 19:45, 25 September 2020 (UTC)[reply]
- Done. Primefac (talk) 19:51, 25 September 2020 (UTC)[reply]
- Trial complete. - technically, at least, turned out pretty straight forward. Log: Special:Log/move/ProcBot. ProcrastinatingReader (talk) 13:22, 26 September 2020 (UTC)[reply]
- Approved. Primefac (talk) 22:06, 29 September 2020 (UTC)[reply]
- Trial complete. - technically, at least, turned out pretty straight forward. Log: Special:Log/move/ProcBot. ProcrastinatingReader (talk) 13:22, 26 September 2020 (UTC)[reply]
- Done. Primefac (talk) 19:51, 25 September 2020 (UTC)[reply]
- 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 Wikipedia:Bots/Noticeboard.
Primefac query re the suppression issue above? Should we suppress under WP:PMRC#8? Just querying before I fill the space with redirects. ProcBot (talk) 00:31, 30 September 2020 (UTC)[reply]
- Yeah, forgot to give the correct perm. Done. Primefac (talk) 12:10, 30 September 2020 (UTC)[reply]