From 1d7e5227f874dc3d2511a73a6f3d69550e62b303 Mon Sep 17 00:00:00 2001 From: Valentin Rothberg Date: Mon, 11 Jan 2021 11:34:23 +0100 Subject: image list: ignore bare manifest list Handle empty/bare manifest lists when listing images. Fixes: #8931 Signed-off-by: Valentin Rothberg --- pkg/domain/infra/abi/images_list.go | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'pkg/domain') diff --git a/pkg/domain/infra/abi/images_list.go b/pkg/domain/infra/abi/images_list.go index c4b0b7712..2d3b9f36a 100644 --- a/pkg/domain/infra/abi/images_list.go +++ b/pkg/domain/infra/abi/images_list.go @@ -44,7 +44,10 @@ func (ir *ImageEngine) List(ctx context.Context, opts entities.ImageListOptions) } e.Labels, err = img.Labels(ctx) if err != nil { - return nil, errors.Wrapf(err, "error retrieving label for image %q: you may need to remove the image to resolve the error", img.ID()) + // Ignore empty manifest lists. + if errors.Cause(err) != libpodImage.ErrImageIsBareList { + return nil, errors.Wrapf(err, "error retrieving label for image %q: you may need to remove the image to resolve the error", img.ID()) + } } ctnrs, err := img.Containers() -- cgit v1.2.3-54-g00ecf