source/containers-storage: error message

An error message has changed in skopeo [1] (or one of it's underlying
libraries). This new version is now in our CI so let's fix our tests.

[1]: f423f01d1b

Signed-off-by: Simon de Vlieger <supakeen@redhat.com>
This commit is contained in:
Simon de Vlieger 2025-06-16 12:30:06 +02:00 committed by Brian C. Lane
parent 83b1b48108
commit cde6e1e114

View file

@ -80,7 +80,8 @@ class ContainersStorageSource(sources.SourceService):
# string not matching not ideal - this is ErrNotAnImage
# which is unchanged since 2016 (added in ee99172905 in
# containers/storage)
if "identifier is not an image" in res.stderr:
# update: 2025, the message did change!
if "identifier is not an image" in res.stderr or "does not resolve to an image ID" in res.stderr:
return False
raise RuntimeError(f"unknown skopeo error: {res.stderr}")