Fix default merge failure reports
Commit 385d11e2ed moved the logic
that performs report formatting into the reporters themselves. But
it also contained a logic change to the formatting.
Previously, if an item was not mergeable, it was reported without
a job list, regardless if the merge-failure or standard failure
reporter was used. With that change, if a pipeline specified a
merge-failure message reporter, it would not format the job list,
but if no merge-failure reporter was supplied, and the standard
failure reporter was used, the standard failure reporter would not
check whether a merge-failure happened and instead always try to
format the job list.
Change-Id: If65d4f64d6558a544d3d0c2cc0b32ad7786a6bcd
This commit is contained in:
@@ -84,6 +84,8 @@ class BaseReporter(object):
|
||||
def _formatItemReportFailure(self, pipeline, item):
|
||||
if item.dequeued_needing_change:
|
||||
msg = 'This change depends on a change that failed to merge.\n'
|
||||
elif not pipeline.didMergerSucceed(item):
|
||||
msg = pipeline.merge_failure_message
|
||||
else:
|
||||
msg = (pipeline.failure_message + '\n\n' +
|
||||
self._formatItemReportJobs(pipeline, item))
|
||||
|
||||
Reference in New Issue
Block a user