Wikipedia:Bots/Requests for approval/ZackBot 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 Symbol oppose vote.svg Withdrawn by operator.

ZackBot 4
Operator:

Time filed: 00:42, Saturday, December 3, 2016 (UTC)

Automatic, Supervised, or Manual: Automatic

Programming language(s): Ruby

Source code available: User:ZackBot/river_cleanup

Function overview: Remove instances of from infobox river

Links to relevant discussions (where appropriate): Special:Permalink/756930869

Edit period(s): one time run

Estimated number of pages affected: 11,472 (all in Category:Pages using infobox river with "basin countries" parameter

Exclusion compliant (Yes/No): yes

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

Function details: Simply will go through all pages in the deprecation category and replace the param with the new syntax that is used in nearly every info box that has anything to do with geographic location. The code will search for the regex:  and grab the country. It will then replace that code with  this adding the suibdividion_type as Country and inserting the new subdivision name.

Discussion
Can you link to a discussion to remove this parameter somewhere? It looks like the template still displays it when populated. — xaosflux  Talk 01:01, 3 December 2016 (UTC)
 * There are multiple threads on Template talk:Infobox river about this. Not sure if they will satisfy what you are looking for... The existence of the deprecation category and tracking of these occurrences seems to suggest it, as does the fact that this is the new convention. What are your concerns? -- Zackmann08 (Talk to me/What I been doing) 07:58, 3 December 2016 (UTC)
 * Just making sure there is a consensus for the removal before you make 10000+ changes, the category was made by . Rehman, any comments? —  xaosflux  Talk 15:24, 3 December 2016 (UTC)
 * Gotcha! Makes total sense to me! :-) -- Zackmann08 (Talk to me/What I been doing) 19:20, 3 December 2016 (UTC)

Thanks for the ping, User:Xaosflux. I personally have no serious concerns with this, but, it would be better if this could be coupled with more fixes since we will be editing quite a number of articles. The other fixes may include the updating of coordinates parameters (as per the template talkpage), among other fixes. Hence I feel like we should hold this request for now. Reh man  06:44, 4 December 2016 (UTC)
 * I'm happy to add that to the script, but I'm pretty sure that is already doing that. I'm not seeing what the problem is with it editing so many articles? it is a simple edit... -- Zackmann08  (Talk to me/What I been doing) 06:21, 5 December 2016 (UTC)
 * I would also like to point out that there is precedent... See User:Monkbot. -- Zackmann08 (Talk to me/What I been doing) 07:27, 5 December 2016 (UTC)
 * I support this task, and this bot should not try to replicate the tricky work that is doing. If  has other specific infobox cleanup edits to suggest (besides coordinates), they can be listed here or on the infobox's talk page. – Jonesey95 (talk) 07:31, 5 December 2016 (UTC)
 * any further thoughts? Seems like the only concern that has been raised is that it is solely a cosmetic change, but there is some debate as to whether that is true. -- Zackmann08 (Talk to me/What I been doing) 03:05, 6 December 2016 (UTC)
 * I'd really like to see some more people weigh in on this so giving it some time. —  xaosflux  Talk 03:09, 6 December 2016 (UTC)
 * works for me! :-) I shall standby. you've all taken part in the discussion on the template talk page or made edits to Infobox river. Any thoughts? -- Zackmann08  (Talk to me/What I been doing) 03:14, 6 December 2016 (UTC)


 * Thanks for the input Jonesey95. If you believe dealing with the coordinates now is a complex move, then as you suggest, lets play it safe and leave that out :-) (Unless of course, if that bot can take over the tasks being proposed here). I don't have anything serious in my mind other than what is being proposed, so I support to go ahead. As a side note, please do add an edit summary of something like this if possible, so others would be encouraged to look at the updated infobox. Cheers, Reh  man  23:43, 6 December 2016 (UTC)
 * I like that idea! Will certainly add a clear edit summary. Just need the go ahead to put this in trial. -- Zackmann08 (Talk to me/What I been doing) 22:22, 11 December 2016 (UTC)

