You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@tvm.apache.org by GitBox <gi...@apache.org> on 2022/03/23 18:46:04 UTC

[GitHub] [tvm] driazati opened a new pull request #10734: [ci] Check existing reviews and requested reviews before cc-ing

driazati opened a new pull request #10734:
URL: https://github.com/apache/tvm/pull/10734


   This will re-request reviews from existing reviewers as in #10714 which is not intended, so this lists out existing reviews/requests and filters the new reviews to add based on those usernames.
   
   cc @areusch
   
   Thanks for contributing to TVM!   Please refer to guideline https://tvm.apache.org/docs/contribute/ for useful information and tips. After the pull request is submitted, please request code reviews from [Reviewers](https://github.com/apache/incubator-tvm/blob/master/CONTRIBUTORS.md#reviewers) by @ them in the pull request thread.
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@tvm.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [tvm] areusch merged pull request #10734: [ci] Check existing and requested reviews before cc-ing

Posted by GitBox <gi...@apache.org>.
areusch merged pull request #10734:
URL: https://github.com/apache/tvm/pull/10734


   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@tvm.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [tvm] areusch commented on a change in pull request #10734: [ci] Check existing and requested reviews before cc-ing

Posted by GitBox <gi...@apache.org>.
areusch commented on a change in pull request #10734:
URL: https://github.com/apache/tvm/pull/10734#discussion_r833731723



##########
File path: tests/scripts/github_cc_reviewers.py
##########
@@ -66,8 +67,36 @@ def find_reviewers(body: str) -> List[str]:
     if body is None:
         body = ""
 
-    to_add = find_reviewers(body)
-    print("Adding reviewers:", to_add)
+    new_reviewers = find_reviewers(body)
+    print("Found these reviewers:", new_reviewers)
+
+    if args.testing_reviews_json:
+        existing_reviews = json.loads(args.testing_reviews_json)
+    else:
+        github = GitHubRepo(token=os.environ["GITHUB_TOKEN"], user=user, repo=repo)
+        existing_reviews = github.get(f"pulls/{number}/reviews")
+
+    existing_review_users = [review["user"]["login"] for review in existing_reviews]

Review comment:
       should we also analyze the state of the review?




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@tvm.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [tvm] driazati commented on a change in pull request #10734: [ci] Check existing and requested reviews before cc-ing

Posted by GitBox <gi...@apache.org>.
driazati commented on a change in pull request #10734:
URL: https://github.com/apache/tvm/pull/10734#discussion_r833732708



##########
File path: tests/scripts/github_cc_reviewers.py
##########
@@ -66,8 +67,36 @@ def find_reviewers(body: str) -> List[str]:
     if body is None:
         body = ""
 
-    to_add = find_reviewers(body)
-    print("Adding reviewers:", to_add)
+    new_reviewers = find_reviewers(body)
+    print("Found these reviewers:", new_reviewers)
+
+    if args.testing_reviews_json:
+        existing_reviews = json.loads(args.testing_reviews_json)
+    else:
+        github = GitHubRepo(token=os.environ["GITHUB_TOKEN"], user=user, repo=repo)
+        existing_reviews = github.get(f"pulls/{number}/reviews")
+
+    existing_review_users = [review["user"]["login"] for review in existing_reviews]

Review comment:
       since this is just for notifying I don't think we need to, regardless of whether its approved/pending/changes requested the bot shouldn't take any action if the person is already in the review box




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@tvm.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org