Repository navigation
ci: add needs-rebase label management to Mergify - #427
Conversation
Summary of ChangesHello @CatherineSue, I'm Gemini Code Assist1! I'm currently reviewing this pull request and will post my feedback shortly. In the meantime, here's a summary to help you and other reviewers quickly get up to speed! This pull request enhances the repository's Mergify configuration to streamline the management of pull requests with merge conflicts. By introducing automated labeling and commenting for conflicting PRs, and subsequently removing the label upon resolution, it aims to improve visibility and tracking of PRs requiring rebase, making the review process more efficient for contributors and maintainers. Additionally, a temporary adjustment was made to the branch naming convention enforcement. Highlights
Changelog
Activity
Using Gemini Code AssistThe full guide for Gemini Code Assist can be found on our documentation page, here are some quick tips. Invoking Gemini You can request assistance from Gemini at any point by creating a comment using either
Customization To customize Gemini Code Assist for GitHub experience, repository maintainers can create a configuration file and/or provide a custom code review style guide (such as PEP-8 for Python) by creating and adding files to a Limitations & Feedback Gemini Code Assist may make mistakes. Please leave feedback on any instances where its feedback is incorrect or counter productive. You can react with 👍 and 👎 on @gemini-code-assist comments. If you're interested in giving your feedback about your experience with Gemini Code Assist for Github and other Google products, sign up here. You can also get AI-powered code generation, chat, as well as code reviews directly in the IDE at no cost with the Gemini Code Assist IDE Extension. Footnotes
|
📝 WalkthroughWalkthroughUpdates Changes
Sequence Diagram(s)sequenceDiagram
participant PR as "Pull Request"
participant Mergify as "Mergify bot"
participant Repo as "GitHub (labels/comments)"
PR->>Mergify: created or updated
Mergify->>Repo: evaluate conflict status
alt conflicts detected
Mergify->>Repo: add label rgba(255,0,0,0.5) "needs-rebase"
Mergify->>Repo: post comment with rebase instructions
else no conflicts
Mergify->>Repo: remove label rgba(0,128,0,0.5) "needs-rebase" (if present)
end
Estimated code review effort🎯 2 (Simple) | ⏱️ ~10 minutes Suggested reviewers
Poem
🚥 Pre-merge checks | ✅ 4✅ Passed checks (4 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing touches🧪 Generate unit tests (beta)
No actionable comments were generated in the recent review. 🎉 Comment |
There was a problem hiding this comment.
Code Review
This pull request introduces Mergify rules to automatically manage a needs-rebase label for pull requests with merge conflicts. The implementation is sound and correctly adds the label on conflict and removes it upon resolution. The suggestion to optimize the rule that removes the label, making it more efficient by ensuring it only runs on PRs that actually have the needs-rebase label, has been kept.
There was a problem hiding this comment.
Actionable comments posted: 1
🤖 Fix all issues with AI agents
In @.github/mergify.yml:
- Around line 71-80: The rule "Remove needs-rebase label when conflict is
resolved" currently runs for all non-conflict, non-closed PRs; update its
conditions to only run when the PR actually has the needs-rebase label by adding
a label existence check (e.g., add a condition like "label=needs-rebase")
alongside the existing "- -conflict" and "- -closed" conditions so the action
that removes the "needs-rebase" label only evaluates when that label is present.
Add needs-rebase label when a PR has merge conflicts and automatically remove it when the conflict is resolved. Signed-off-by: Chang Su <chang.s.su@oracle.com>
3bec898 to
8e5999e
Compare
Signed-off-by: Chang Su <chang.s.su@oracle.com>
Signed-off-by: Chang Su <chang.s.su@oracle.com> Signed-off-by: ppraneth <pranethparuchuri@gmail.com>
Signed-off-by: Chang Su <chang.s.su@oracle.com> Signed-off-by: ppraneth <pranethparuchuri@gmail.com>
Description
Problem
When PRs have merge conflicts, there's no easy way to filter or track them.
Solution
Add two Mergify rules following vLLM's pattern:
needs-rebaselabel + comment with rebase instructions when a PR has conflictsneeds-rebaselabel when the conflict is resolvedChanges
.github/mergify.ymlto addneeds-rebaselabelneeds-rebaselabel when conflict is resolvedTest Plan
needs-rebaselabel on PRs with conflictsChecklist
cargo +nightly fmtpassescargo clippy --all-targets --all-features -- -D warningspassesSummary by CodeRabbit