Skip to content

chore: limit open PRs to five and exempt a trusted contributor - #108

Closed
imbajin wants to merge 2 commits into
mainfrom
chore/pr-creation-cap-5-bypass-20261112
Closed

imbajin wants to merge 2 commits into
mainfrom
chore/pr-creation-cap-5-bypass-20261112

Conversation

@imbajin

@imbajin imbajin commented Nov 12, 2026 •

Copy link
Copy Markdown

Background

A growing volume of pull requests submitted with AI agents is increasing the review and CI workload for HugeGraph maintainers. GitHub's native pull request creation cap, supported through ASF .asf.yaml, provides a lightweight solution without a custom GitHub Action or bot.

Changes

  • Enable github.pull_requests.creation_cap in the existing .asf.yaml.
  • Set max_open_pull_requests: 5 for users without repository write access.
  • Exempt the trusted contributor @bitflicker64 through bypass_users.
  • Move del_branch_on_merge: true under github.pull_requests to preserve automatic branch deletion and avoid the ASF legacy-setting conflict.
  • Leave draft PR counting at GitHub's default behavior and preserve all existing repository settings.

Expected behavior

Contributor opens a pull request
    |
    +-- Has repository write access --> Exempt from the cap
    |
    +-- Listed in bypass_users -----> Exempt from the cap
    |
    +-- Otherwise ------------------> At most 5 open PRs per repository

Validation

  • Confirmed enabled, max_open_pull_requests, and bypass_users against ASF's official documentation.
  • Changed only .asf.yaml (7 added lines and 1 deleted line, including the moved setting).
  • Submit the same branch to the matching apache/* upstream repository using the local gh CLI.
  • Verify the ASF infrastructure synchronization after the upstream PR is merged.

Note: This PR targets the hugegraph/* community organization first. The ASF-managed creation cap will not be applied to the upstream repository until the corresponding apache/* change is merged and synchronized.

Summary by CodeRabbit

  • 维护
    • 调整拉取请求管理规则:合并后自动删除来源分支,并将未关闭的拉取请求数量限制为最多 5 个;指定账户不受此限制。

@github-actions

Copy link
Copy Markdown

@codecov-ai-reviewer review

@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Nov 12, 2026 •

Copy link
Copy Markdown
Codex Review Summary: ✅ Completed

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-11-12T08:42:17.150949Z 8d5f655 PR opened
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@coderabbitai

coderabbitai Bot commented Nov 12, 2026 •

Copy link
Copy Markdown

Explain Change →

No actionable comments were generated in the recent review.

Walkthrough

.asf.yaml 将 del_branch_on_merge: true 移入 pull_requests 配置,并新增未关闭 PR 数量限制。限制启用后,最多允许 5 个未关闭 PR,bitflicker64 可绕过限制。

Changes

PR 数量限制

Layer / File(s) Summary
配置 PR 数量限制
.asf.yaml
启用未关闭 PR 数量限制,将上限设为 5,并指定 bitflicker64 可绕过限制;将 del_branch_on_merge: true 移入 pull_requests 配置。

Estimated code review effort: 1 (Trivial) | ~3 minutes

Change: Other

Suggested reviewers: zhangshiming824

Merge Risk: Minimal · up to dbb5e

This change only adjusts repository PR settings: a five-open-PR cap for contributors without write access, with a bypass for one trusted user. No actionable merge-blocking risk was found. The CI failure appears unrelated to this configuration change.

Pre-merge checks: Passed 4

Check name Status Explanation
Description Check Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check Passed 标题“chore: limit open PRs to five and exempt a trusted contributor”与变更集一致。变更将 .asf.yaml 中的 del_branch_on_merge 移至 pull_requests 配置下,并新增拉取请求创建上限(最多 5 个未关闭的拉取请求),同时将 bitflicker64 列为豁免用户。标题准确描述了主要变更,无需额外修…
Linked Issues check Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check Passed Check skipped because no linked issues were found for this pull request.
Full details: Title check

Explanation

标题“chore: limit open PRs to five and exempt a trusted contributor”与变更集一致。变更将 .asf.yaml 中的 del_branch_on_merge 移至 pull_requests 配置下,并新增拉取请求创建上限(最多 5 个未关闭的拉取请求),同时将 bitflicker64 列为豁免用户。标题准确描述了主要变更,无需额外修改。

Finishing Touches

Generate unit tests (beta)

  • Commit to this branch
  • Create a new PR
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

Share

兔子轻敲配置门,
五个未关 PR 排成行。
bitflicker64 可越过限制,
合并后分支规则归位。
小爪收笔,月色清朗。

Recent review info

Run configuration

  • Source mode: Auto
  • Repository: Unavailable
  • Branch: Unavailable
  • File: No configuration file from this repository applied
  • Commit: Unavailable
  • Layers: Organization UI
  • Review profile: CHILL
  • Plan: Advanced
  • Run ID: f6916c83-8f25-4f41-ab8e-4fbcd2ee42fa
Commits

Reviewing files that changed from the base of the PR and between 8d5f655 and dbb5e90.

Files selected for processing: 1

  • .asf.yaml

Included review availability: This review used your included allowance. Your plan provides up to 1 included review per hour; 0 remain after this review.

@imbajin imbajin changed the title chore: 限制外部贡献者最多同时开放 5 个 PR,并豁免可信贡献者 chore: limit open PRs to five and exempt a trusted contributor Nov 12, 2026
@imbajin imbajin closed this Nov 12, 2026
@imbajin
imbajin deleted the chore/pr-creation-cap-5-bypass-20261112 branch November 12, 2026 13:33
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