gerrit_util: move changes: enable keep_all_votes
The default move behavior resets all non-blocking labels (including
Code-Review) which is not generally what we want. Preserve them.
Change-Id: I9c49582b4147e27d3ed6a439a610c9c667d7aa7e
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/2586110
Commit-Queue: Mike Frysinger <vapier@chromium.org>
Commit-Queue: Josip Sokcevic <sokcevic@google.com>
Auto-Submit: Mike Frysinger <vapier@chromium.org>
Reviewed-by: Josip Sokcevic <sokcevic@google.com>
diff --git a/gerrit_util.py b/gerrit_util.py
index 3b13f19..5bb62a9 100644
--- a/gerrit_util.py
+++ b/gerrit_util.py
@@ -714,7 +714,8 @@
def MoveChange(host, change, destination_branch):
"""Move a Gerrit change to different destination branch."""
path = 'changes/%s/move' % change
- body = {'destination_branch': destination_branch}
+ body = {'destination_branch': destination_branch,
+ 'keep_all_votes': True}
conn = CreateHttpConn(host, path, reqtype='POST', body=body)
return ReadHttpJsonResponse(conn)