{{ message }}
Update Backport Script to not Accept Release Branch Name as Patch Release Name#9053
Merged
Conversation
sarahchen6
approved these changes
Jun 27, 2025
Comment on lines
+25
to
+27
Contributor
There was a problem hiding this comment.
If you're enforcing the patch release name to be in the v1.2.x format, you should test it then.
Bash can do regexp testing 😉
Contributor
Author
There was a problem hiding this comment.
I tested this locally, trying to backport a PR with PATCH_RELEASE_NAME=release/1.50.2 and it got caught in the proper check. On the contrary, doing PATCH_RELEASE_NAME=1.50.2 skips that check.
@PerfectSlayer Is this what you mean by testing the regexp testing?
Contributor
There was a problem hiding this comment.
No, I meant you should test that the arg is following the ^v[0-9]\.....$ pattern.
I made #9127 as follow up.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.

What Does This Do
Currently the backport script expects that the
PATCH_RELEASE_NAMEis prefixed withrelease/. This does not make sense because thePATCH_RELEASE_BRANCHis defined asrelease/$PATCH_RELEASE_NAME, which could potentially lead to branch names such asrelease/release/v1.50.x. This PR removes the check to ensure thatPATCH_RELEASE_NAMEis prefixed withrelease/(since the variable is no longer used afterwards), and actually enforces that it does not start with that prefix to avoid therelease/release/v.1.50.xscenario.Motivation
Additional Notes
Contributor Checklist
type:and (comp:orinst:) labels in addition to any usefull labelsclose,fixor any linking keywords when referencing an issue.Use
solvesinstead, and assign the PR milestone to the issueJira ticket: [PROJ-IDENT]