Don't send reports without any job
Some CIs like to narrow their scope to a certain set of files. For that, they specify file mask on per-job basis. So there appear annoying comments with only "Build succeeded". (an example complaint: http://lists.openstack.org/pipermail/openstack-dev/2015-June/065367.html) Moreover, most of CIs which don't bother filtering, make lots of comments to doc/unittest changes, which is also wrong. By this change we drop such reports, leaving a record at debug level. We also don't want to report on failures in such configuration, as it's impossible to recheck them. Change-Id: Ifa43b6a2cd07d81b26dd2fe48e780c5ac94dbbb9
This commit is contained in:
parent
7fca9c1cc6
commit
88db9cb888
|
@ -1521,7 +1521,13 @@ class BasePipelineManager(object):
|
|||
def _reportItem(self, item):
|
||||
self.log.debug("Reporting change %s" % item.change)
|
||||
ret = True # Means error as returned by trigger.report
|
||||
if self.pipeline.didAllJobsSucceed(item):
|
||||
if not self.pipeline.getJobs(item):
|
||||
# We don't send empty reports with +1,
|
||||
# and the same for -1's (merge failures or transient errors)
|
||||
# as they cannot be followed by +1's
|
||||
self.log.debug("No jobs for change %s" % item.change)
|
||||
actions = []
|
||||
elif self.pipeline.didAllJobsSucceed(item):
|
||||
self.log.debug("success %s" % (self.pipeline.success_actions))
|
||||
actions = self.pipeline.success_actions
|
||||
item.setReportedResult('SUCCESS')
|
||||
|
|
Loading…
Reference in New Issue