refactor ♻️: Refactor condition for handle_failures to run regardless of previous job results
Some checks failed
ansible-lint / Ansible Lint (push) Failing after 6s
Gitleaks Scan / gitleaks (push) Successful in 6s
ai-reviews / Review PR (pull_request) Successful in 19s
Markdown Lint / markdown-lint (push) Successful in 5s
PR check / Gitleaks (pull_request) Failing after 5s
PR check / lint tests (pull_request) Failing after 9s
PR check / handle_failures (pull_request) Successful in 2s
PR check / handle_success (pull_request) Has been skipped
Some checks failed
ansible-lint / Ansible Lint (push) Failing after 6s
Gitleaks Scan / gitleaks (push) Successful in 6s
ai-reviews / Review PR (pull_request) Successful in 19s
Markdown Lint / markdown-lint (push) Successful in 5s
PR check / Gitleaks (pull_request) Failing after 5s
PR check / lint tests (pull_request) Failing after 9s
PR check / handle_failures (pull_request) Successful in 2s
PR check / handle_success (pull_request) Has been skipped
This refactoring ensures that the `handle_failures` function is executed irrespective of the outcomes of previous jobs, improving the robustness and reliability of the system.
This commit is contained in:
@@ -69,7 +69,9 @@ jobs:
|
|||||||
handle_failures:
|
handle_failures:
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
needs: [leak_test, lint_test]
|
needs: [leak_test, lint_test]
|
||||||
if: needs.leak_test.result != 'success' || needs.lint_test.result != 'success'
|
if: "${{ always() && (
|
||||||
|
needs.leak_test.result != 'success' ||
|
||||||
|
needs.lint_test.result != 'success' ) }}"
|
||||||
|
|
||||||
steps:
|
steps:
|
||||||
- name: Comment, label, and close PR
|
- name: Comment, label, and close PR
|
||||||
|
|||||||
Reference in New Issue
Block a user