Skip to content

Commit

Permalink
Merge pull request openSUSE#2981 from Vogtinator/hardenedrabbit
Browse files Browse the repository at this point in the history
gocd/rabbit-openqa.py: Ignore projects without a staging setup
  • Loading branch information
Vogtinator committed Jun 29, 2023
2 parents 3b612be + 18009e5 commit 009689f
Showing 1 changed file with 12 additions and 3 deletions.
15 changes: 12 additions & 3 deletions gocd/rabbit-openqa.py
Original file line number Diff line number Diff line change
Expand Up @@ -256,9 +256,18 @@ def start_consuming(self):
# initial state
self.projects_to_check = set()
for project in self.projects:
self.logger.info('Fetching ISOs of %s', project.name)
for sproj in project.init():
self.projects_to_check.add((project, sproj))
try:
self.logger.info('Fetching ISOs of %s', project.name)
for sproj in project.init():
self.projects_to_check.add((project, sproj))
except HTTPError as e:
if e.code == 404:
# No staging workflow? Have to protect against "rogue" projects
self.logger.error('Failed to load staging projects')
continue
else:
raise

self.logger.info('Finished fetching initial ISOs, listening')
super(Listener, self).start_consuming()

Expand Down

0 comments on commit 009689f

Please sign in to comment.