Commit 48cda092 authored by Edward Lemur's avatar Edward Lemur Committed by Commit Bot

gerrit_util: Remove RemoveReviewers.

It's not used and uses basestring, which is not supported in Python 3.

Bug: 1002209
Change-Id: I9df900076978636c4a5c75e84432a8cc02d46909
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/1891654Reviewed-by: 's avatarAnthony Polito <apolito@google.com>
Commit-Queue: Edward Lesmes <ehmaldonado@chromium.org>
parent c9144527
......@@ -792,24 +792,6 @@ def AddReviewers(host, change, reviewers=None, ccs=None, notify=True,
ccs=(ccs-errored), notify=notify, accept_statuses=[200])
def RemoveReviewers(host, change, remove=None):
"""Removes reviewers from a change."""
if not remove:
return
if isinstance(remove, basestring):
remove = (remove,)
for r in remove:
path = 'changes/%s/reviewers/%s' % (change, r)
conn = CreateHttpConn(host, path, reqtype='DELETE')
try:
ReadHttpResponse(conn, accept_statuses=[204])
except GerritError as e:
raise GerritError(
e.http_status,
'Received unexpected http status while deleting reviewer "%s" '
'from change %s' % (r, change))
def SetReview(host, change, msg=None, labels=None, notify=None, ready=None):
"""Sets labels and/or adds a message to a code review."""
if not msg and not labels:
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment