Repository: osbuild/osbuild
Pull request #581 (2021-02-12 16:59:20)

Rename the org.osbuild.files source to org.osbuild.curl
Done in two steps, i.e. the two commits. I quote their commit messages:

1) Instead of supplying the full cache dir, i.e. the directory in the store where the source will place the fetched resources, to the source, only supply the root folder of the cache and let the source itself create the desired sub-directory. This allows the source to determine what type of resource it provides and makes the path independent of the name of the source: a `org.osbuild.curl` source can place files into the `org.osbuild.files` sub-dir. Then the `org.osbuild.files` input can be used to get those from the cache dir.

2) The `org.osbuild.files` source provides files, but might in the future not be the only one that does. Therefore rename it to match the internal tool that is being used to fetch the files. This is done for most other osbuild modules that target tools.
The format v1 loader is adapted to make this change transparent for users of the v1 format, so we are backwards compatible.
Change the MPP depsolve preprocessor so that for format v2 based manifest `org.osbuild.curl` source is used. Also rename the corresponding source test.

NB: the `test/test_fmt_v1.py`test checks that loading and describing the format results in the same manifest that was loaded and thus checks that we internally handle the re-mapping correctly.


Patch:
diff --git a/osbuild/formats/v1.py b/osbuild/formats/v1.py
index d769eda3..7412d661 100644
--- a/osbuild/formats/v1.py
+++ b/osbuild/formats/v1.py
@@ -40,6 +40,12 @@ def describe(manifest: Manifest, *, with_id=False) -> Dict:
 
         return description
 
+    def get_source_name(source):
+        name = source.info.name
+        if name == "org.osbuild.curl":
+            name = "org.osbuild.files"
+        return name
+
     pipeline = describe_pipeline(manifest["tree"])
 
     assembler = manifest.get("assembler")
@@ -51,7 +57,7 @@ def describe(manifest: Manifest, *, with_id=False) -> Dict:
 
     if manifest.sources:
         sources = {
-            s.info.name: s.options
+            get_source_name(s): s.options
             for s in manifest.sources
         }
         description["sources"] = sources
@@ -115,9 +121,12 @@ def load_stage(description: Dict, index: Index, pipeline: Pipeline):
 
 
 def load_source(name: str, description: Dict, index: Index, manifest: Manifest):
+    if name == "org.osbuild.files":
+        name = "org.osbuild.curl"
+
     info = index.get_module_info("Source", name)
 
-    if name == "org.osbuild.files":
+    if name == "org.osbuild.curl":
         items = description["urls"]
     elif name == "org.osbuild.ostree":
         items = description["commits"]
@@ -268,6 +277,8 @@ def validate(manifest: Dict, index: Index) -> ValidationResult:
     # sources
     sources = manifest.get("sources", {})
     for name, source in sources.items():
+        if name == "org.osbuild.files":
+            name = "org.osbuild.curl"
         schema = index.get_schema("Source", name)
         res = schema.validate(source)
         result.merge(res, path=["sources", name])
diff --git a/osbuild/sources.py b/osbuild/sources.py
index 90ca1de9..384180af 100644
--- a/osbuild/sources.py
+++ b/osbuild/sources.py
@@ -20,7 +20,7 @@ class Source:
 
     def download(self, store: ObjectStore, libdir: PathLike):
         source = self.info.name
