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

[CI] add github action requesting review by label #12715

Open
zetwhite opened this issue Feb 29, 2024 · 1 comment
Open

[CI] add github action requesting review by label #12715

zetwhite opened this issue Feb 29, 2024 · 1 comment
Labels
area/CI For our Continuous Integration type/suggestion I've a good idea :)

Comments

@zetwhite
Copy link
Contributor

zetwhite commented Feb 29, 2024

Motivation

If I want to get N approvals from @Samsung/one_onert on specific PR, I always have to assign the team N times as reviewers.
It is quite troublesome.

Suggestion

I'd like to add a Github Action that assigns the team as a reviewer based on given labels.
For example, if a PR has labels(approval: 2, review-by/onert), Let's make a github action assign the onert-team until It meets the approval count.


I don't know if a similar suggestion has been before or not.
So, feel free to give any comments!

@zetwhite zetwhite added area/CI For our Continuous Integration type/discussion We need discussion. Discussion itself can help. Even without conclusions! type/suggestion I've a good idea :) and removed type/discussion We need discussion. Discussion itself can help. Even without conclusions! labels Feb 29, 2024
@jyoungyun
Copy link
Contributor

jyoungyun commented Feb 29, 2024

I suggest using github-script to control GitHub REST API. :)

github-script:
https://github.com/actions/github-script

How to check the approved count:
https://docs.github.com/en/rest/pulls/reviews?apiVersion=2022-11-28#list-reviews-for-a-pull-request

How to add reviewers:
https://docs.github.com/en/rest/pulls/review-requests?apiVersion=2022-11-28#request-reviewers-for-a-pull-request

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area/CI For our Continuous Integration type/suggestion I've a good idea :)
Projects
None yet
Development

No branches or pull requests

2 participants