While trying to use test.wikidata.org to play with pywikibot-Wikidata in PAWS we get an error EntityTypeUnknownException: DataSite("test", "wikidata") does not support entity type "item"
import pywikibot site = pywikibot.Site("test", "wikidata") def create_item(site, label_dict): new_item = pywikibot.ItemPage(site) new_item.editLabels(labels=label_dict, summary="Setting labels") # Add description here or in another function return new_item.getID() some_labels = {"en": "Hamburg Main Station", "de": "Hamburg Hauptbahnhof"} new_item_id = create_item(site, some_labels) --------------------------------------------------------------------------- EntityTypeUnknownException Traceback (most recent call last) <ipython-input-10-07e996cb8911> in <module> 9 10 some_labels = {"en": "Hamburg Main Station", "de": "Hamburg Hauptbahnhof"} ---> 11 new_item_id = create_item(site, some_labels) <ipython-input-10-07e996cb8911> in create_item(site, label_dict) 3 4 def create_item(site, label_dict): ----> 5 new_item = pywikibot.ItemPage(site) 6 new_item.editLabels(labels=label_dict, summary="Setting labels") 7 # Add description here or in another function /srv/paws/pwb/pywikibot/page.py in __init__(self, site, title, ns) 4347 """ 4348 if ns is None: -> 4349 ns = site.item_namespace 4350 # Special case for empty item. 4351 if title is None or title == '-1': /srv/paws/pwb/pywikibot/site.py in item_namespace(self) 7524 raise EntityTypeUnknownException( 7525 '%r does not support entity type "item"' -> 7526 % self) 7527 7528 @property EntityTypeUnknownException: DataSite("test", "wikidata") does not support entity type "item"