-        cache = os.path.join(store.store, "sources", source)
+        cache = os.path.join(store.store, "sources")
         msg = {
             "items": self.items,
             "options": self.options,
@@ -73,7 +73,7 @@ class SourcesServer(api.BaseAPI):
         msg = {
             "items": {},
             "options": self.options.get(source, {}),
-            "cache": f"{self.cache}/{source}",
+            "cache": self.cache,
             "output": f"{self.output}/{source}",
             "checksums": checksums,
             "libdir": self.libdir
diff --git a/sources/org.osbuild.files b/sources/org.osbuild.curl
similarity index 99%
rename from sources/org.osbuild.files
rename to sources/org.osbuild.curl
index 316f3469..842d080c 100755
--- a/sources/org.osbuild.files
+++ b/sources/org.osbuild.curl
@@ -235,6 +235,7 @@ def export(checksums, cache, output):
 
 
 def main(urls, options, checksums, cache, output):
+    cache = os.path.join(cache, "org.osbuild.files")
     download_only = not output
 
     if not urls:
diff --git a/sources/org.osbuild.ostree b/sources/org.osbuild.ostree
index a73a069c..caf0e489 100755
--- a/sources/org.osbuild.ostree
+++ b/sources/org.osbuild.ostree
@@ -127,6 +127,7 @@ def export(checksums, cache, output):
 
 
 def main(commits, options, checksums, cache, output):
+    cache = os.path.join(cache, "org.osbuild.ostree")
 
     if not commits:
         commits = options.get("commits", {})
diff --git a/tools/mpp-depsolve.py b/tools/mpp-depsolve.py
index a135da30..f549881d 100755
--- a/tools/mpp-depsolve.py
+++ b/tools/mpp-depsolve.py
@@ -222,7 +222,7 @@ def _manifest_parse_v2(state, manifest):
             todo.append(packages)
 
     sources = _manifest_enter(manifest, "sources", {})
-    files = _manifest_enter(sources, "org.osbuild.files", {})
+    files = _manifest_enter(sources, "org.osbuild.curl", {})
     urls = _manifest_enter(files, "items", {})
 
     state.manifest = manifest


Test patch:
diff --git a/test/data/manifests/f32-build-v2.json b/test/data/manifests/f32-build-v2.json
index 9e1cfb89..edc560ea 100644
--- a/test/data/manifests/f32-build-v2.json
+++ b/test/data/manifests/f32-build-v2.json
@@ -255,7 +255,7 @@
     }
   ],
   "sources": {
-    "org.osbuild.files": {
+    "org.osbuild.curl": {
       "items": {
         "sha256:705bdb96aab3a0f9d9e2ff48ead1208e2dbc1927d713d8637632af936235217b": "https://rpmrepo.osbuild.org/v1/anon/f32/f32-x86_64-fedora-20201010/Packages/a/acl-2.2.53-5.fc32.x86_64.rpm",
         "sha256:c574c5432197acbe08ea15c7837be7577cd0b49902a3e65227792f051d73ce5c": "https://rpmrepo.osbuild.org/v1/anon/f32/f32-x86_64-fedora-20201010/Packages/a/alternatives-1.11-6.fc32.x86_64.rpm",
diff --git a/test/data/manifests/fedora-container.json b/test/data/manifests/fedora-container.json
index 1e3b0290..5c9acc81 100644
--- a/test/data/manifests/fedora-container.json
+++ b/test/data/manifests/fedora-container.json
@@ -479,7 +479,7 @@
     }
   ],
   "sources": {
-    "org.osbuild.files": {
+    "org.osbuild.curl": {
       "items": {
         "sha256:705bdb96aab3a0f9d9e2ff48ead1208e2dbc1927d713d8637632af936235217b": "https://rpmrepo.osbuild.org/v1/anon/f32/f32-x86_64-fedora-20201010/Packages/a/acl-2.2.53-5.fc32.x86_64.rpm",
         "sha256:c574c5432197acbe08ea15c7837be7577cd0b49902a3e65227792f051d73ce5c": "https://rpmrepo.osbuild.org/v1/anon/f32/f32-x86_64-fedora-20201010/Packages/a/alternatives-1.11-6.fc32.x86_64.rpm",
diff --git a/test/data/manifests/fedora-ostree-container.json b/test/data/manifests/fedora-ostree-container.json
index 99c37754..99b1b41f 100644
--- a/test/data/manifests/fedora-ostree-container.json
+++ b/test/data/manifests/fedora-ostree-container.json
@@ -947,7 +947,7 @@
     }
   ],
   "sources": {
-    "org.osbuild.files": {
+    "org.osbuild.curl": {
       "items": {
         "sha256:342bdf0143d9145f8846e1b5c3401685e0d1274b66df39ac8cbfb78013313861": "https://rpmrepo.osbuild.org/v1/anon/f32/f32-x86_64-fedora-20201010/Packages/n/NetworkManager-1.22.10-1.fc32.x86_64.rpm",
         "sha256:fd2a2dd726d855f877296227fb351883d647df28b1b0085f525d87df622d49e4": "https://rpmrepo.osbuild.org/v1/anon/f32/f32-x86_64-fedora-20201010/Packages/n/NetworkManager-libnm-1.22.10-1.fc32.x86_64.rpm",
diff --git a/test/data/sources/org.osbuild.files/cases/empty.json b/test/data/sources/org.osbuild.curl/cases/empty.json
similarity index 100%
rename from test/data/sources/org.osbuild.files/cases/empty.json
rename to test/data/sources/org.osbuild.curl/cases/empty.json
diff --git a/test/data/sources/org.osbuild.files/cases/invalid_checksum.json b/test/data/sources/org.osbuild.curl/cases/invalid_checksum.json
similarity index 100%
rename from test/data/sources/org.osbuild.files/cases/invalid_checksum.json
rename to test/data/sources/org.osbuild.curl/cases/invalid_checksum.json
diff --git a/test/data/sources/org.osbuild.files/cases/missing_file.json b/test/data/sources/org.osbuild.curl/cases/missing_file.json
similarity index 100%
rename from test/data/sources/org.osbuild.files/cases/missing_file.json
rename to test/data/sources/org.osbuild.curl/cases/missing_file.json
diff --git a/test/data/sources/org.osbuild.files/cases/success.json b/test/data/sources/org.osbuild.curl/cases/success.json
similarity index 100%
rename from test/data/sources/org.osbuild.files/cases/success.json
rename to test/data/sources/org.osbuild.curl/cases/success.json
diff --git a/test/data/sources/org.osbuild.files/cases/unknown_checksum.json b/test/data/sources/org.osbuild.curl/cases/unknown_checksum.json
similarity index 100%
rename from test/data/sources/org.osbuild.files/cases/unknown_checksum.json
rename to test/data/sources/org.osbuild.curl/cases/unknown_checksum.json
diff --git a/test/data/sources/org.osbuild.files/data/a b/test/data/sources/org.osbuild.curl/data/a
similarity index 100%
rename from test/data/sources/org.osbuild.files/data/a
rename to test/data/sources/org.osbuild.curl/data/a
diff --git a/test/data/sources/org.osbuild.files/data/b b/test/data/sources/org.osbuild.curl/data/b
similarity index 100%
rename from test/data/sources/org.osbuild.files/data/b
rename to test/data/sources/org.osbuild.curl/data/b
diff --git a/test/data/sources/org.osbuild.files/data/c b/test/data/sources/org.osbuild.curl/data/c
similarity index 100%
rename from test/data/sources/org.osbuild.files/data/c
rename to test/data/sources/org.osbuild.curl/data/c
diff --git a/test/data/sources/org.osbuild.files/data/d b/test/data/sources/org.osbuild.curl/data/d
similarity index 100%
rename from test/data/sources/org.osbuild.files/data/d
rename to test/data/sources/org.osbuild.curl/data/d
diff --git a/test/data/sources/org.osbuild.files/data/e b/test/data/sources/org.osbuild.curl/data/e
similarity index 100%
rename from test/data/sources/org.osbuild.files/data/e
rename to test/data/sources/org.osbuild.curl/data/e
diff --git a/test/data/sources/org.osbuild.files/data/f b/test/data/sources/org.osbuild.curl/data/f
similarity index 100%
rename from test/data/sources/org.osbuild.files/data/f
rename to test/data/sources/org.osbuild.curl/data/f
diff --git a/test/data/sources/org.osbuild.files/data/g b/test/data/sources/org.osbuild.curl/data/g
similarity index 100%
rename from test/data/sources/org.osbuild.files/data/g
rename to test/data/sources/org.osbuild.curl/data/g
diff --git a/test/data/sources/org.osbuild.files/data/h b/test/data/sources/org.osbuild.curl/data/h
similarity index 100%
rename from test/data/sources/org.osbuild.files/data/h
rename to test/data/sources/org.osbuild.curl/data/h
diff --git a/test/data/sources/org.osbuild.files/data/i b/test/data/sources/org.osbuild.curl/data/i
similarity index 100%
rename from test/data/sources/org.osbuild.files/data/i
rename to test/data/sources/org.osbuild.curl/data/i
diff --git a/test/data/sources/org.osbuild.files/data/j b/test/data/sources/org.osbuild.curl/data/j
similarity index 100%
rename from test/data/sources/org.osbuild.files/data/j
rename to test/data/sources/org.osbuild.curl/data/j
diff --git a/test/data/sources/org.osbuild.files/data/k b/test/data/sources/org.osbuild.curl/data/k
similarity index 100%
rename from test/data/sources/org.osbuild.files/data/k
rename to test/data/sources/org.osbuild.curl/data/k
diff --git a/test/data/sources/org.osbuild.files/data/l b/test/data/sources/org.osbuild.curl/data/l
similarity index 100%
rename from test/data/sources/org.osbuild.files/data/l
rename to test/data/sources/org.osbuild.curl/data/l
diff --git a/test/data/sources/org.osbuild.files/data/m b/test/data/sources/org.osbuild.curl/data/m
similarity index 100%
rename from test/data/sources/org.osbuild.files/data/m
rename to test/data/sources/org.osbuild.curl/data/m
diff --git a/test/data/sources/org.osbuild.files/data/n b/test/data/sources/org.osbuild.curl/data/n
similarity index 100%
rename from test/data/sources/org.osbuild.files/data/n
rename to test/data/sources/org.osbuild.curl/data/n
diff --git a/test/data/sources/org.osbuild.files/data/o b/test/data/sources/org.osbuild.curl/data/o
similarity index 100%
rename from test/data/sources/org.osbuild.files/data/o
rename to test/data/sources/org.osbuild.curl/data/o
diff --git a/test/data/sources/org.osbuild.files/data/p b/test/data/sources/org.osbuild.curl/data/p
similarity index 100%
rename from test/data/sources/org.osbuild.files/data/p
rename to test/data/sources/org.osbuild.curl/data/p
diff --git a/test/data/sources/org.osbuild.files/data/q b/test/data/sources/org.osbuild.curl/data/q
similarity index 100%
rename from test/data/sources/org.osbuild.files/data/q
rename to test/data/sources/org.osbuild.curl/data/q
diff --git a/test/data/sources/org.osbuild.files/data/r b/test/data/sources/org.osbuild.curl/data/r
similarity index 100%
rename from test/data/sources/org.osbuild.files/data/r
rename to test/data/sources/org.osbuild.curl/data/r
diff --git a/test/data/sources/org.osbuild.files/data/s b/test/data/sources/org.osbuild.curl/data/s
similarity index 100%
rename from test/data/sources/org.osbuild.files/data/s
rename to test/data/sources/org.osbuild.curl/data/s
diff --git a/test/data/sources/org.osbuild.files/data/t b/test/data/sources/org.osbuild.curl/data/t
similarity index 100%
rename from test/data/sources/org.osbuild.files/data/t
rename to test/data/sources/org.osbuild.curl/data/t
diff --git a/test/data/sources/org.osbuild.files/data/u b/test/data/sources/org.osbuild.curl/data/u
similarity index 100%
rename from test/data/sources/org.osbuild.files/data/u
rename to test/data/sources/org.osbuild.curl/data/u
diff --git a/test/data/sources/org.osbuild.files/data/v b/test/data/sources/org.osbuild.curl/data/v
similarity index 100%
rename from test/data/sources/org.osbuild.files/data/v
rename to test/data/sources/org.osbuild.curl/data/v
diff --git a/test/data/sources/org.osbuild.files/data/w b/test/data/sources/org.osbuild.curl/data/w
similarity index 100%
rename from test/data/sources/org.osbuild.files/data/w
rename to test/data/sources/org.osbuild.curl/data/w
diff --git a/test/data/sources/org.osbuild.files/data/x b/test/data/sources/org.osbuild.curl/data/x
similarity index 100%
rename from test/data/sources/org.osbuild.files/data/x
rename to test/data/sources/org.osbuild.curl/data/x
diff --git a/test/data/sources/org.osbuild.files/data/y b/test/data/sources/org.osbuild.curl/data/y
similarity index 100%
rename from test/data/sources/org.osbuild.files/data/y
rename to test/data/sources/org.osbuild.curl/data/y
diff --git a/test/data/sources/org.osbuild.files/data/z b/test/data/sources/org.osbuild.curl/data/z
similarity index 100%
rename from test/data/sources/org.osbuild.files/data/z
rename to test/data/sources/org.osbuild.curl/data/z
diff --git a/test/data/sources/org.osbuild.curl/sources.json b/test/data/sources/org.osbuild.curl/sources.json
new file mode 100644
index 00000000..f7b0a5ef
--- /dev/null
+++ b/test/data/sources/org.osbuild.curl/sources.json
@@ -0,0 +1,34 @@
+{
+  "org.osbuild.curl": {
+    "urls": {
+      "sha256:87428fc522803d31065e7bce3cf03fe475096631e5e07bbd7a0fde60c4cf25c7": "http://localhost/sources/org.osbuild.curl/data/a",
+      "sha256:0263829989b6fd954f72baaf2fc64bc2e2f01d692d4de72986ea808f6e99813f": "http://localhost/sources/org.osbuild.curl/data/b",
+      "sha256:a3a5e715f0cc574a73c3f9bebb6bc24f32ffd5b67b387244c2c909da779a1478": "http://localhost/sources/org.osbuild.curl/data/c",
+      "sha256:8d74beec1be996322ad76813bafb92d40839895d6dd7ee808b17ca201eac98be": "http://localhost/sources/org.osbuild.curl/data/d",
+      "sha256:a2bbdb2de53523b8099b37013f251546f3d65dbe7a0774fa41af0a4176992fd4": "http://localhost/sources/org.osbuild.curl/data/e",
+      "sha256:092fcfbbcfca3b5be7ae1b5e58538e92c35ab273ae13664fed0d67484c8e78a6": "http://localhost/sources/org.osbuild.curl/data/f",
+      "sha256:768c71d785bf6bbbf8c4d6af6582041f2659027140a962cd0c55b11eddfd5e3d": "http://localhost/sources/org.osbuild.curl/data/g",
+      "sha256:91ee5e9f42ba3d34e414443b36a27b797a56a47aad6bb1e4c1769e69c77ce0ca": "http://localhost/sources/org.osbuild.curl/data/h",
+      "sha256:50c393f158c3de2db92fa9661bfb00eda5b67c3a777c88524ed3417509631625": "http://localhost/sources/org.osbuild.curl/data/i",
+      "sha256:cee00b08a818db87e17e703273818e5194f83280e1ef3eae9214ff14675d9e6d": "http://localhost/sources/org.osbuild.curl/data/j",
+      "sha256:19732980d68fbd00358a0a4d98246c960400b87e4fa2a2e155db98be2b42ed6c": "http://localhost/sources/org.osbuild.curl/data/k",
+      "sha256:6d7ebc44c5bc26207e62f4f628f912e1a0f41ed11764891aa7dd99eab83228e7": "http://localhost/sources/org.osbuild.curl/data/l",
+      "sha256:01a60e35df88d8b49546cb3f8f4ba4f406870f9b8e1f394c9d48ab73548d748d": "http://localhost/sources/org.osbuild.curl/data/m",
+      "sha256:a4fb621495a0122493b2203591c448903c472e306a1ede54fabad829e01075c0": "http://localhost/sources/org.osbuild.curl/data/n",
+      "sha256:7427d152005f9ed0fa31c76ef9963cf4bb47dce6e2768111d9eb0edbfe59c704": "http://localhost/sources/org.osbuild.curl/data/o",
+      "sha256:fd6641673e7f3bf6e80e4bc5401fcb2821a1e117206c8e1c65cef23a58dc37ff": "http://localhost/sources/org.osbuild.curl/data/p",
+      "sha256:4adc33bd9fe74303c344be46e5916d65182fb218e248fe80452ab3f025b06c64": "http://localhost/sources/org.osbuild.curl/data/q",
+      "sha256:8e54b0ca18020275e4aef1ca0eb5e197e066c065c1864817652a8a39c55402cd": "http://localhost/sources/org.osbuild.curl/data/r",
+      "sha256:cbc80bb5c0c0f8944bf73b3a429505ac5cde16644978bc9a1e74c5755f8ca556": "http://localhost/sources/org.osbuild.curl/data/s",
+      "sha256:fe8edeeb98cc6d3b93cf2d57000254b84bd9eba34b4df7ce4b87db8b937b7703": "http://localhost/sources/org.osbuild.curl/data/t",
+      "sha256:ea46748e171abd2dd4dba5b86bb6589334d86bba2df8d50cbb16b36c83b0856a": "http://localhost/sources/org.osbuild.curl/data/u",
+      "sha256:73324e1ab1db72ee9eb4fdf1c90a586d67e00ab58330d1cbfea26ecd0a77fa4d": "http://localhost/sources/org.osbuild.curl/data/v",
+      "sha256:cf945b5236e101dbe0471d5200f28b1ae64f21c1f35bf55fcf40cd0fe42cd8e7": "http://localhost/sources/org.osbuild.curl/data/w",
+      "sha256:73cb3858a687a8494ca3323053016282f3dad39d42cf62ca4e79dda2aac7d9ac": "http://localhost/sources/org.osbuild.curl/data/x",
+      "sha256:3bb2abb69ebb27fbfe63c7639624c6ec5e331b841a5bc8c3ebc10b9285e90877": "http://localhost/sources/org.osbuild.curl/data/y",
+      "sha256:c865f6c5ab8d1b0bcd383a5e1e3879d22681c96bf462c269b7581d523fbe70ab": "http://localhost/sources/org.osbuild.curl/data/z",
+      "sha256:aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa": "http://localhost/sources/org.osbuild.curl/data/a",
+      "sha256:bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb": "http://localhost/sources/org.osbuild.curl/data/missing"
+    }
+  }
+}
diff --git a/test/data/sources/org.osbuild.files/sources.json b/test/data/sources/org.osbuild.files/sources.json
deleted file mode 100644
index 581a6ed4..00000000
--- a/test/data/sources/org.osbuild.files/sources.json
+++ /dev/null
@@ -1,34 +0,0 @@
-{
-  "org.osbuild.files": {
-    "urls": {
-      "sha256:87428fc522803d31065e7bce3cf03fe475096631e5e07bbd7a0fde60c4cf25c7": "http://localhost/sources/org.osbuild.files/data/a",
-      "sha256:0263829989b6fd954f72baaf2fc64bc2e2f01d692d4de72986ea808f6e99813f": "http://localhost/sources/org.osbuild.files/data/b",
-      "sha256:a3a5e715f0cc574a73c3f9bebb6bc24f32ffd5b67b387244c2c909da779a1478": "http://localhost/sources/org.osbuild.files/data/c",
-      "sha256:8d74beec1be996322ad76813bafb92d40839895d6dd7ee808b17ca201eac98be": "http://localhost/sources/org.osbuild.files/data/d",
-      "sha256:a2bbdb2de53523b8099b37013f251546f3d65dbe7a0774fa41af0a4176992fd4": "http://localhost/sources/org.osbuild.files/data/e",
-      "sha256:092fcfbbcfca3b5be7ae1b5e58538e92c35ab273ae13664fed0d67484c8e78a6": "http://localhost/sources/org.osbuild.files/data/f",
-      "sha256:768c71d785bf6bbbf8c4d6af6582041f2659027140a962cd0c55b11eddfd5e3d": "http://localhost/sources/org.osbuild.files/data/g",
-      "sha256:91ee5e9f42ba3d34e414443b36a27b797a56a47aad6bb1e4c1769e69c77ce0ca": "http://localhost/sources/org.osbuild.files/data/h",
-      "sha256:50c393f158c3de2db92fa9661bfb00eda5b67c3a777c88524ed3417509631625": "http://localhost/sources/org.osbuild.files/data/i",
-      "sha256:cee00b08a818db87e17e703273818e5194f83280e1ef3eae9214ff14675d9e6d": "http://localhost/sources/org.osbuild.files/data/j",
-      "sha256:19732980d68fbd00358a0a4d98246c960400b87e4fa2a2e155db98be2b42ed6c": "http://localhost/sources/org.osbuild.files/data/k",
-      "sha256:6d7ebc44c5bc26207e62f4f628f912e1a0f41ed11764891aa7dd99eab83228e7": "http://localhost/sources/org.osbuild.files/data/l",
-      "sha256:01a60e35df88d8b49546cb3f8f4ba4f406870f9b8e1f394c9d48ab73548d748d": "http://localhost/sources/org.osbuild.files/data/m",
-      "sha256:a4fb621495a0122493b2203591c448903c472e306a1ede54fabad829e01075c0": "http://localhost/sources/org.osbuild.files/data/n",
-      "sha256:7427d152005f9ed0fa31c76ef9963cf4bb47dce6e2768111d9eb0edbfe59c704": "http://localhost/sources/org.osbuild.files/data/o",
-      "sha256:fd6641673e7f3bf6e80e4bc5401fcb2821a1e117206c8e1c65cef23a58dc37ff": "http://localhost/sources/org.osbuild.files/data/p",
-      "sha256:4adc33bd9fe74303c344be46e5916d65182fb218e248fe80452ab3f025b06c64": "http://localhost/sources/org.osbuild.files/data/q",
-      "sha256:8e54b0ca18020275e4aef1ca0eb5e197e066c065c1864817652a8a39c55402cd": "http://localhost/sources/org.osbuild.files/data/r",
-      "sha256:cbc80bb5c0c0f8944bf73b3a429505ac5cde16644978bc9a1e74c5755f8ca556": "http://localhost/sources/org.osbuild.files/data/s",
-      "sha256:fe8edeeb98cc6d3b93cf2d57000254b84bd9eba34b4df7ce4b87db8b937b7703": "http://localhost/sources/org.osbuild.files/data/t",
-      "sha256:ea46748e171abd2dd4dba5b86bb6589334d86bba2df8d50cbb16b36c83b0856a": "http://localhost/sources/org.osbuild.files/data/u",
-      "sha256:73324e1ab1db72ee9eb4fdf1c90a586d67e00ab58330d1cbfea26ecd0a77fa4d": "http://localhost/sources/org.osbuild.files/data/v",
-      "sha256:cf945b5236e101dbe0471d5200f28b1ae64f21c1f35bf55fcf40cd0fe42cd8e7": "http://localhost/sources/org.osbuild.files/data/w",
-      "sha256:73cb3858a687a8494ca3323053016282f3dad39d42cf62ca4e79dda2aac7d9ac": "http://localhost/sources/org.osbuild.files/data/x",
-      "sha256:3bb2abb69ebb27fbfe63c7639624c6ec5e331b841a5bc8c3ebc10b9285e90877": "http://localhost/sources/org.osbuild.files/data/y",
-      "sha256:c865f6c5ab8d1b0bcd383a5e1e3879d22681c96bf462c269b7581d523fbe70ab": "http://localhost/sources/org.osbuild.files/data/z",
-      "sha256:aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa": "http://localhost/sources/org.osbuild.files/data/a",
-      "sha256:bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb": "http://localhost/sources/org.osbuild.files/data/missing"
-    }
-  }
-}
diff --git a/test/mod/test_fmt_v2.py b/test/mod/test_fmt_v2.py
index 21087fde..cf862830 100644
--- a/test/mod/test_fmt_v2.py
+++ b/test/mod/test_fmt_v2.py
@@ -12,7 +12,7 @@ import osbuild.meta
 BASIC_PIPELINE = {
     "version": "2",
     "sources": {
-        "org.osbuild.files": {
+        "org.osbuild.curl": {
             "items": {
                 "sha256:6eeebf21f245bf0d6f58962dc49b6dfb51f55acb6a595c6b9cbe9628806b80a4":
                 "https://internet/curl-7.69.1-1.fc32.x86_64.rpm",