Commit 71962e8c authored by machenbach's avatar machenbach Committed by Commit bot

[release] Remove unused sheriff feature from auto-roller.

BUG=chromium:559141
LOG=n
NOTRY=true

Review URL: https://codereview.chromium.org/1466233002

Cr-Commit-Position: refs/heads/master@{#32169}
parent f39d1cd4
......@@ -65,8 +65,6 @@ class RollChromium(Step):
"--use-commit-queue",
self["roll"],
]
if self._options.sheriff:
args.append("--sheriff")
if self._options.dry_run:
args.append("--dry-run")
if self._options.work_dir:
......
......@@ -149,7 +149,6 @@ class ChromiumRoll(ScriptsBase):
return [
Preparation,
PrepareRollCandidate,
DetermineV8Sheriff,
SwitchChromium,
UpdateChromiumCheckout,
UploadCL,
......
......@@ -766,32 +766,6 @@ class UploadStep(Step):
cc=self._options.cc)
class DetermineV8Sheriff(Step):
MESSAGE = "Determine the V8 sheriff for code review."
def RunStep(self):
self["sheriff"] = None
if not self._options.sheriff: # pragma: no cover
return
# The sheriff determined by the rotation on the waterfall has a
# @google.com account.
url = "https://chromium-build.appspot.com/p/chromium/sheriff_v8.js"
match = re.match(r"document\.write\('(\w+)'\)", self.ReadURL(url))
# If "channel is sheriff", we can't match an account.
if match:
g_name = match.group(1)
# Optimistically assume that google and chromium account name are the
# same.
self["sheriff"] = g_name + "@chromium.org"
self._options.reviewer = ("%s,%s" %
(self["sheriff"], self._options.reviewer))
print "Found active sheriff: %s" % self["sheriff"]
else:
print "No active sheriff found."
def MakeStep(step_class=Step, number=0, state=None, config=None,
options=None, side_effect_handler=DEFAULT_SIDE_EFFECT_HANDLER):
# Allow to pass in empty dictionaries.
......@@ -842,10 +816,6 @@ class ScriptsBase(object):
help="File to write results summary to.")
parser.add_argument("-r", "--reviewer", default="",
help="The account name to be used for reviews.")
parser.add_argument("--sheriff", default=False, action="store_true",
help=("Determine current sheriff to review CLs. On "
"success, this will overwrite the reviewer "
"option."))
parser.add_argument("-s", "--step",
help="Specify the step where to start work. Default: 0.",
default=0, type=int)
......
......@@ -1015,7 +1015,7 @@ Please close rolling in case of a roll revert:
https://v8-roll.appspot.com/
This only works with a Google account.
TBR=g_name@chromium.org,reviewer@chromium.org"""
TBR=reviewer@chromium.org"""
def testChromiumRoll(self):
# Setup fake directory structures.
......@@ -1038,8 +1038,6 @@ TBR=g_name@chromium.org,reviewer@chromium.org"""
"Version 3.22.4 (based on abc)\n"),
Cmd("git describe --tags roll_hsh", "3.22.4"),
Cmd("git describe --tags last_roll_hsh", "3.22.2.1"),
URL("https://chromium-build.appspot.com/p/chromium/sheriff_v8.js",
"document.write('g_name')"),
Cmd("git status -s -uno", "", cwd=chrome_dir),
Cmd("git checkout -f master", "", cwd=chrome_dir),
Cmd("git branch", "", cwd=chrome_dir),
......@@ -1060,7 +1058,6 @@ TBR=g_name@chromium.org,reviewer@chromium.org"""
self.Expect(expectations)
args = ["-a", "author@chromium.org", "-c", chrome_dir,
"--sheriff",
"-r", "reviewer@chromium.org",
"--last-roll", "last_roll_hsh",
"roll_hsh"]
......
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