Tolerate unstarted builds in rebaseline server.
authorbungeman <bungeman@google.com>
Fri, 5 Dec 2014 15:14:53 +0000 (07:14 -0800)
committerCommit bot <commit-bot@chromium.org>
Fri, 5 Dec 2014 15:14:53 +0000 (07:14 -0800)
Currently server.py --rietveld-issue will crash if there are any
unstarted trybots on the latest patch. Instead of crashing, warn
that the bot hasn't started yet.

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

gm/rebaseline_server/download_actuals.py

index 437b663..ae16770 100755 (executable)
@@ -197,6 +197,9 @@ class RietveldIssueActuals(object):
       logging.info('Fetching issue %s patch %s try %s...' %
                   (self._issue, patchset, try_builder))
       build_url = try_job_result.get('url', '<bad url>')
+      if build_url is None:
+        logging.warning('Builder %s has not started.' % (try_builder,))
+        continue
       gm_upload_output_url = build_url + urllib2.quote(upload_gm_step_url)
       logging.info('Fetching %s ...' % (gm_upload_output_url,))