Wikipedia:Bots/Requests for approval/CensusBot 2
[[User:CensusBot|CensusBot 2]]
{{Newbot|CensusBot|2}}
Operator: {{botop|Logan-Census}}
Time filed: 16:50, Monday, July 17, 2017 (UTC)
Automatic, Supervised, or Manual: Automatic
Programming language(s): Python
Source code available: https://github.com/CommerceDataService/census-wikidata-bot/blob/master/wikipedia_bot.py
Function overview: A bot for checking total population and ranking values in U.S. State and County page infoboxes and editing to add official values from U.S. Census Bureau API's
Links to relevant discussions (where appropriate): Wikipedia_talk:WikiProject_U.S._counties#County_Infobox_Inconsistencies
Edit period(s): Twice yearly
Estimated number of pages affected: 3,000 pages (each US county)
Exclusion compliant (Yes/No): No
Already has a bot flag (Yes/No): No
Function details: This is an extension of the original CensusBot request, in order to allow the bot to edit population values for US county pages.
CensusBot is a bot produced by the [https://www.commerce.gov/dataservice/ Commerce Data Service] in collaboration with the [https://www.census.gov/ U.S. Census Bureau]. The main purpose of this bot is to check Wikipedia pages to make sure that they contain the most up to date information available from the Census Bureau and that the entries are complete.
{{reflist}}
=Discussion=
In addition to this bot request, I want to register this user account as an additional operator for CensusBot. I am working with Sasan-CDS. Let me know if there is anything I need to edit for the bot or the pervious request to have me listed as an approved operator. -- Logan-Census (talk) 18:35, 26 July 2017 (UTC)
:Please have the original operator confirm this request.—CYBERPOWER (Around) 21:10, 27 July 2017 (UTC)
::{{ping|Cyberpower678}} Hi, I can confirm that Logan-Census is now the operator of this bot. Sasan-CDS (talk) 13:52, 7 August 2017 (UTC)
- {{BotTrial|edits=50}} Please link to the diffs when done.—CYBERPOWER (Chat) 18:04, 7 August 2017 (UTC)
- I note that the bot removes extra spaces that are included as part of the infobox templates ([https://en.wikipedia.org/w/index.php?title=Anchorage,_Alaska&diff=prev&oldid=794779851]) which can make it easier for editors to work with infoboxes. I don't know the views of others on these, minor stylistic changes, but that edit seemed to boarder on WP:COSMETICBOT if it were not for the comma. I am concerned that this could easily become a case of CONTEXTBOT. I am further concerned by the lack of requisite Wikipedia experience needed to operate a bot in this case, as I rased in the first BRFA. In particular the BRFA was filed incorectly (details here). TheMagikCow (T) (C) 18:43, 10 August 2017 (UTC)
- {{ping|TheMagikCow}} I also noticed that issue and ensured that I only updated the one page while working through any additional updates. I reverted the change you linked to, and you can see the updated diff now ([https://en.wikipedia.org/w/index.php?title=Anchorage,_Alaska&diff=794927649&oldid=794927476]). Additionally I’ve updated the bot code so that it won’t apply the thousands separator (‘,’) in future population values. For the trial, I'm using the 50 edits as an opportunity to update one county page per state -- and I am working through it methodically to ensure each page's variance is accounted for. There are three different templates used, and they’re not used consistently across pages, which makes automated changes tricky. If you have recommendations for the bot behavior, I can incorporate that into the code. Also, yes the BRFA was initially submitted by Sasan-CDS with the wrong format. That was a mistake that I fixed at the same time that I listed myself as the bot operator. -- Logan-Census (talk) 15:03, 11 August 2017 (UTC)
- Hi {{u|Logan-Census}}! Its not so much the presence of the comma that I take issue with. My issue is edits that the bot would perform where the only change is adding the comma, as a source and the correct population is already present. Thanks for fixing the changes above - the task seems tricky with the different templates in use! Best, TheMagikCow (T) (C) 17:13, 11 August 2017 (UTC)
{{ping|Cyberpower678}} I have made 50 edits using CensusBot. Some states didn't have any pages that needed to be updated, so this represents changes to 36 different states. The 50 diffs are provided below:
- [https://en.wikipedia.org/w/index.php?title=Anchorage,_Alaska&diff=prev&oldid=794927649 Anchorage, Alaska]
- [https://en.wikipedia.org/w/index.php?title=Kusilvak_Census_Area,_Alaska&diff=prev&oldid=795537250 Kusilvak Census Area, Alaska]
- [https://en.wikipedia.org/w/index.php?title=Lafayette_County,_Arkansas&diff=prev&oldid=795633932 Lafayette County, Arkansas]
- [https://en.wikipedia.org/w/index.php?title=Butte_County,_California&diff=prev&oldid=795633947 Butte County, California]
- [https://en.wikipedia.org/w/index.php?title=Adams_County,_Colorado&diff=prev&oldid=795633962 Adams County, Colorado]
- [https://en.wikipedia.org/w/index.php?title=Baker_County,_Florida&diff=prev&oldid=795633986 Baker County, Florida]
- [https://en.wikipedia.org/w/index.php?title=Appling_County,_Georgia&diff=prev&oldid=795634006 Appling County, Georgia]
- [https://en.wikipedia.org/w/index.php?title=Honolulu_County,_Hawaii&diff=prev&oldid=795634039 Honolulu County, Hawaii]
- [https://en.wikipedia.org/w/index.php?title=Ada_County,_Idaho&diff=prev&oldid=795634053 Ada County, Idaho]
- [https://en.wikipedia.org/w/index.php?title=Adams_County,_Illinois&diff=prev&oldid=795634073 Adams County, Illinois]
- [https://en.wikipedia.org/w/index.php?title=Adams_County,_Indiana&diff=prev&oldid=795634096 Adams County, Indiana]
- [https://en.wikipedia.org/w/index.php?title=Adair_County,_Iowa&diff=prev&oldid=795634116 Adair County, Iowa]
- [https://en.wikipedia.org/w/index.php?title=Adair_County,_Kentucky&diff=prev&oldid=795634178 Adair County, Kentucky]
- [https://en.wikipedia.org/w/index.php?title=Acadia_Parish,_Louisiana&diff=prev&oldid=795634197 Acadia Parish, Louisiana]
- [https://en.wikipedia.org/w/index.php?title=Allegany_County,_Maryland&diff=prev&oldid=795634215 Allegany County, Maryland]
- [https://en.wikipedia.org/w/index.php?title=Barnstable_County,_Massachusetts&diff=prev&oldid=795634229 Barnstable County, Massachusetts]
- [https://en.wikipedia.org/w/index.php?title=Alcona_County,_Michigan&diff=prev&oldid=795634253 Alcona County, Michigan]
- [https://en.wikipedia.org/w/index.php?title=Alcorn_County,_Mississippi&diff=prev&oldid=795634296 Alcorn County, Mississippi]
- [https://en.wikipedia.org/w/index.php?title=Adair_County,_Missouri&diff=prev&oldid=795634323 Adair County, Missouri]
- [https://en.wikipedia.org/w/index.php?title=Beaverhead_County,_Montana&diff=prev&oldid=795634338 Beaverhead County, Montana]
- [https://en.wikipedia.org/w/index.php?title=Adams_County,_Nebraska&diff=prev&oldid=795634355 Adams County, Nebraska]
- [https://en.wikipedia.org/w/index.php?title=Churchill_County,_Nevada&diff=prev&oldid=795634376 Churchill County, Nevada]
- [https://en.wikipedia.org/w/index.php?title=Atlantic_County,_New_Jersey&diff=prev&oldid=795634394 Atlantic County, New Jersey]
- [https://en.wikipedia.org/w/index.php?title=Bernalillo_County,_New_Mexico&diff=prev&oldid=795634407 Bernalillo County, New Mexico]
- [https://en.wikipedia.org/w/index.php?title=Albany_County,_New_York&diff=prev&oldid=795634431 Albany County, New York]
- [https://en.wikipedia.org/w/index.php?title=Alamance_County,_North_Carolina&diff=prev&oldid=795634455 Alamance County, North Carolina]
- [https://en.wikipedia.org/w/index.php?title=Adams_County,_Ohio&diff=prev&oldid=795634478 Adams County, Ohio]
- [https://en.wikipedia.org/w/index.php?title=Adair_County,_Oklahoma&diff=prev&oldid=795634501 Adair County, Oklahoma]
- [https://en.wikipedia.org/w/index.php?title=Adams_County,_Pennsylvania&diff=prev&oldid=795634525 Adams County, Pennsylvania]
- [https://en.wikipedia.org/w/index.php?title=Bristol_County,_Rhode_Island&diff=prev&oldid=795634546 Bristol County, Rhode Island]
- [https://en.wikipedia.org/w/index.php?title=Abbeville_County,_South_Carolina&diff=prev&oldid=795634576 Abbeville County, South Carolina]
- [https://en.wikipedia.org/w/index.php?title=Anderson_County,_Tennessee&diff=prev&oldid=795634618 Anderson County, Tennessee]
- [https://en.wikipedia.org/w/index.php?title=Anderson_County,_Texas&diff=prev&oldid=795634634 Anderson County, Texas]
- [https://en.wikipedia.org/w/index.php?title=Beaver_County,_Utah&diff=prev&oldid=795634645 Beaver County, Utah]
- [https://en.wikipedia.org/w/index.php?title=Addison_County,_Vermont&diff=prev&oldid=795634669 Addison County, Vermont]
- [https://en.wikipedia.org/w/index.php?title=Accomack_County,_Virginia&diff=prev&oldid=795634679 Accomack County, Virginia]
- [https://en.wikipedia.org/w/index.php?title=Barbour_County,_West_Virginia&diff=prev&oldid=795634689 Barbour County, West Virginia]
- [https://en.wikipedia.org/w/index.php?title=Adams_County,_Wisconsin&diff=prev&oldid=795634703 Adams County, Wisconsin]
- [https://en.wikipedia.org/w/index.php?title=San_Francisco&diff=prev&oldid=795635373 San Francisco]
- [https://en.wikipedia.org/w/index.php?title=Alamosa_County,_Colorado&diff=prev&oldid=795635392 Alamosa County, Colorado]
- [https://en.wikipedia.org/w/index.php?title=Arapahoe_County,_Colorado&diff=prev&oldid=795635416 Arapahoe County, Colorado]
- [https://en.wikipedia.org/w/index.php?title=Archuleta_County,_Colorado&diff=prev&oldid=795635435 Archuleta County, Colorado]
- [https://en.wikipedia.org/w/index.php?title=Baca_County,_Colorado&diff=prev&oldid=795635450 Baca County, Colorado]
- [https://en.wikipedia.org/w/index.php?title=Bent_County,_Colorado&diff=prev&oldid=795635461 Bent County, Colorado]
- [https://en.wikipedia.org/w/index.php?title=Boulder_County,_Colorado&diff=prev&oldid=795635482 Boulder County, Colorado]
- [https://en.wikipedia.org/w/index.php?title=Chaffee_County,_Colorado&diff=prev&oldid=795635497 Chaffee County, Colorado]
- [https://en.wikipedia.org/w/index.php?title=Cheyenne_County,_Colorado&diff=prev&oldid=795635520 Cheyenne County, Colorado]
- [https://en.wikipedia.org/w/index.php?title=Clear_Creek_County,_Colorado&diff=prev&oldid=795635537 Clear Creek County, Colorado]
- [https://en.wikipedia.org/w/index.php?title=Conejos_County,_Colorado&diff=prev&oldid=795635566 Conejos County, Colorado]
- [https://en.wikipedia.org/w/index.php?title=Costilla_County,_Colorado&diff=prev&oldid=795635587 Costilla County, Colorado]
As it is setup today, the bot will specifically attempt to update the Infobox_U.S._county and Infobox_settlement templates, only making a change if the raw population value doesn't match the most recent US Census population estimate. There are four U.S. counties still using the Geobox template, but I am ignoring those for now. The bot attempts to keep properties formatted with similar whitespace and order within the template, and most of that is done using the Python [https://github.com/earwig/mwparserfromhell mwparserfromhell]. -- Logan-Census (talk) 14:53, 15 August 2017 (UTC)
:So this goes back to the formatting, why is the bot removing the comma from certain numbers? I feel they should be left alone if in there. It should be easy to check for the presence of a comma.—CYBERPOWER (Chat) 13:10, 16 August 2017 (UTC)
::{{ping|Cyberpower678}} The bot is making that change because that's the directive within the template instructions. Those are defined here and here. It says to use the 'raw' format for numbers, and specifically mentions it when discussing population. I imagine it's a better format for localization. -- Logan-Census (talk) 16:53, 16 August 2017 (UTC)
- {{BotApproved}}—CYBERPOWER (Chat) 18:56, 16 August 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.