BAGAssistanceNeeded

I have similar concerns to task 7 regarding the regular expressions. infobox_text.gsub!(/\ looks like it would remove the subdivision_name1 parameter, but leave the value. Is that intentional?There are some tricks I'd like to share... If you're not already familiar with this tactic, try out the pry-byebug gem, and replace the client.edit line (all editing code) with binding.pry. This will activate the debugger where it would normally edit. From here, you can sort of do a dry run of the bot, and carefully analyze if the change it was going to implement is correct. That may surface other issues. Within the debugger, use exit to skip to the next iteration, and exit-program to exit out of the bot's run entirely. I'd also strongly recommend a sleep 1 (one second) for each iteration, at least for the first 20-30 pages of a run, to make sure nothing goes horribly wrong on a large scale. As with task 7, I will try to look over the more complex regex, too.Finally, could you also update this BRFA filing to include links to relevant discussions? Thanks! &mdash; MusikAnimal  talk  07:30, 16 December 2016 (UTC)
 * With other task completed, shall we shift focus back here? First and foremost, I have big concerns taking on 10,000+ pages when the "Links to relevant discussions" of the BRFA filing is empty. I know you said there were some at Template talk:Infobox river. Could you point those out? Also, from the "Function details" it is unclear exactly what is going to happen. Could you elaborate on what the "new syntax" is, and also touch on any additional functionality that was requested by Rehman here in the BRFA? Are others in agreeance with the new requested changes? &mdash; MusikAnimal  talk  22:46, 21 December 2016 (UTC)
 * D I second MusikAnimal's sentiment. We're looking to be spoon-fed the relevant discussions, because there are few of us, and we're unfortunately not omniscient (nor have time to scour archives). Furthermore, if the issue is for some reason contentious, we want to ensure everyone involved is aware a bot is about to do stuff. -- slakr \ talk / 22:56, 21 December 2016 (UTC)
 * Sorry been a busy day... Let me follow up in the morning! I wanted to acknowledge this tho! -- Zackmann08 (Talk to me/What I been doing) 05:07, 22 December 2016 (UTC)
 * so the more I looked at it, the more I realized that there isn't really a thread that shows consensus for this change to be made.... IMHO it is a matter of common sense. All infoboxes that have any sort of location specific data are migrating towards to idea of subdivison1, subdivison2, subdivison3, etc... That being said, I do agree that before a bot is executed making 10,000+ edits, a CLEAR consensus should be reached. To that end, I have started a thread on the talk page here. I pinged the most recent editors. If that doesn't drive some responses I will start a WP:RFC. In the meantime, shall we put this on hold? Shall we move forward with testing it but wait off on full approval? I defer to your judgments. -- Zackmann08 (Talk to me/What I been doing) 18:44, 22 December 2016 (UTC)
 * A discussion on a template talk page is not normally counted as a community consensus unless it has also been advertised somewhere more well attended by the general community. Maybe this one only concerns certain wikiprojects (not sure how much wider interest there would be) but it should at least be advertised on their talk pages if not conducted there. SpinningSpark 19:20, 23 December 2016 (UTC)
 * sorry for the late response. Holliday's have kept me off wikipedia for a bit. Where do you think would be the best place to have this conversation? -- Zackmann08 (Talk to me/What I been doing) 15:47, 27 December 2016 (UTC)
 * I'm not really able to advise you authoritatively on this particular case as I am not familiar. My comment was a general one.  You need to make a call on whether you think this is just a local issue or if there is wider community interest.  As I said, I suspect it is only of interest to Wikiprojects using the template, in which case open a discussion on the main one and put a notification on the others (or link to the existing discussion at the template page).  You can identify these by sampling a few talk pages of articles using the template where the wikiprojects claiming scope are declared.  Sometimes template talk pages also declare Wikiproject scope, but more rarely. SpinningSpark 18:14, 27 December 2016 (UTC)

Sorry I didn't get to you sooner. I probably wouldn't have started an RfC, at least in the History and geography list, as this is a very much technical matter that is of little interest to most. RfC's are a bit time consuming :) The series of pings you made is probably enough, and maybe also notify WT:RIVERS and WT:WPINFOBOXES, as Spinningspark suggests. I'll give this a few days then we can proceed. In the meantime, please kindly fill out the "Function details" so that is more clear as to exactly what the bot is going to do. You can also go ahead and fill in the "Links to relevant discussions". Thanks! &mdash; MusikAnimal  talk  05:10, 28 December 2016 (UTC)

D I think there is now sufficient support for this task. Before we go any further, we still need the above "Function details" to be filled out. What is the old syntax, and what is the new syntax? Note also my first comment above about the "subdivision_name1" regex. It's unclear what it is trying to do. The additional functionality recommended by Rehman here in the BRFA doesn't appear to have been discussed much elsewhere, so I think we should save that for another task &mdash; MusikAnimal  talk  21:53, 31 December 2016 (UTC)
 * didn't want you to think I was ignoring you. been traveling a lot the past few days. What little time I did have for WIkipedia I was working on other projects. Hoping to get some time to work on this today or tmrw. Thanks for the follow up! :-) Happy new year! -- Zackmann08 (Talk to me/What I been doing) 18:54, 1 January 2017 (UTC)


 * Thanks for following up on this User:Zackmann08, appreciate it. I too was away due to holidays, and will again be away due to lots of RL work :( I agree with MusikAnimal, this is a simple technical task, and can be done sooner IMO. Happy New Year! Reh  man  14:37, 3 January 2017 (UTC)


 * alright. Finally taking the time to look this over... In response to your question Musik about the regex... The purpose of infobox_text.gsub!(/\ is to remove  if it already exists. My thinking was that the pages in the category have   as well as   and I didn't want to end up with duplicate params. This however has multiple issues... First, what about  ? That would need to be checked for as well... What if both params are filled in? Then shouldn't I just delete basin_counties? Here's my thinking... Why don't I change the category in the template to only categorize pages that have basin_countries set and nothing set for subdivision_name1. Then I can safely delete those as I iterate through. Thoughts? -- Zackmann08  (Talk to me/What I been doing) 17:48, 3 January 2017 (UTC)
 * That seems sensible, but I'm honestly still confused what is the proper syntax and what is not. Are both subdivision_name1 and subdivision_type1 valid? I take it basin_countries lists the countries one by one, whereas with the subdivision syntax we use a different parameter for each country. Is that correct? &mdash; MusikAnimal  talk  00:07, 5 January 2017 (UTC)
 * so If you use subdivision_name1 you need subdivision_type1 to go with it. In this case, type will always be country. -- Zackmann08 (Talk to me/What I been doing) 20:53, 5 January 2017 (UTC)
 * Sorry to keep asking, but if you could kindly fill in the "Functional details" with exactly what the bot is intended to do, that'd be very helpful so we don't have to keep scanning through the discussion &mdash; MusikAnimal  talk  00:03, 14 January 2017 (UTC)

done. -- Zackmann08 (Talk to me/What I been doing) 22:36, 16 January 2017 (UTC)
 * Thanks! It is much clearer now :) Though it seems the part about removing subdivision_name if it is blank has not been explained. Do you still plan to add any similar logic? Or maybe you want to update the template to (and subdivision_type1)?A few more concerns: the numbering of the new parameters suggests there could be multiple sets. Is it possible that subdivision_name and type can be used for something other than the country, in which case the bot would have to increment the parameter name accordingly? So if name/types 1 and 2 are taken for other purposes, and basin_countries is set, the bot would need to remove basin_countries and set subdivision_name3 and subdivision_type3 accordingly. Finally it looks like the regex to capture the country won't account for piped links  &mdash;  MusikAnimal  talk  23:45, 16 January 2017 (UTC)
 * Any updates? It's the usage of subdivision_name1 vs subdivision_name2, etc, that I'm most worried about &mdash; MusikAnimal  talk  17:00, 31 January 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.