| Index: appengine/findit/waterfall/suspected_cl_util.py
|
| diff --git a/appengine/findit/waterfall/suspected_cl_util.py b/appengine/findit/waterfall/suspected_cl_util.py
|
| index c84b01eec256405c0e7a58211458238d5aa55d56..3432279763ebd13032d8b0d0688b58a50f42f4d2 100644
|
| --- a/appengine/findit/waterfall/suspected_cl_util.py
|
| +++ b/appengine/findit/waterfall/suspected_cl_util.py
|
| @@ -120,12 +120,14 @@ def _HasNewFailures(current_failures, new_failures):
|
|
|
| def GetSuspectedCLConfidenceScoreAndApproach(
|
| confidences, cl_from_analyzed_build, cl_from_first_failed_build):
|
| - if not confidences or not cl_from_analyzed_build:
|
| + if not confidences or (
|
| + not cl_from_analyzed_build and not cl_from_first_failed_build):
|
| return None, None
|
|
|
| - if (cl_from_first_failed_build and not _HasNewFailures(
|
| - cl_from_analyzed_build.get('failures'),
|
| - cl_from_first_failed_build.get('failures'))):
|
| + if (cl_from_first_failed_build and (
|
| + not cl_from_analyzed_build or
|
| + not _HasNewFailures(cl_from_analyzed_build.get('failures'),
|
| + cl_from_first_failed_build.get('failures')))):
|
| # For non-first-time failures, the try job result is not recorded.
|
| # If there is no new failures in current build, use first failed build to
|
| # make sure the confidence score is correct.
|
|
|