From eb1b70aa9bf7b54283c4eb7c9721da74d63b51ab Mon Sep 17 00:00:00 2001 From: Jelte Fennema-Nio Date: Sat, 1 Mar 2025 14:33:15 +0100 Subject: [PATCH] Show a CI timeout as a failure If things take too long, then CFBot will mark the build as timed out. Such builds would not have that "timeout" status reflected correctly, and would be displayed as running forever. --- pgcommitfest/commitfest/templates/commitfest.html | 2 +- pgcommitfest/commitfest/views.py | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/pgcommitfest/commitfest/templates/commitfest.html b/pgcommitfest/commitfest/templates/commitfest.html index ac5b17de..419dbe33 100644 --- a/pgcommitfest/commitfest/templates/commitfest.html +++ b/pgcommitfest/commitfest/templates/commitfest.html @@ -101,7 +101,7 @@

{{p.is_open|yesno:"Active patches,Closed patches"}}

- {%if p.cfbot_results.failed > 0 %} + {%if p.cfbot_results.failed > 0 or p.cfbot_results.branch_status == 'failed' or p.cfbot_results.branch_status == 'timeout' %} {%elif p.cfbot_results.completed < p.cfbot_results.total %} diff --git a/pgcommitfest/commitfest/views.py b/pgcommitfest/commitfest/views.py index 452a81f1..90dbe6a0 100644 --- a/pgcommitfest/commitfest/views.py +++ b/pgcommitfest/commitfest/views.py @@ -304,6 +304,7 @@ def commitfest(request, cfid): count(*) total, string_agg(task.task_name, ', ') FILTER (WHERE task.status in ('ABORTED', 'ERRORED', 'FAILED')) as failed_task_names, branch.commit_id IS NULL as needs_rebase, + branch.status as branch_status, branch.apply_url, branch.patch_count, branch.first_additions,