diff --git a/swh/lister/nixguix/lister.py b/swh/lister/nixguix/lister.py index 89bf4a84929386c8be583b765370ca104699f636..671e40d4a180e5bc37c156dea25ebc4b609a255c 100644 --- a/swh/lister/nixguix/lister.py +++ b/swh/lister/nixguix/lister.py @@ -262,9 +262,7 @@ def is_tarball( if location: # It's not always present logger.debug("Location: %s", location) try: - # FIXME: location is also returned as it's considered the true - # origin, true enough? - return _is_tarball(location), location + return _is_tarball(location), url except ArtifactWithoutExtension: logger.warning( "Still cannot detect extension through location <%s>...", diff --git a/swh/lister/nixguix/tests/test_lister.py b/swh/lister/nixguix/tests/test_lister.py index 180fe4fe54b2c6b7ab454e2fe044e4f15e8ffced..ab976f28c0ee028fa3af65cbb87645b9060d9796 100644 --- a/swh/lister/nixguix/tests/test_lister.py +++ b/swh/lister/nixguix/tests/test_lister.py @@ -189,7 +189,7 @@ def test_is_tarball_complex_with_location_result( is_tar, origin = is_tarball(urls, requests) assert is_tar == expected_result if is_tar: - assert origin == fallback_url + assert origin == url @pytest.mark.parametrize(