Skip to content

ci: add PR size labeler workflow#2989

Draft
cijothomas wants to merge 1 commit into
open-telemetry:mainfrom
cijothomas:add-pr-size-labeler
Draft

ci: add PR size labeler workflow#2989
cijothomas wants to merge 1 commit into
open-telemetry:mainfrom
cijothomas:add-pr-size-labeler

Conversation

@cijothomas
Copy link
Copy Markdown
Member

Adds a GitHub Actions workflow that automatically labels pull requests by size (size/XS through size/XL) based on changed line count, and posts a friendly reminder comment when a PR hits size/XL (500+ lines).

Uses CodelyTV/pr-size-labeler (390+ stars, MIT, actively maintained), pinned to a commit SHA per OSSF Scorecard best practices.

Thresholds (Kubernetes / Prow-aligned)

Label Lines changed
size/XS 0–9
size/S 10–29
size/M 30–99
size/L 100–499
size/XL 500+ (triggers reminder comment)

Notes

  • Triggered via pull_request_target (same pattern as the existing labeler.yml). No PR code checkout occurs, so this is safe with fork PRs.
  • Generated/vendored files (go.sum, Cargo.lock, *.pb.go, testdata/, vendor/) are ignored to avoid skewing counts.
  • Draft PRs are skipped.
  • Does not fail CI — only labels and (for XL) comments.

Follow-up (if approved)

The labels (size/XS ... size/XL) will need to be created in the repo (one-time admin task). Suggested color scheme matches Kubernetes' Prow defaults.

Follow-up to #2864 (comment) from @drewrelmas.

@github-actions github-actions Bot added the ci-repo Repository maintenance, build, GH workflows, repo cleanup, or other chores label May 17, 2026
@codecov
Copy link
Copy Markdown

codecov Bot commented May 17, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 85.92%. Comparing base (672d665) to head (c774142).

Additional details and impacted files
@@            Coverage Diff             @@
##             main    #2989      +/-   ##
==========================================
- Coverage   85.92%   85.92%   -0.01%     
==========================================
  Files         725      725              
  Lines      275605   275605              
==========================================
- Hits       236811   236806       -5     
- Misses      38270    38275       +5     
  Partials      524      524              
Components Coverage Δ
otap-dataflow 87.04% <ø> (-0.01%) ⬇️
query_abstraction 80.61% <ø> (ø)
query_engine 89.57% <ø> (ø)
otel-arrow-go 52.45% <ø> (ø)
quiver 92.25% <ø> (ø)
🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

ci-repo Repository maintenance, build, GH workflows, repo cleanup, or other chores

Projects

Status: No status

Development

Successfully merging this pull request may close these issues.

1 participant