https://bugzilla.wikimedia.org/show_bug.cgi?id=62008
Bug ID: 62008
Summary: Add commonsMedia to harvest_template
Product: Pywikibot
Version: core (2.0)
Hardware: All
OS: All
Status: NEW
Severity: normal
Priority: Unprioritized
Component: Wikidata
Assignee: [email protected]
Reporter: [email protected]
Web browser: ---
Mobile Platform: ---
As pointed out in
https://www.wikidata.org/wiki/User:Underlying_lk/sandbox#commonsMedia_support_in_harvest_template
, it should be relatively easy to add image support.
elif claim.getType() == 'commonsMedia':
mediasite = pywikibot.Site("commons", "commons")
image = pywikibot.ImagePage(mediasite, value)
claim.setTarget(image)
Instead of using ImagePage I think Link() should be used.
--
You are receiving this mail because:
You are on the CC list for the bug.
_______________________________________________
Wikibugs-l mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/wikibugs-l