Skip to content

Can't specify artifact by digest when it's pulled by tag #408

@bitoku

Description

@bitoku

I can't inspect an artifact by its digest, which artifact is pulled by a tag.

❯ podman artifact inspect quay.io/crio/artifact:singlefile
{
     "Manifest": {
          "schemaVersion": 2,
          "mediaType": "application/vnd.oci.image.manifest.v1+json",
          "artifactType": "application/x.test.test.test.v1",
          "config": {
               "mediaType": "application/vnd.oci.empty.v1+json",
               "digest": "sha256:44136fa355b3678a1146ad16f7e8649e94fb4fc21fe77e8310c060f61caaff8a",
               "size": 2,
               "data": "e30="
          },
          "layers": [
               {
                    "mediaType": "application/vnd.oci.image.layer.v1.tar",
                    "digest": "sha256:d1cc3064379fca32757730461bd728cb7de430e46a0046aa59ab55c65be7ce3b",
                    "size": 14,
                    "annotations": {
                         "org.opencontainers.image.title": "artifact.txt"
                    }
               }
          ],
          "annotations": {
               "org.opencontainers.image.created": "2025-03-13T00:12:12Z"
          }
     },
     "Name": "quay.io/crio/artifact:singlefile",
     "Digest": "sha256:d2dbbc46e94529be98d2513fe2a46ef650683af96c584e1287dd966300aaf583"
}

❯ podman artifact inspect quay.io/crio/artifact@sha256:d2dbbc46e94529be98d2513fe2a46ef650683af96c584e1287dd966300aaf583
Error: quay.io/crio/artifact@sha256:d2dbbc46e94529be98d2513fe2a46ef650683af96c584e1287dd966300aaf583: artifact does not exist

After I pull the artifact with its digest, I can specify the artifact by its digest.

❯ podman artifact pull quay.io/crio/artifact@sha256:d2dbbc46e94529be98d2513fe2a46ef650683af96c584e1287dd966300aaf583
Getting image source signatures
Copying blob d1cc3064379f skipped: already exists
Copying config 44136fa355 done   |
Writing manifest to image destination

❯ podman artifact list
REPOSITORY             TAG         DIGEST        SIZE
quay.io/crio/artifact  singlefile  d2dbbc46e945  14B
quay.io/crio/artifact              d2dbbc46e945  14B

❯ podman artifact inspect quay.io/crio/artifact@sha256:d2dbbc46e94529be98d2513fe2a46ef650683af96c584e1287dd966300aaf583
{
     "Manifest": {
          "schemaVersion": 2,
          "mediaType": "application/vnd.oci.image.manifest.v1+json",
          "artifactType": "application/x.test.test.test.v1",
          "config": {
               "mediaType": "application/vnd.oci.empty.v1+json",
               "digest": "sha256:44136fa355b3678a1146ad16f7e8649e94fb4fc21fe77e8310c060f61caaff8a",
               "size": 2,
               "data": "e30="
          },
          "layers": [
               {
                    "mediaType": "application/vnd.oci.image.layer.v1.tar",
                    "digest": "sha256:d1cc3064379fca32757730461bd728cb7de430e46a0046aa59ab55c65be7ce3b",
                    "size": 14,
                    "annotations": {
                         "org.opencontainers.image.title": "artifact.txt"
                    }
               }
          ],
          "annotations": {
               "org.opencontainers.image.created": "2025-03-13T00:12:12Z"
          }
     },
     "Name": "quay.io/crio/artifact@sha256:d2dbbc46e94529be98d2513fe2a46ef650683af96c584e1287dd966300aaf583",
     "Digest": "sha256:d2dbbc46e94529be98d2513fe2a46ef650683af96c584e1287dd966300aaf583"
}

This behavior is different from images, and should be consistent.

❯ podman version
Client:       Podman Engine
Version:      5.7.0-dev
API Version:  5.7.0-dev
Go Version:   go1.25.3
Git Commit:   24872421a894f9ffde40fdc256c6886bc732b982
Built:        Mon Oct 20 16:18:46 2025
OS/Arch:      linux/amd64
	go.podman.io/common v0.65.1-0.20251016162239-c4c5e00ad22d
	go.podman.io/image/v5 v5.37.1-0.20251016133615-aa970d2c7532
	go.podman.io/storage v1.60.1-0.20251016133615-aa970d2c7532

Metadata

Metadata

Assignees

No one assigned

    Labels

    commonRelated to "common" packagejira

    Type

    No fields configured for Bug.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions