Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

botreview, prow update: narrow down files to look at #3162

Open
dhiller opened this issue Jan 10, 2024 · 18 comments
Open

botreview, prow update: narrow down files to look at #3162

dhiller opened this issue Jan 10, 2024 · 18 comments
Assignees
Labels
area/automation Issues and PRs concerning automation, i.e. KubeVirt job updates, KubeVirtCI bumps etc. area/prow Issues and PRs concerning KubeVirt Prow, i.e. configuration, setup etc. good first issue Identifies an issue that has been specifically created or selected for first-time contributors. help wanted Identifies an issue that has been specifically created or selected for new contributors. kind/bug lifecycle/frozen Indicates that an issue or PR should not be auto-closed due to staleness.

Comments

@dhiller
Copy link
Contributor

dhiller commented Jan 10, 2024

TL;DR

goal: make the botreview only look at pull requests that the review type is made for

Background

The botreview plugin has been created to automatically review pull requests that have been created by automation. It's initial implementation is intended to check expectation but it could easily extended to also check whether images are available etc.

Problem

Issue is that it currently picks up pull requests that are none of it's business. I.e. #3146 (comment) shows that the PR has been accidentally considered to be reviewed.

However, the review types are clearly made to only consider pull requests created by automation.

Task

Narrow down the pull requests to be considered per review type, such that it doesn't consider other pull requests and creates noise on it.

Suggestion: make the botreview only look at pull requests that have the correct subject for the pull request type

Subject examples

Review type1 Example PR subject2 GitHub Search Query3
bump_kubevirtci.go Bump kubevirtci PR Bump kubevirtci
image_update.go Run hack/bump-prow-job-images.sh Run hack/bump-prow-job-images.sh
kubevirt_uploader.go Run bazelisk run //robots/cmd/uploader:uploader -- -workspace /home/prow/go/src/github.com/kubevirt/project-infra/../kubevirt/WORKSPACE -dry-run=false Run bazelisk ...
prow_autobump.go Run hack/bump-prow.sh Run hack/bump-prow.sh

Footnotes

  1. The review type effectively is the implementation of the strategy for checking a set of reviews of the same type

  2. This is the subject of the reviews that the strategy is meant to check

  3. This query should yield all PRs that the strategy is meant to check

@dhiller
Copy link
Contributor Author

dhiller commented Jan 10, 2024

/kind bug

@dhiller
Copy link
Contributor Author

dhiller commented Jan 10, 2024

/kind prow

@kubevirt-bot
Copy link
Contributor

@dhiller: The label(s) kind/prow cannot be applied, because the repository doesn't have them.

In response to this:

/kind prow

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository.

@dhiller
Copy link
Contributor Author

dhiller commented Jan 10, 2024

/area automatin
/area prow

@kubevirt-bot kubevirt-bot added the area/prow Issues and PRs concerning KubeVirt Prow, i.e. configuration, setup etc. label Jan 10, 2024
@kubevirt-bot
Copy link
Contributor

@dhiller: The label(s) area/automatin cannot be applied, because the repository doesn't have them.

In response to this:

/area automatin
/area prow

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository.

@dhiller
Copy link
Contributor Author

dhiller commented Jan 10, 2024

/area automation

@kubevirt-bot kubevirt-bot added the area/automation Issues and PRs concerning automation, i.e. KubeVirt job updates, KubeVirtCI bumps etc. label Jan 10, 2024
@dhiller
Copy link
Contributor Author

dhiller commented Jan 10, 2024

/assign

@dhiller
Copy link
Contributor Author

dhiller commented Mar 8, 2024

/unassign
/good-first-issue

@kubevirt-bot
Copy link
Contributor

@dhiller:
This request has been marked as suitable for new contributors.

Guidelines

  • No Barrier to Entry
  • Clear Task
  • Solution Explained
  • Provides Context
  • Identifies Relevant Code
  • Gives Examples
  • Ready to Test
  • Goldilocks priority
  • Up-To-Date

For more details on the requirements of such an issue, please see here and ensure that they are met.

If this request no longer meets these requirements, the label can be removed
by commenting with the /remove-good-first-issue command.

In response to this:

/unassign
/good-first-issue

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository.

@kubevirt-bot kubevirt-bot added good first issue Identifies an issue that has been specifically created or selected for first-time contributors. help wanted Identifies an issue that has been specifically created or selected for new contributors. labels Mar 8, 2024
@jmhbnz
Copy link

jmhbnz commented Mar 22, 2024

I'm keen to pick this one up.

/assign

@jmhbnz
Copy link

jmhbnz commented Mar 22, 2024

Hey @dhiller - We met at the contribfest can you please point me to what the "good" pr's are for this bot so I can start thinking about filtering based on subject etc.

@dhiller
Copy link
Contributor Author

dhiller commented Mar 25, 2024

Hey @jmhbnz thanks for your interest in this! I've added a subsection Subject examples to the Task section inside the issue description. Please ping me for any other questions you should have.
Thanks for reaching out and it was great talking to you IRL :)
Looking forward to your contribution 💪

@dhiller
Copy link
Contributor Author

dhiller commented Mar 25, 2024

@jmhbnz one other thing to get you started - the func GuessReviewTypes selects the proper strategy - I'd go add the subject to the Reviewer struct and then modify it to ask each strategy whether the subject matches this review type.

@kubevirt-bot
Copy link
Contributor

Issues go stale after 90d of inactivity.
Mark the issue as fresh with /remove-lifecycle stale.
Stale issues rot after an additional 30d of inactivity and eventually close.

If this issue is safe to close now please do so with /close.

/lifecycle stale

@kubevirt-bot kubevirt-bot added the lifecycle/stale Denotes an issue or PR has remained open with no activity and has become stale. label Jun 23, 2024
@dhiller
Copy link
Contributor Author

dhiller commented Jul 11, 2024

/remove-lifecycle stale

@kubevirt-bot kubevirt-bot removed the lifecycle/stale Denotes an issue or PR has remained open with no activity and has become stale. label Jul 11, 2024
@kubevirt-bot
Copy link
Contributor

Issues go stale after 90d of inactivity.
Mark the issue as fresh with /remove-lifecycle stale.
Stale issues rot after an additional 30d of inactivity and eventually close.

If this issue is safe to close now please do so with /close.

/lifecycle stale

@kubevirt-bot kubevirt-bot added the lifecycle/stale Denotes an issue or PR has remained open with no activity and has become stale. label Oct 9, 2024
@kubevirt-bot
Copy link
Contributor

Stale issues rot after 30d of inactivity.
Mark the issue as fresh with /remove-lifecycle rotten.
Rotten issues close after an additional 30d of inactivity.

If this issue is safe to close now please do so with /close.

/lifecycle rotten

@kubevirt-bot kubevirt-bot added lifecycle/rotten Denotes an issue or PR that has aged beyond stale and will be auto-closed. and removed lifecycle/stale Denotes an issue or PR has remained open with no activity and has become stale. labels Nov 8, 2024
@dhiller
Copy link
Contributor Author

dhiller commented Nov 14, 2024

/remove-lifecycle rotten
/lifecycle frozen

@kubevirt-bot kubevirt-bot added lifecycle/frozen Indicates that an issue or PR should not be auto-closed due to staleness. and removed lifecycle/rotten Denotes an issue or PR that has aged beyond stale and will be auto-closed. labels Nov 14, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area/automation Issues and PRs concerning automation, i.e. KubeVirt job updates, KubeVirtCI bumps etc. area/prow Issues and PRs concerning KubeVirt Prow, i.e. configuration, setup etc. good first issue Identifies an issue that has been specifically created or selected for first-time contributors. help wanted Identifies an issue that has been specifically created or selected for new contributors. kind/bug lifecycle/frozen Indicates that an issue or PR should not be auto-closed due to staleness.
Projects
None yet
Development

No branches or pull requests

3 participants