Wikidata:Requests for permissions/Bot/bitbotje
- The following discussion is closed. Please do not modify it. Subsequent comments should be made in a new section. A summary of the conclusions reached follows.
- Approved --Lymantria (talk) 17:32, 9 March 2023 (UTC)[reply]
bitbotje (talk • contribs • new items • new lexemes • SUL • Block log • User rights log • User rights • xtools)
Operator: bdijkstra (talk • contribs • logs)
Task/s: Property MovieMeter film ID (P1970) has a suggested constraint that the item should have a Dutch ('nl') label. The MovieMeter website has suitable labels and provides an API for structured data access. I have a script that reads the relevant section in Wikidata:Database reports/Constraint violations/P1970 and for each listed item does an API call to moviemeter.nl and adds a label.
Code: I could share the Python/pywikibot code once I've started a test run.
Function details: For each item listed on Wikidata:Database reports/Constraint violations/P1970#"Label in 'nl' language" violations that doesn't already have a label, check its best non-deprecated P1970 value, construct and perform a moviemeter.nl API call, read & parse the resulting JSON, set the "display_title" value as a label and optionally set the "alternative_title" value as an alias (if non-null and different from display_title and not already present in the aliases).
--bdijkstra (overleg) 16:47, 2 March 2023 (UTC)[reply]
- seems reasonable. can we see test edits? BrokenSegue (talk) 17:38, 2 March 2023 (UTC)[reply]
- See these 50 edits. bdijkstra (overleg) 19:33, 2 March 2023 (UTC)[reply]
- generally LGTM. BrokenSegue (talk) 22:00, 2 March 2023 (UTC)[reply]
- See these 50 edits. bdijkstra (overleg) 19:33, 2 March 2023 (UTC)[reply]