Fix clusterfuzz check in auto-roll.

Minor fixes: Strip new lines from api key. Missing import. Use string query parameters.

BUG=
TBR=jarin@chromium.org

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

git-svn-id: https://v8.googlecode.com/svn/branches/bleeding_edge@21998 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
This commit is contained in:
machenbach@chromium.org 2014-06-25 08:44:59 +00:00
parent c0dd51efdb
commit 52ef087dcf
2 changed files with 3 additions and 2 deletions

View File

@ -80,7 +80,7 @@ class CheckClusterFuzz(Step):
result = self._side_effect_handler.ReadClusterFuzzAPI(
api_key, job_type="linux_asan_d8_dbg", reproducible="True",
open="True", bug_information="",
revision_greater_or_equal=self["last_push"])
revision_greater_or_equal=str(self["last_push"]))
if result:
print "Stop due to pending ClusterFuzz issues."
return True

View File

@ -37,6 +37,7 @@ import subprocess
import sys
import textwrap
import time
import urllib
import urllib2
from git_recipes import GitRecipesMixin
@ -209,7 +210,7 @@ class SideEffectHandler(object): # pragma: no cover
url_fh.close()
def ReadClusterFuzzAPI(self, api_key, **params):
params["api_key"] = api_key
params["api_key"] = api_key.strip()
params = urllib.urlencode(params)
headers = {"Content-type": "application/x-www-form-urlencoded"}