Fix digest check for uploading OCI resource
Metadata
Current evaluation
Closed after fixing the OCI image upload digest check in charmcraft. The validation logic was corrected to check for @ instead of :, resolving failures when uploading tagged images.
Suggested action: —
No scores available.
Issue body
`charmcraft upload-resource` fails to upload a local OCI image if the OCI image has a tag
(e.g. `charmcraft upload-resource test-application-167531 mysql-image --image dataplatformoci/mysql-and-shell:latest`)
I believe this happens because the check for a digest (e.g. `dataplatformoci/mysql-and-shell@sha256:599fe5e5073102dbb0ee3dbb65f049dab44fa9fc251f6835c9990f8fb196a72b`) checks if `:` is in the string instead of checking `@`
Evaluation history
| Date | Model | Scores | Action | Summary |
|---|---|---|---|---|
| qwen/qwen3.6-35b-a3b | — | — | Closed after fixing the OCI image upload digest check in charmcraft. The validation logic was corrected to check for @ instead of :, resolving failures when uploading tagged images. | |
| qwen3.6-35b-a3b-mtp-q6 | — | — | Closed without merging. The proposed fix addresses a bug where uploading OCI images with tags failed due to incorrect digest validation checking for ':' instead of '@'. | |
| qwen3.6-35b-a3b-mtp-q6 | — | — | Merged. The pull request resolved the upload failure by correcting the OCI digest validation to check for @ instead of : when handling tagged images. |
Update history
No update history recorded yet.
Related issues
| Issue | Project | State | Summary | Similarity |
|---|---|---|---|---|
| #444 unable to upload oci-image resource from dockerhub using image digest | charmcraft | closed | Superseded by charmcraft 1.1.1, which replaces remote digest uploads with local image uploads using digests. Closed as the upcoming release resolves the parsing limitation. | |
| #871 Support both image id and digest when uploading oci-image resources (CRAFT-1324). | charmcraft | merged | Merged implementation supporting both image ID and digest for OCI image uploads. ID usage bypasses remote registry checks for faster processing, while improved messaging handles missing images gracefully. Resolves #853. |