mirror of
https://pagure.io/fedora-qa/createhdds.git
synced 2024-11-28 09:03:08 +00:00
Move the 'unknown' image check below the renaming gubbins
Signed-off-by: Adam Williamson <awilliam@redhat.com>
This commit is contained in:
parent
6fbe122c0c
commit
841fdf1ffb
@ -605,11 +605,6 @@ def check(hdds, nextrel=None):
|
||||
unknown = []
|
||||
# Get the list of all 'expected' images
|
||||
expected = get_all_images(hdds, nextrel=nextrel)
|
||||
# Get the list of all present image files
|
||||
files = set(fl for fl in os.listdir('.') if fl.startswith('disk') and fl.endswith('img'))
|
||||
# Compare present images vs. expected images to produce 'unknown'
|
||||
expnames = set(img.filename for img in expected)
|
||||
unknown = list(files.difference(expnames))
|
||||
|
||||
# Now determine if images are absent or outdated
|
||||
for img in expected:
|
||||
@ -628,6 +623,12 @@ def check(hdds, nextrel=None):
|
||||
continue
|
||||
current.append(img)
|
||||
|
||||
# Get the list of all present image files
|
||||
files = set(fl for fl in os.listdir('.') if fl.startswith('disk') and (fl.endswith('img') or fl.endswith('qcow2')))
|
||||
# Compare present images vs. expected images to produce 'unknown'
|
||||
expnames = set(img.filename for img in expected)
|
||||
unknown = list(files.difference(expnames))
|
||||
|
||||
logger.debug("Current images: %s", ', '.join([img.filename for img in current]))
|
||||
logger.debug("Missing images: %s", ', '.join([img.filename for img in missing]))
|
||||
logger.debug("Outdated images: %s", ', '.join([img.filename for img in outdated]))
|
||||
|
Loading…
Reference in New Issue
Block a user