You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@bookkeeper.apache.org by si...@apache.org on 2018/02/28 18:34:43 UTC

[bookkeeper] branch master updated: Pull as many reviewers as possible when merging

This is an automated email from the ASF dual-hosted git repository.

sijie pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/bookkeeper.git


The following commit(s) were added to refs/heads/master by this push:
     new 45c5cf5  Pull as many reviewers as possible when merging
45c5cf5 is described below

commit 45c5cf5ec0f2560c8858a7167f8c1fc066bf0431
Author: Ivan Kelly <iv...@apache.org>
AuthorDate: Wed Feb 28 10:34:33 2018 -0800

    Pull as many reviewers as possible when merging
    
    Github uses pagination on some apis. This means that if there are a
    lot of comments on a issue, it may not pick up approvals by
    default. This patch increases the number of review comments to pull,
    from a default of 30 to 100. A proper fix would be to enable
    pagination using the Link header, but that's a much bigger change, for
    little return.
    
    Author: Ivan Kelly <iv...@apache.org>
    
    Reviewers: Sijie Guo <si...@apache.org>, Matteo Merli <mm...@apache.org>
    
    This closes #1220 from ivankelly/page_comments
---
 dev/bk-merge-pr.py | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/dev/bk-merge-pr.py b/dev/bk-merge-pr.py
index daf290e..2c1384f 100755
--- a/dev/bk-merge-pr.py
+++ b/dev/bk-merge-pr.py
@@ -453,7 +453,7 @@ def get_reviewers(pr_num):
                 reviewers_ids.add(comment['user']['login'])
 
     approval_review_states = ['approved']
-    pr_reviews = get_json('{0}/pulls/{1}/reviews'.format(GITHUB_API_BASE, pr_num), True)
+    pr_reviews = get_json('{0}/pulls/{1}/reviews?per_page=100'.format(GITHUB_API_BASE, pr_num), True)
     for review in pr_reviews:
         for approval_state in approval_review_states:
             if approval_state in review['state'].lower():

-- 
To stop receiving notification emails like this one, please contact
sijie@apache.org.