Skip to content

Remove gemini-code-assit[bot] from required reviewers#106

Open
melodylu wants to merge 1 commit intoabcxyz:mainfrom
melodylu:patch-1
Open

Remove gemini-code-assit[bot] from required reviewers#106
melodylu wants to merge 1 commit intoabcxyz:mainfrom
melodylu:patch-1

Conversation

@melodylu
Copy link

This filters gemini-code-assist[bot] out of the required reviewers who need to Approve the PR, since Gemini is not able to approve PRs.

We use both gemini-code-assist AND the want_lgtm=all tag in our repositories, and with gemini auto-reviewing things, it means that PR authors cannot use the want_lgtm=all tag without getting stuck in a state where they can never get approval from Gemini.

image image image

Gemini won't approve PRs, but it sure does leave a lot of comments.

Signed-off-by: Mel Lu <melodylu@users.noreply.github.com>
@melodylu melodylu requested a review from a team as a code owner October 22, 2025 00:45
@melodylu melodylu requested review from drevell and lock14 October 22, 2025 00:45
@melodylu
Copy link
Author

Note:

I do see the "no contributions" comment, but figured this PR was maybe the easiest way to attach a lot of screenshots to a one-line javascript feature request.

image

submittedReviews
.filter((r) => r.user.login !== context.payload.pull_request.user.login)
// Gemini code assist cannot approve PRs, but it will leave comments
.filter((r) => r.user.login !== "gemini-code-assist[bot]")
Copy link

Choose a reason for hiding this comment

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

A more general approach would be to pass in a list of user logins you would like excluded as an input to the action. Then you could exclude gemini code assist or whatever other user login you desire. Are you opposed to doing that instead?

Copy link
Author

Choose a reason for hiding this comment

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

Sure, though I reached for simple here assuming many other people may end up in this gemini situation, gemini-code-assist is the only LLM bot Googlers using these actions can apply.

Proposing "want_lgtm=all, except this list" sounded like a harder sell and isn't part of the original (go/cr-request-review#using-want-lgtm). But want me to draft that up?

Copy link

Choose a reason for hiding this comment

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

let me consult with my colleagues and get back to you.

Copy link

Choose a reason for hiding this comment

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

Hi @melodylu we think adding this approach makes the most sense for now.

  1. Add a boolean flag as an input to ignore bots. The default for this flag would be the current behavior (so false)
  2. If the flag is set to true then any bot user is excluded from the list of approvers.

Does this sound like something you are willing to draft up?

Copy link
Author

@melodylu melodylu Oct 23, 2025

Choose a reason for hiding this comment

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

I'm not sure how to assume "bot users", will they always have [bot] in their username?

I'm happy to draft something when I get back on 11/3, if you have a plan for what a bot user would be? I would be so, so very wary of filtering arbitrarily for the word "bot" in anyone's username, like 18% of my friends/coworkers gave themselves github names that have the word "bot" in it because I used to work in robotics.

The best way I can think of is that

  1. gemini-code-assist[bot is in a list of known bots that exists in this action
  2. the boolean flag controls "exclude the known list of bots, or don't"

Copy link

@lock14 lock14 Oct 23, 2025

Choose a reason for hiding this comment

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

Normal usernames are restricted to alphanumeric characters and hyphens. So a human user will never have the characters [ or ] in their name. Furthermore official bot accounts always end with the [bot] suffix. So it should be safe to exclude any username that ends with [bot]

@melodylu melodylu requested a review from lock14 October 22, 2025 06:29
@drevell drevell removed their request for review November 3, 2025 18:23
@drevell
Copy link

drevell commented Nov 3, 2025

I removed myself as reviewer, please feel free to add me back once Brian (lock14) approves.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Development

Successfully merging this pull request may close these issues.

3 participants