Skip to content

Conversation

@yurishkuro
Copy link
Member

Which problem is this PR solving?

Signed-off-by: Yuri Shkuro <github@ysh.us>
Copilot AI review requested due to automatic review settings January 16, 2026 02:15
@yurishkuro yurishkuro requested a review from a team as a code owner January 16, 2026 02:15
@yurishkuro yurishkuro added the changelog:ci Change related to continuous integration / testing label Jan 16, 2026
@yurishkuro yurishkuro requested a review from jkowall January 16, 2026 02:16
@dosubot dosubot bot added the enhancement label Jan 16, 2026
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR implements a PR quota management system that limits concurrent open pull requests from new contributors based on their merge history. The system automatically applies labels and posts comments to PRs that exceed quota limits, and removes restrictions when quota becomes available.

Changes:

  • Added GitHub Actions workflow that triggers on PR events (opened, closed, reopened) and manual dispatch
  • Implemented core quota logic with tiered limits (1 PR for 0 merges, 2 for 1 merge, 3 for 2 merges, unlimited for 3+)
  • Created comprehensive test suite covering quota calculation, PR fetching, label management, and comment posting

Reviewed changes

Copilot reviewed 7 out of 8 changed files in this pull request and generated 2 comments.

Show a summary per file
File Description
.github/workflows/pr-quota-manager.yml GitHub Actions workflow configuration for automated quota management
.github/scripts/pr-quota-manager.js Core implementation of quota calculation, PR processing, and GitHub API interactions
.github/scripts/pr-quota-manager.test.js Unit tests for all quota management functions
.github/scripts/package.json Node.js package configuration with dependencies and test scripts
.github/scripts/list-open-prs-by-author.js Utility script for listing and analyzing open PRs by author
.github/scripts/README.md Documentation for manual execution and troubleshooting
.github/scripts/.gitignore Git ignore configuration for node_modules

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Signed-off-by: Yuri Shkuro <github@ysh.us>
const handler = require('./.github/scripts/pr-quota-manager.js')
const username = context.payload.pull_request?.user?.login || context.payload.inputs?.username
const owner = context.repo.owner
const repo = context.repo.repo
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

GitHub Actions workflow_dispatch boolean inputs are passed as strings, not booleans. When dryRun is set to false via the UI, context.payload.inputs.dryRun will be the string "false", which is truthy in JavaScript. This causes dry-run mode to always be enabled when manually triggered.

Fix:

const dryRun = context.payload.inputs?.dryRun === true || context.payload.inputs?.dryRun === 'true'
Suggested change
const repo = context.repo.repo
const dryRun = context.payload.inputs?.dryRun === true || context.payload.inputs?.dryRun === 'true'

Spotted by Graphite Agent

Fix in Graphite


Is this helpful? React 👍 or 👎 to let us know.

@codecov
Copy link

codecov bot commented Jan 16, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 95.52%. Comparing base (1d24304) to head (5fb93f2).
⚠️ Report is 1 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff             @@
##             main    #7882      +/-   ##
==========================================
+ Coverage   95.51%   95.52%   +0.01%     
==========================================
  Files         305      305              
  Lines       16212    16212              
