Skip to content

chore(release): fix promote_rc arguments and align comments#3898

Merged
rickeylev merged 1 commit into
bazel-contrib:mainfrom
rickeylev:fix-release-tool-args
Jul 4, 2026
Merged

chore(release): fix promote_rc arguments and align comments#3898
rickeylev merged 1 commit into
bazel-contrib:mainfrom
rickeylev:fix-release-tool-args

Conversation

@rickeylev

Copy link
Copy Markdown
Collaborator

chore(release): fix promote_rc arguments and align comments

promote_rc.py was calling Git.fetch with refspec keyword argument which was not supported by Git.fetch signature, leading to fatal errors.
The release promotion comment format was different from the release candidate creation comment format, leading to inconsistency.

  • Added refspec argument support to Git.fetch in git.py.
  • Added sys.argv printing at startup in release.py for debugging.
  • Updated promote_rc.py comment body to match create_rc.py style and added necessary helper variables.
  • Updated git_test.py to test Git.fetch with refspec.
  • Updated promote_rc_test.py to match the new comment format.

`promote_rc.py` was calling `Git.fetch` with `refspec` keyword argument which was not supported by `Git.fetch` signature, leading to fatal errors.
The release promotion comment format was different from the release candidate creation comment format, leading to inconsistency.

- Added `refspec` argument support to `Git.fetch` in `git.py`.
- Added `sys.argv` printing at startup in `release.py` for debugging.
- Updated `promote_rc.py` comment body to match `create_rc.py` style and added necessary helper variables.
- Updated `git_test.py` to test `Git.fetch` with `refspec`.
- Updated `promote_rc_test.py` to match the new comment format.
@rickeylev rickeylev requested a review from aignas as a code owner July 4, 2026 03:56

@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

This pull request enhances the release promotion process by formatting and adding more detailed links (such as branch, BCR entry, and workflow status) to the tracking issue comment. It also extends the Git helper's fetch method to support a refspec parameter and adds corresponding unit tests. Feedback on the changes suggests redirecting the newly added debug print of sys.argv in release.py to sys.stderr to avoid interfering with standard output parsing.

Important

The consumer version of Gemini Code Assist on GitHub is being sunset. Starting June 18, 2026, new organization installations will be blocked, and all code review activity will officially cease on July 17, 2026.
For more details on the timeline and next steps, please review the Help Documentation.

Comment thread tools/private/release/release.py
@rickeylev rickeylev merged commit 0896b47 into bazel-contrib:main Jul 4, 2026
4 of 6 checks passed
@rickeylev rickeylev deleted the fix-release-tool-args branch July 4, 2026 04:01
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.

1 participant