Page MenuHomeSoftware Heritage

Jenkins > .tox.py3.lib.python3.7.site-packages.swh.provenance.tests.test_archive_interface::test_archive_interface[cmdbts2]
Failed

TEST RESULT

Run At
Aug 31 2022, 5:38 PM
Details
repo = 'cmdbts2' archive = <swh.provenance.storage.archive.ArchiveStorage object at 0x7f9b7bc7c3c8> @pytest.mark.parametrize( "repo", ("cmdbts2", "out-of-order", "with-merges"), ) def test_archive_interface(repo: str, archive: ArchiveInterface) -> None: # read data/README.md for more details on how these datasets are generated data = load_repo_data(repo) fill_storage(archive.storage, data) # test against ArchiveStorage archive_api = ArchiveStorage(archive.storage) check_directory_ls(archive, archive_api, data) check_revision_get_some_outbound_edges(archive, archive_api, data) check_snapshot_get_heads(archive, archive_api, data) # test against ArchivePostgreSQL assert isinstance(archive.storage, Storage) dsn = archive.storage.get_db().conn.dsn with BaseDb.connect(dsn).conn as conn: BaseDb.adapt_conn(conn) archive_direct = ArchivePostgreSQL(conn) check_directory_ls(archive, archive_direct, data) check_revision_get_some_outbound_edges(archive, archive_direct, data) check_snapshot_get_heads(archive, archive_direct, data) # test against ArchiveGraph nodes, edges = get_graph_data(data) > graph = NaiveClient(nodes=nodes, edges=edges) .tox/py3/lib/python3.7/site-packages/swh/provenance/tests/test_archive_interface.py:237: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ .tox/py3/lib/python3.7/site-packages/swh/graph/http_naive_client.py:115: in __init__ self.graph = Graph(nodes, edges) _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = <swh.graph.http_naive_client.Graph object at 0x7f9b7b1fc400> nodes = [CoreSWHID.from_string('swh:1:cnt:5d322b152c491c915079caa3d8af22ab4d02d5cb'), CoreSWHID.from_string('swh:1:dir:6b2d11d...211f77c6c7f1f742020e483b506b82b5d6'), CoreSWHID.from_string('swh:1:dir:c86d2f588234098642ef6f33ca662a6a9de865bc'), ...] edges = [(CoreSWHID.from_string('swh:1:dir:8084b999790aab88e5119915ea1083e747a3f42f'), ExtendedSWHID.from_string('swh:1:dir:8b...8cd791abe83527becee73d3c64e86'), ExtendedSWHID.from_string('swh:1:rev:c0d8929936631ecbcf9147be6b8aa13b13b014e4')), ...] def __init__( self, nodes: List[SWHIDlike], edges: List[Tuple[SWHIDlike, SWHIDlike]] ): self.nodes = [str(node) for node in nodes] self.forward_edges: Dict[str, List[str]] = {} self.backward_edges: Dict[str, List[str]] = {} for node in nodes: self.forward_edges[str(node)] = [] self.backward_edges[str(node)] = [] for (src, dst) in edges: self.forward_edges[str(src)].append(str(dst)) > self.backward_edges[str(dst)].append(str(src)) E KeyError: 'swh:1:rel:30b921df954fa7bcfa1ba31ccb80eb1d35139d67' .tox/py3/lib/python3.7/site-packages/swh/graph/http_naive_client.py:282: KeyError