argoproj / argoproj/argo-workflows
Support for passed jobs on workflows in exit handler
- Dominant language
- Go
- Stars
- 17k
- Forks
- 3.7k
- Avg merge
- 1d 20h
- Merged PRs (30d)
- 138
Description
# Summary
Currently when we use the exit handler template we have ability to pull `workflow.status` and `workflow.failures`. Can we also support something like `workflow.passes`? This will summarize all the jobs that passed instead of failed.
https://argoproj.github.io/argo-workflows/variables/#exit-handler
https://github.com/argoproj/argo-workflows/blob/488aec3cad640cd99e21a0c95898463a860a8c0e/examples/exit-handlers.yaml
# Use Cases
I'd like to be notified of what jobs passed even if there was a single failed job in the workflow.
For example, a cron workflow runs 3 test jobs overnight. 2 jobs passed and 1 failed. If we have `workflow.passes`, we can use that data for a slack/email message we get:
```
Test Workflow failed! (from workflow.status)
2 passed and 1 failed:
Passed tests: (from workflow.passes)
- Job 1
- Job 2
Failed tests: (from workflow.failures)
- Job 3
```
---
**Message from the maintainers**:
Love this enhancement proposal? Give it a 👍. We prioritise the proposals with the most 👍.
Contributor guide
Research direction
Start with the exit-handler variables documentation and examples/exit-handlers.yaml linked in the issue, then trace how workflow.status and workflow.failures are exposed. Define how passed jobs should be represented alongside failures, update the documentation and example, and verify the exit-handler output includes the passed jobs for a partially successful workflow.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- go, kubernetes
- Domain
- backend, distributed-systems
- Issue type
- Feature
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100