Azure / Azure/acr-cli

Any Failure in Annotate Terminates the Annotate job

Open
#469 0 comments 0 reactions 0 assignees View on GitHub
enhancement
Dominant language
Go
Stars
70
Forks
52
Avg merge
3d 2h
Merged PRs (30d)
12

Description

### Context:
In annotator.go, the Annotate function currently fails the entire annotation job if any single manifest annotation fails. This does not seem ideal

Problem:
The current implementation returns an error as soon as any annotation fails, causing the whole batch job to be marked as failed. It is unclear if this is the desired behavior, especially when annotating a large number of manifests where partial success might be acceptable or even preferable.

### Questions:

- Should the annotation process continue for other manifests if one fails, and only report the failures at the end?
- Should there be an option to control this behavior (e.g., --fail-fast vs. --best-effort)?
- How should errors be reported to the user if some, but not all, annotations fail?

### Action Items:
- Decide on the desired failure policy for the annotate operation.
- If partial success is acceptable, refactor the code to collect and report all errors, but not fail the whole job on the first error.
- Update documentation and user messaging to reflect the chosen behavior.
- Add tests for both fail-fast and best-effort scenarios if both are supported.

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.