View text source at Wikipedia
Operator: Philroc (talk · contribs · SUL · edit count · logs · page moves · block log · rights log · ANI search)
Time filed: 02:04, Friday, March 18, 2022 (UTC)
Automatic, Supervised, or Manual: Automatic
Programming language(s): Python
Source code available: Here
Function overview: Replace string values in {{C-SPAN}} transclusions with numerical IDs to prevent link rot.
Links to relevant discussions (where appropriate): Wikipedia:Bot requests#Bot action to convert Template:C-SPAN from strings to numeric values for identifier fix
Edit period(s): One-time run
Estimated number of pages affected: 10,985
Exclusion compliant (Yes/No): Yes
Already has a bot flag (Yes/No): No
Function details: This bot will iterate through the articles in Category:Pages using non-numeric C-SPAN identifiers, all of which provide an outdated string value rather than a numerical ID as the first and sole parameter for {{C-SPAN}}. If the link generated by the template on a certain article is still valid, the bot will assign the ID of whatever page it redirects to as the template's new first parameter. If the opposite is true, the parameter will be removed entirely pending a manual review by myself.
Comment: The C-SPAN template was recently modified to support this string to numeric ID transition in coordination with Wikidata's C-SPAN person string ID (deprecated) (P2190) format change. The template has a fallback to Wikidata when the parameter is empty, and if no Wikidata value is present the Template automatically adds orphan template uses to the maintenance category Category:C-SPAN template failing to display for collaborative review and cleanup. Wolfgang8741 says: If not you, then who? (talk) 03:10, 18 March 2022 (UTC)[reply]