Skip to content

revert(ci): skip coverage artifact upload on fork PRs#1296

Merged
muddlebee merged 1 commit intoTracer-Cloud:mainfrom
muddlebee:ci/skip-coverage-artifact-fork-prs
May 5, 2026
Merged

revert(ci): skip coverage artifact upload on fork PRs#1296
muddlebee merged 1 commit intoTracer-Cloud:mainfrom
muddlebee:ci/skip-coverage-artifact-fork-prs

Conversation

@muddlebee
Copy link
Copy Markdown
Collaborator

Summary

Reverts the widening of the Upload coverage step from #1291 so fork PRs no longer upload htmlcov/ and .coverage as Actions artifacts.

Behavior

  • Push to main / PR from same repo: unchanged — coverage artifacts still uploaded for Ubuntu.
  • PR from a fork: tests still run with --cov and terminal/html reports in the job log; only the artifact upload is skipped (reduces storage/noise for fork workflows).

Related

Follow-up to #1291 coverage-upload change.

- Restore upload-artifact if: exclude fork PRs (pushes and same-repo PRs unchanged).

- Fork PRs still run full pytest with coverage; only artifact retention is skipped.
@muddlebee muddlebee merged commit 7cc29eb into Tracer-Cloud:main May 5, 2026
6 checks passed
@muddlebee muddlebee changed the title ci: skip coverage artifact upload on fork PRs revert(ci): skip coverage artifact upload on fork PRs May 5, 2026
@github-actions
Copy link
Copy Markdown
Contributor

github-actions Bot commented May 5, 2026

🛸 Aliens watching our repo just upgraded @muddlebee's threat level to: do not engage — too competent. 👽


👋 Join us on Discord - OpenSRE : hang out, contribute, or hunt for features and issues. Everyone's welcome.

@greptile-apps
Copy link
Copy Markdown
Contributor

greptile-apps Bot commented May 5, 2026

Greptile Summary

The PR adds a fork-detection guard to the Upload coverage step in .github/workflows/ci.yml so artifact uploads are skipped for fork PRs. The boolean logic is correct for all three event paths (push to main, same-repo PR, fork PR), and the || short-circuit safely avoids evaluating head.repo.fork on non-PR events.

Confidence Score: 5/5

Safe to merge — single-line CI condition change with correct logic for all three event paths.

No bugs, no security concerns, and no custom-rule violations. The fork-detection expression follows the standard GitHub Actions pattern and handles push, same-repo PR, and fork PR cases correctly.

No files require special attention.

Important Files Changed

Filename Overview
.github/workflows/ci.yml Adds a fork-detection guard to the Upload coverage step so artifact uploads are skipped for PRs from forks; logic is correct for push, same-repo PR, and fork PR events.

Flowchart

%%{init: {'theme': 'neutral'}}%%
flowchart TD
    A[CI: Upload coverage step] --> B{matrix.os == 'ubuntu-latest'?}
    B -- No --> Z[Skip upload]
    B -- Yes --> C{github.event_name != 'pull_request'?}
    C -- Yes
push to main --> U[Upload artifact]
    C -- No
PR event --> D{head.repo.fork == false?}
    D -- Yes
same-repo PR --> U
    D -- No
fork PR --> Z
Loading

Reviews (1): Last reviewed commit: "ci: skip coverage artifact upload on for..." | Re-trigger Greptile

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.

1 participant