unified-iso: Handle missing paths in metadata
For empty variants the path is no longer stored, so we need to handle the possible exception. This has no effect on the actual result, as if the path was empty, we would bail anyway on missing .treeinfo. Signed-off-by: Lubomír Sedlář <lsedlar@redhat.com>
This commit is contained in:
parent
2f5d6d7dcd
commit
f6121f0887
1 changed files with 5 additions and 1 deletions
|
|
@ -126,7 +126,11 @@ class UnifiedISO(object):
|
|||
for variant in self.ci.get_variants(recursive=False):
|
||||
for arch in variant.arches:
|
||||
print("Processing: {0}.{1}".format(variant.uid, arch))
|
||||
tree_dir = os.path.join(self.compose_path, variant.paths.os_tree[arch])
|
||||
try:
|
||||
tree_dir = os.path.join(self.compose_path, variant.paths.os_tree[arch])
|
||||
except KeyError:
|
||||
# The path in metadata is missing: no content there
|
||||
continue
|
||||
|
||||
ti = productmd.treeinfo.TreeInfo()
|
||||
try:
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue