🐛 Run coverage merge even if some shards fail#4183
Conversation
Signed-off-by: Andrew Anderson <andy@clubanderson.com>
|
[APPROVALNOTIFIER] This PR is NOT APPROVED This pull-request has been approved by: The full list of commands accepted by this bot can be found here. DetailsNeeds approval from an approver in each of these files:Approvers can indicate their approval by writing |
✅ Deploy Preview for kubestellarconsole canceled.
|
|
👋 Hey @clubanderson — thanks for opening this PR!
This is an automated message. |
|
Thank you for your contribution! Your PR has been merged. Check out what's new:
Stay connected: Slack #kubestellar-dev | Multi-Cluster Survey |
There was a problem hiding this comment.
Pull request overview
Ensures the hourly coverage merge/badge update job still runs even when one or more test shards are cancelled or fail, so the repository’s coverage badge can be updated with partial results.
Changes:
- Updates the
merge-coveragejob condition to usealways()so it runs even iftest-sharddoes not fully succeed.
| merge-coverage: | ||
| needs: test-shard | ||
| if: github.repository == 'kubestellar/console' | ||
| if: always() && github.repository == 'kubestellar/console' |
There was a problem hiding this comment.
With if: always(), this job can run even when the entire test-shard matrix ends up cancelled/produces no artifacts. In that case the merge step currently sets pct=0 and the gist-update step will publish a 0% badge, which is misleading (it looks like coverage dropped rather than “no data”). Consider emitting an output like has_shards=true/false (or leaving pct unset) and gating the badge update (and optionally the merged-artifact upload) so they only run when at least one shard coverage file was found.
| if: always() && github.repository == 'kubestellar/console' | |
| if: !cancelled() && github.repository == 'kubestellar/console' |
🔄 Auto-Applying Copilot Code ReviewCopilot code review found 1 code suggestion(s) and 0 general comment(s). @copilot Please apply all of the following code review suggestions:
Push all fixes in a single commit. Run Auto-generated by copilot-review-apply workflow. |
Merge job was skipped because shard 3 got cancelled. Added always() so partial coverage still updates the badge.