I'm trying to add a Claim to a wikidata item, but instead of adding it and keeping all other claims with same property, the tool deletes all other claims and replaces them.
Specifically,
flametti = wbi.item.get(entity_id='Q105624761')
flametti.claims.get(PROPS['title'])
shows the entity has several claims about regarding title, two of them in German, but none in English (yet) so I'd like to add it:
title_en_string = datatypes.MonolingualText(text='Flametti, or The Dandyism of the Poor', language='en', prop_nr=PROPS['title'])
flametti.claims.add(title_en_string)
If I do flametti.claims.get(PROPS['title']) indeed the local object it has four or so titles, now, as it should.
But after
flametti.write(login=login_instance)
the entity ends up having only one title, the one I just added. Is this expected behaviour? What am I doing wrong?
I'm trying to add a Claim to a wikidata item, but instead of adding it and keeping all other claims with same property, the tool deletes all other claims and replaces them.
Specifically,
flametti = wbi.item.get(entity_id='Q105624761')flametti.claims.get(PROPS['title'])shows the entity has several claims about regarding title, two of them in German, but none in English (yet) so I'd like to add it:
title_en_string = datatypes.MonolingualText(text='Flametti, or The Dandyism of the Poor', language='en', prop_nr=PROPS['title'])flametti.claims.add(title_en_string)If I do
flametti.claims.get(PROPS['title'])indeed the local object it has four or so titles, now, as it should.But after
flametti.write(login=login_instance)the entity ends up having only one title, the one I just added. Is this expected behaviour? What am I doing wrong?