Wikipedia:Bots/Requests for approval/PrimeBOT 25


 * 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

PrimeBOT 25
Operator:

Time filed: 22:22, Thursday, February 1, 2018 (UTC)

Automatic, Supervised, or Manual: automatic

Programming language(s): AWB

Source code available: WP:AWB

Function overview: Fix broken URLs

Links to relevant discussions (where appropriate): BOTREQ request

Edit period(s): one time run

Estimated number of pages affected: ~1500

Namespace(s): All

Exclusion compliant (Yes/No): Yes

Function details: www.cwgc.org has changed their URL parameters, leaving a lot of pages with broken links. Simple find/replace:

Discussion

 * Consider archive URLs:
 * http://web.archive.org/web/20100707090909/http://www.cwgc.org/search/casualty_details.aspx?Casualty=9898
 * http://webcitation.org/567W23?url=http://www.cwgc.org/find-war-dead/casualty/9898
 * etc.. a full list of archive types and URLs WP:WEBARCHIVES. -- Green  C  03:13, 2 February 2018 (UTC)
 * Good point. I've amended my code to include a lookbehind. Primefac (talk) 03:22, 2 February 2018 (UTC)
 * Would it overlap with template instances like http://www.cwgc.org/find-war-dead/casualty/9898? --  Green  C  04:10, 2 February 2018 (UTC)
 * There are 5 instances out of over 1000 where the archive URL includes "?url=", so assuming that I remove those five from the list there shouldn't be an issue. I actually thought it would be the other way around... Primefac (talk) 04:15, 2 February 2018 (UTC)
 * Yeah those are WebCite, not too common. The domain was whitelisted by IABot at some point, so it hasn't been auto-archived (in the wiki anyway) which turned out to be a good thing. The 1000 with url might also have yes and ideally it would be set back to no but understandably that would be a more complex bot and not crucial. IABot might be able to detect and make the change not sure.  --  Green  C  04:55, 2 February 2018 (UTC)
 * IABot can, but won't.— CYBERPOWER  ( Chat ) 22:52, 2 February 2018 (UTC)
 * The original request that I made didn't consider web archive URLs. If those instances need fixing manually before any bot run, I am happy to do that. Some URLs are just wrong (for various reasons), and will need manual checking to correct the ID numbers used. If it is possible to output a list of URLs that still return 404 errors, even after this correction is applied, that would help immensely. It is important to limit this to the casualty and cemetery URLs only, not the other URLs from the CWGC site (many of which are also broken). Good examples from the web archive links at Cemeteries and crematoria in Brighton and Hove of the change in the appearance of the CWGC pages from 2013 to the present: 1 vs 2 and 3 vs 4. For the appearance in 2011, see the archived link at Percy Charles Pickard: 5 Carcharoth (talk) 12:35, 2 February 2018 (UTC)
 * Couple more points. For some reason I don't understand, the bottom 44 or so links here are lacking any ID number at all. Those will need to be fixed manually. I also checked the 'https' links as well. Respective numbers are 163, 0, 51, 0. i.e. none of the 'aspx' links are https, and only a few of the correct ones are https. Carcharoth (talk) 21:02, 2 February 2018 (UTC)
 * If they don't have a numerical value in the URL, then they won't be picked up. The regex is only looking for digits. Primefac (talk) 15:08, 3 February 2018 (UTC)
 * I have have checked the list of incorrect URLs and those all have a numerical value in the URL. The ones with the numerical values missing are in the 'correct' form - I will fix them manually. Carcharoth (talk) 14:49, 4 February 2018 (UTC)


 * Gen fixes? Yes or no?— CYBERPOWER  ( Chat ) 22:55, 2 February 2018 (UTC)
 * No. Primefac (talk) 15:07, 3 February 2018 (UTC)
 * — CYBERPOWER  ( Chat ) 16:59, 3 February 2018 (UTC)
 * - Edits. Note that I did 25 of each URL. Primefac (talk) 18:06, 3 February 2018 (UTC)
 * I've looked through most of those and they all look fine to me in terms of fixing the URLs (of course, other fixes may be needed, beyond the scope of the bot). Carcharoth (talk) 14:49, 4 February 2018 (UTC)
 * Headbomb {t · c · p · b} 01:29, 8 February 2018 (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.