self = <swh.indexer.tests.test_fossology_license.TestFossologyLicenseIndexer testMethod=test_index>
def test_index(self):
"""Known sha1 have their data indexed
"""
sha1s = [self.id0, self.id1, self.id2]
# when
> self.indexer.run(sha1s, policy_update="update-dups")
.tox/py3/lib/python3.7/site-packages/swh/indexer/tests/utils.py:655:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
.tox/py3/lib/python3.7/site-packages/swh/indexer/indexer.py:322: in run
summary = self.persist_index_computations(results, policy_update)
.tox/py3/lib/python3.7/site-packages/swh/indexer/fossology_license.py:134: in persist_index_computations
results, conflict_update=(policy_update == "update-dups")
.tox/py3/lib/python3.7/site-packages/swh/indexer/storage/in_memory.py:365: in content_fossology_license_add
added = self._licenses.add(licenses, conflict_update)
.tox/py3/lib/python3.7/site-packages/swh/indexer/storage/in_memory.py:211: in add
check_id_duplicates(data)
.tox/py3/lib/python3.7/site-packages/swh/indexer/storage/__init__.py:92: in check_id_duplicates
counter = Counter(tuple(sorted(item.unique_key().items())) for item in data)
/usr/lib/python3.7/collections/__init__.py:566: in __init__
self.update(*args, **kwds)
/usr/lib/python3.7/collections/__init__.py:653: in update
_count_elements(self, iterable)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
.0 = <list_iterator object at 0x7fa6b4f9e438>
> counter = Counter(tuple(sorted(item.unique_key().items())) for item in data)
E AttributeError: 'dict' object has no attribute 'unique_key'
.tox/py3/lib/python3.7/site-packages/swh/indexer/storage/__init__.py:92: AttributeError
TEST RESULT
TEST RESULT
- Run At
- Oct 7 2020, 11:27 AM