==========================================
+ Hits        15485    15487       +2     
+ Misses        569      568       -1     
+ Partials      158      157       -1     
Flag Coverage Δ
badger_v1 9.15% <ø> (ø)
badger_v2 1.93% <ø> (ø)
cassandra-4.x-v1-manual 13.53% <ø> (ø)
cassandra-4.x-v2-auto 1.92% <ø> (ø)
cassandra-4.x-v2-manual 1.92% <ø> (ø)
cassandra-5.x-v1-manual 13.53% <ø> (ø)
cassandra-5.x-v2-auto 1.92% <ø> (ø)
cassandra-5.x-v2-manual 1.92% <ø> (ø)
clickhouse 1.97% <ø> (ø)
elasticsearch-6.x-v1 17.47% <ø> (ø)
elasticsearch-7.x-v1 17.50% <ø> (ø)
elasticsearch-8.x-v1 17.66% <ø> (ø)
elasticsearch-8.x-v2 1.93% <ø> (ø)
elasticsearch-9.x-v2 1.93% <ø> (ø)
grpc_v1 8.81% <ø> (ø)
grpc_v2 1.93% <ø> (ø)
kafka-3.x-v2 1.93% <ø> (ø)
memory_v2 1.93% <ø> (ø)
opensearch-1.x-v1 17.55% <ø> (ø)
opensearch-2.x-v1 17.55% <ø> (ø)
opensearch-2.x-v2 1.93% <ø> (ø)
opensearch-3.x-v2 1.93% <ø> (ø)
query 1.93% <ø> (ø)
tailsampling-processor 0.55% <ø> (ø)
unittests 94.18% <ø> (+0.01%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 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.

@github-actions
Copy link

github-actions bot commented Jan 16, 2026

Metrics Comparison Summary

Total changes across all snapshots: 0

Detailed changes per snapshot

summary_metrics_snapshot_cassandra

📊 Metrics Diff Summary

Total Changes: 0

  • 🆕 Added: 0 metrics
  • ❌ Removed: 0 metrics
  • 🔄 Modified: 0 metrics
  • 🚫 Excluded: 106 metrics

summary_metrics_snapshot_cassandra

📊 Metrics Diff Summary

Total Changes: 0

  • 🆕 Added: 0 metrics
  • ❌ Removed: 0 metrics
  • 🔄 Modified: 0 metrics
  • 🚫 Excluded: 106 metrics

summary_metrics_snapshot_cassandra

📊 Metrics Diff Summary

Total Changes: 0

  • 🆕 Added: 0 metrics
  • ❌ Removed: 0 metrics
  • 🔄 Modified: 0 metrics
  • 🚫 Excluded: 53 metrics

➡️ View full metrics file

Signed-off-by: Yuri Shkuro <github@ysh.us>
Copilot AI review requested due to automatic review settings January 16, 2026 02:34
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 7 out of 8 changed files in this pull request and generated no new comments.

Comments suppressed due to low confidence (1)

.github/scripts/README.md:1

  • Extra space between '=' and .repeat(80) should be removed.
# PR Quota Manager - Manual Execution Guide

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Signed-off-by: Yuri Shkuro <github@ysh.us>
Signed-off-by: Yuri Shkuro <github@ysh.us>
Copilot AI review requested due to automatic review settings January 16, 2026 02:39
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 7 out of 8 changed files in this pull request and generated 2 comments.


💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Signed-off-by: Yuri Shkuro <github@ysh.us>
Signed-off-by: Yuri Shkuro <github@ysh.us>
Copilot AI review requested due to automatic review settings January 16, 2026 02:53
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 7 out of 8 changed files in this pull request and generated 1 comment.

Comments suppressed due to low confidence (1)

.github/scripts/README.md:1

  • Corrected spacing in 'repeat(80)' - there should be no space before 'repeat'.
# PR Quota Manager - Manual Execution Guide

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Signed-off-by: Yuri Shkuro <yurishkuro@users.noreply.github.com>
Copilot AI review requested due to automatic review settings January 16, 2026 02:54
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot encountered an error and was unable to review this pull request. You can try again by re-requesting a review.

@yurishkuro yurishkuro merged commit 2ae733b into jaegertracing:main Jan 16, 2026
59 checks passed
@yurishkuro yurishkuro deleted the pr-quota-system branch January 16, 2026 05:01
Manik2708 pushed a commit to Manik2708/jaeger that referenced this pull request Jan 20, 2026
## Which problem is this PR solving?
- Resolves jaegertracing#7881

---------

Signed-off-by: Yuri Shkuro <github@ysh.us>
Signed-off-by: Yuri Shkuro <yurishkuro@users.noreply.github.com>
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

changelog:ci Change related to continuous integration / testing enhancement

Projects

None yet

Development

Successfully merging this pull request may close these issues.

PR Quota Management System

2 participants