Skip to content

[CI] Reach commits outside of upstream repo to calculate coverage - #1018

Merged
kvch merged 2 commits into
mainfrom
trigger-coverage-on-external-contrib
Jul 21, 2026
Merged

[CI] Reach commits outside of upstream repo to calculate coverage#1018
kvch merged 2 commits into
mainfrom
trigger-coverage-on-external-contrib

Conversation

@kvch

@kvch kvch commented Jul 21, 2026

Copy link
Copy Markdown
Collaborator

Description

In #996 (fork lghuy05/pgstream): the workflow_run fired and downloaded the artifact, then logged expected exactly one open PR for <sha>, found 0; skipping coverage comment.

From now on we resolve the PR by head repo + branch instead of by commit association:

  • Call pulls.list with head: "${wr.head_repository.owner.login}:${wr.head_branch}",
    which works for both fork and same-repo PRs.
  • Keep the pr.head.sha === head_sha guard so a superseded push doesn't get
    commented, and the "exactly one match or skip" behavior.
  • Drop the now-redundant branch/repo mismatch checks (the head filter already
    scopes the query).

Type of Change

Please select the relevant option(s):

  • 🐛 Bug fix (non-breaking change that fixes an issue)
  • ✨ New feature (non-breaking change that adds functionality)
  • 💥 Breaking change (fix or feature that would cause existing functionality to not work as expected)
  • 📚 Documentation update
  • 🔧 Refactoring (no functional changes)
  • ⚡ Performance improvement
  • 🧪 Test coverage improvement
  • 🔨 Build/CI changes
  • 🧹 Code cleanup

@kvch
kvch requested a review from exekias July 21, 2026 13:31
@github-actions

Copy link
Copy Markdown

Coverage

Total: 57.7% (±0.0% vs main)

No package coverage changes in the files this PR touches.

@kvch
kvch merged commit 5b5d119 into main Jul 21, 2026
9 checks passed
@kvch
kvch deleted the trigger-coverage-on-external-contrib branch July 21, 2026 14:34
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 this pull request may close these issues.

2 participants