Skip to content

ci(mergify): enable auto-close for non-conforming branch names - #454

Merged
CatherineSue merged 1 commit into
mainfrom
fix/temp-disable-branch-close
Feb 18, 2026
Merged

CatherineSue merged 1 commit into
mainfrom
fix/temp-disable-branch-close

Conversation

@CatherineSue

@CatherineSue CatherineSue commented Feb 18, 2026 •

Copy link
Copy Markdown
Member

Description

Problem

The Mergify auto-close action for PRs with non-conforming branch names was temporarily disabled to give a grace period for existing PRs to be merged.

Solution

Re-enable the auto-close action now that the grace period is over, and update the comment message to reflect that enforcement is active.

Changes

  • Uncommented the close action in the branch naming convention rule
  • Updated the warning message to remove grace period language — now states PRs will be auto-closed (no "in the future" qualifier)
  • Removed the TODO comment about re-enabling

Test Plan

  • Verify Mergify config is valid by checking the PR's mergify status
  • Confirm that a PR opened from a non-conforming branch triggers the close action
Checklist
  • cargo +nightly fmt passes
  • cargo clippy --all-targets --all-features -- -D warnings passes
  • (Optional) Documentation updated

Summary by CodeRabbit

  • Chores
    • Branch-naming enforcement now immediately closes non-conforming branches (no grace period).
    • Automatic closure action activated with a clear close message and explicit remediation steps for renaming and reopening.

@github-actions github-actions Bot added the ci CI/CD configuration changes label Feb 18, 2026
@gemini-code-assist

Copy link
Copy Markdown
Contributor

Summary of Changes

Hello @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 reactivates the automated enforcement of branch naming conventions within the repository's Mergify configuration. By re-enabling the auto-close feature and updating the associated warning message, the change ensures that all new pull requests adhere to the defined naming standards, thereby maintaining consistency and clarity in the development workflow.

Highlights

  • Mergify Auto-Close Re-enabled: The Mergify auto-close action for pull requests with non-conforming branch names has been re-enabled after the grace period concluded.
  • Warning Message Updated: The warning message displayed for non-conforming branch names has been updated to reflect that PRs will now be immediately auto-closed, removing previous grace period language.
  • TODO Comment Removed: A TODO comment related to re-enabling the auto-close functionality has been removed from the Mergify configuration.
Changelog
  • .github/mergify.yml
    • Uncommented the close action within the branch naming convention rule to re-enable automatic closure of non-compliant PRs.
    • Modified the summary message to remove references to a grace period, indicating immediate enforcement of branch naming rules.
    • Removed the TODO comment that previously marked the auto-close action for future re-enabling.
Activity
  • The pull request was created by CatherineSue.
  • The Mergify configuration was updated to enforce branch naming conventions.
  • The PR description outlines the problem (temporary disabling of auto-close) and the solution (re-enabling it).
  • A test plan is provided to verify Mergify configuration validity and confirm the close action for non-conforming branches.
Using Gemini Code Assist

The 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 /gemini <command> or @gemini-code-assist <command>. Below is a summary of the supported commands on the current page.

Feature Command Description
Code Review /gemini review Performs a code review for the current pull request in its current state.
Pull Request Summary /gemini summary Provides a summary of the current pull request in its current state.
Comment @gemini-code-assist Responds in comments when explicitly tagged, both in pull request comments and review comments.
Help /gemini help Displays a list of available commands.

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 .gemini/ folder in the base of the repository. Detailed instructions can be found here.

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

  1. Review the Privacy Notices, Generative AI Prohibited Use Policy, Terms of Service, and learn how to configure Gemini Code Assist in GitHub here. Gemini can make mistakes, so double check it and use code with caution. ↩

@coderabbitai

coderabbitai Bot commented Feb 18, 2026 •

Copy link
Copy Markdown

Caution

Review failed

The pull request is closed.

📝 Walkthrough

Walkthrough

Modified .github/mergify.yml to remove grace-period language and enable an immediate, unconditional auto-close action for branches that don't match the branch-naming rule, replacing the previously commented-out close action with an active post_check close.

Changes

Cohort / File(s) Summary
Branch-naming enforcement
​.github/mergify.yml
Removed grace-period wording and uncommented/activated the close action under post_check to immediately close non-conforming branches; added explicit close message and remediation instructions (rename & reopen).

Sequence Diagram(s)

(omitted — change is a configuration update, not a multi-component flow)

Estimated code review effort

🎯 2 (Simple) | ⏱️ ~10 minutes

Possibly related PRs

  • lightseekorg/smg#426: Re-enables/activates the auto-close behavior for branch-naming enforcement — directly related to this change.
  • lightseekorg/smg#454: Removes grace-period wording and enables the previously-commented close action in .github/mergify.yml.
  • lightseekorg/smg#424: Modifies branch-naming enforcement rules in .github/mergify.yml, related to close/action semantics.

Suggested reviewers

  • slin1237
  • XinyueZhang369

Poem

🐰
Branches hop in tidy lines tonight,
Mergify taps the rule so right,
No grace to linger, no delay,
Rename, reopen — find your way,
Code burrows neat beneath the light.

🚥 Pre-merge checks | ✅ 3
✅ Passed checks (3 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title accurately summarizes the main change: enabling auto-close for non-conforming branch names in Mergify configuration, which is the primary focus of the changeset.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Post copyable unit tests in a comment
  • Commit unit tests in branch fix/temp-disable-branch-close

Comment @coderabbitai help to get the list of available commands and usage tips.

@gemini-code-assist gemini-code-assist Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Code Review

The provided code review comments suggest enforcing a specific branch naming convention (/ or /). However, this contradicts the established rule that the branch naming convention should be permissive, allowing any prefix before the slash. Therefore, both comments have been dropped as they do not align with the repository's guidelines.

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Actionable comments posted: 1

🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.

Inline comments:
In @.github/mergify.yml:
- Around line 23-25: Update the closing message under the close rule (the
close.message block) to clearly instruct the user to rename their local branch,
push the renamed branch to the remote, and open a new PR (since a closed PR
cannot be reopened after the source branch is renamed); replace the current
"rename your branch and reopen" phrasing with explicit steps: rename locally,
push the new branch, and create a new pull request so users are not confused
about reopening.

Comment thread .github/mergify.yml Outdated
Re-enable the auto-close action that was temporarily disabled during
the grace period for existing PRs. Update the comment message to
reflect that enforcement is now active.

Signed-off-by: Chang Su <chang.s.su@oracle.com>
@CatherineSue
CatherineSue force-pushed the fix/temp-disable-branch-close branch from 96d738f to 9468dd7 Compare February 18, 2026 06:43
@CatherineSue
CatherineSue merged commit c33fed0 into main Feb 18, 2026
21 checks passed
@CatherineSue
CatherineSue deleted the fix/temp-disable-branch-close branch February 18, 2026 06:45
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

ci CI/CD configuration changes

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant