Better English in failing_reasons

So that the status display and logs read more better.

Also, include the Zuul ref in JSON output so that the status
screen can do something intelligent with unprocessed items (also
it's an important bit of into).

Change-Id: I1429344917856edfaeefa4e9655c2dad8081cae5
This commit is contained in:
James E. Blair 2013-09-26 07:46:00 -07:00
parent 5f2feaf08c
commit 062c4fb6f2
2 changed files with 3 additions and 2 deletions

View File

@ -304,6 +304,7 @@ class Pipeline(object):
ret['item_ahead'] = None
ret['items_behind'] = [i.change._id() for i in item.items_behind]
ret['failing_reasons'] = item.current_build_set.failing_reasons
ret['zuul_ref'] = item.current_build_set.ref
ret['project'] = changeish.project.name
ret['enqueue_time'] = int(item.enqueue_time * 1000)
ret['jobs'] = []

View File

@ -998,7 +998,7 @@ class BasePipelineManager(object):
self.cancelJobs(item)
self.prepareRef(item)
if item.current_build_set.unable_to_merge:
failing_reasons.append("merge conflict")
failing_reasons.append("it has a merge conflict")
if self.launchJobs(item):
changed = True
if self.pipeline.didAnyJobFail(item):
@ -1007,7 +1007,7 @@ class BasePipelineManager(object):
try:
self.reportItem(item)
except MergeFailure:
failing_reasons.append("did not merge")
failing_reasons.append("it did not merge")
for item_behind in item.items_behind:
self.log.info("Resetting builds for change %s because the "
"item ahead, %s, failed to merge" %