Merge pull request #1249 from jberry-suse/repo_checker-openqa-only

repo_checker: review failed stagings with only openQA failures.
This commit is contained in:
Jimmy Berry 2017-11-09 16:15:38 -06:00 committed by GitHub
commit 3e191caa84
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -125,6 +125,18 @@ class RepoChecker(ReviewBot.ReviewBot):
# Corrupted requests may reference non-existent projects and will
# thus return a None status which should be considered not ready.
if not status or str(status['overall_state']) not in ('testing', 'review', 'acceptable'):
# Not in a "ready" state.
openQA_only = False # Not relevant so set to False.
if str(status['overall_state']) == 'failed':
# Exception to the rule is openQA only in failed state.
openQA_only = True
for project in api.project_status_walk(status):
if len(project['broken_packages']):
# Broken packages so not just openQA.
openQA_only = False
break
if not openQA_only:
self.logger.debug('{}: {} not ready'.format(request.reqid, group))
continue