diff --git a/requirements-swh.txt b/requirements-swh.txt --- a/requirements-swh.txt +++ b/requirements-swh.txt @@ -1,6 +1,6 @@ swh.core >= 0.0.95 swh.indexer >= 0.0.171 -swh.model >= 0.3.4 +swh.model >= 0.3.5 swh.scheduler >= 0.1.1 swh.search >= 0.0.4 swh.storage >= 0.8.0 diff --git a/swh/web/tests/views.py b/swh/web/tests/views.py --- a/swh/web/tests/views.py +++ b/swh/web/tests/views.py @@ -16,6 +16,7 @@ from swh.model import from_disk from swh.model.hashutil import hash_to_hex from swh.model.model import Content +from swh.model.from_disk import DiskBackedContent from swh.web.common.highlightjs import get_hljs_language_from_filename from swh.web.tests.data import get_tests_data @@ -44,7 +45,7 @@ contents = [] for name, obj in directory.items(): - if isinstance(obj, from_disk.Content): + if obj.object_type in [Content.object_type, DiskBackedContent.object_type]: c = obj.to_model().with_data().to_dict() c["status"] = "visible" sha1 = hash_to_hex(c["sha1"])