canonical-ubuntu-qa team mailing list archive
-
canonical-ubuntu-qa team
-
Mailing list archive
-
Message #03505
[Merge] ~andersson123/autopkgtest-cloud:add-running-count into autopkgtest-cloud:master
Tim Andersson has proposed merging ~andersson123/autopkgtest-cloud:add-running-count into autopkgtest-cloud:master.
Requested reviews:
Canonical's Ubuntu QA (canonical-ubuntu-qa)
For more details, see:
https://code.launchpad.net/~andersson123/autopkgtest-cloud/+git/autopkgtest-cloud/+merge/462883
--
Your team Canonical's Ubuntu QA is requested to review the proposed merge of ~andersson123/autopkgtest-cloud:add-running-count into autopkgtest-cloud:master.
diff --git a/charms/focal/autopkgtest-web/webcontrol/browse.cgi b/charms/focal/autopkgtest-web/webcontrol/browse.cgi
index e9bf6b3..d5a0bf9 100755
--- a/charms/focal/autopkgtest-web/webcontrol/browse.cgi
+++ b/charms/focal/autopkgtest-web/webcontrol/browse.cgi
@@ -445,6 +445,10 @@ def running():
] = queue_length
running_info = get_running_jobs()
+ packages = running_info.keys()
+ running_count = 0
+ for pkg in packages:
+ running_count += len(running_info[pkg].keys())
return render(
"browse-running.html",
@@ -453,6 +457,7 @@ def running():
queues_info=queues_info,
queues_lengths=queues_lengths,
running=running_info,
+ running_count=running_count,
)
diff --git a/charms/focal/autopkgtest-web/webcontrol/templates/browse-running.html b/charms/focal/autopkgtest-web/webcontrol/templates/browse-running.html
index 86e555b..e002aaa 100644
--- a/charms/focal/autopkgtest-web/webcontrol/templates/browse-running.html
+++ b/charms/focal/autopkgtest-web/webcontrol/templates/browse-running.html
@@ -3,6 +3,7 @@
{% block content %}
<h1 class="page-header">Currently running tests</h1>
+ <p>There are currently {{running_count}} running tests.</p>
<p>Click on the package name to jump to the currently running tests of that package.</p>
<table class="table-condensed table-striped">