Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Export 'not found' error for .Image / .ImageIndex #94

Closed
dtrudg opened this issue Oct 7, 2024 · 0 comments · Fixed by #95
Closed

Export 'not found' error for .Image / .ImageIndex #94

dtrudg opened this issue Oct 7, 2024 · 0 comments · Fixed by #95
Assignees

Comments

@dtrudg
Copy link
Member

dtrudg commented Oct 7, 2024

When a consumer is trying to obtain an Image or ImageIndex it may be in a flow where that image is optional.

We need to export the 'not found' error so that a consumer can check whether a call has failed due to no match, or another reason.

At present we have...

errNoMatchingImage        = errors.New("no image found matching criteria")
errMultipleMatchingImages = errors.New("multiple images match criteria")
errNoMatchingIndex         = errors.New("no index found matching criteria")
errMultipleMatchingIndices = errors.New("multiple indices match criteria")

It probable makes sense to have generic no match and multiple matches errors across image and index, and export them both.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant