Skip to content

Commit

Permalink
failedadded to fail_stasuses (#12)
Browse files Browse the repository at this point in the history
  • Loading branch information
kiracih authored Dec 29, 2023
1 parent 65f5200 commit 0613be6
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion notification_service.py
Original file line number Diff line number Diff line change
Expand Up @@ -18,8 +18,9 @@ def notify(self, build):
self.logger.info(trigger_message)
return trigger_message, 200

fail_statuses = ["failing", "failed"]
build_status = build.get("state")
if build_status != "failing":
if build_status not in fail_statuses:
build_status_message = f"Not a build failure, no action taken for the build url={build_web_url}."
return build_status_message, 200

Expand Down

0 comments on commit 0613be6

Please sign in to comment.