Hi,
I noticed we can have several identical references for the same
statement. Here is an example from Wikidata [1]:
---------8<---------------------------------------------------
'references': [ { 'hash':
'fa278ebfc458360e5aed63d5058cca83c46134f1',
'snaks': { 'P143': [ { 'datatype': 'wikibase-item',
'datavalue': { 'type': 'wikibase-entityid',
'value': { 'entity-type': 'item',
'id': 'Q328',
'numeric-id': 328}},
'hash': 'e4f6d9441d0600513c4533c672b5ab472dc73694',
'property': 'P143',
'snaktype': 'value'}]},
'snaks-order': ['P143']},
{ 'hash': 'fa278ebfc458360e5aed63d5058cca83c46134f1',
'snaks': { 'P143': [ { 'datatype': 'wikibase-item',
'datavalue': { 'type': 'wikibase-entityid',
'value': { 'entity-type': 'item',
'id': 'Q328',
'numeric-id': 328}},
'hash': 'e4f6d9441d0600513c4533c672b5ab472dc73694',
'property': 'P143',
'snaktype': 'value'}]},
---------8<---------------------------------------------------
From what I understood from the docs [2][3], lists in
the JSON
serialized output are actually _sets_. So how can we have the same item
twice in a set? Can I safely ignore the duplicate reference?
Regards,
- Sylvain
[1]:
https://www.wikidata.org/w/api.php?action=wbgetentities&format=json&…
[2]:
https://www.mediawiki.org/wiki/Wikibase/DataModel/JSON#References
[3]:
https://www.mediawiki.org/wiki/Wikibase/DataModel#ReferenceRecords