This is an automated email from the ASF dual-hosted git repository.

sbp pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/tooling-trusted-releases.git


The following commit(s) were added to refs/heads/main by this push:
     new fbcf36a  Only enable the button to start a vote when checks have 
completed
fbcf36a is described below

commit fbcf36ae903b609df5670597ad9ef76d2b0c6741
Author: Sean B. Palmer <[email protected]>
AuthorDate: Fri Nov 28 14:17:28 2025 +0000

    Only enable the button to start a vote when checks have completed
---
 atr/templates/check-selected-release-info.html | 18 ++++++++++++++++--
 atr/templates/check-selected.html              |  2 +-
 2 files changed, 17 insertions(+), 3 deletions(-)

diff --git a/atr/templates/check-selected-release-info.html 
b/atr/templates/check-selected-release-info.html
index 4fd99fc..bbb042c 100644
--- a/atr/templates/check-selected-release-info.html
+++ b/atr/templates/check-selected-release-info.html
@@ -58,14 +58,28 @@
            title="View revision history"
            class="btn btn-secondary"><i class="bi bi-clock-history me-1"></i> 
Revisions</a>
         {% if revision_number %}
-          {% if has_files and release.project.policy_manual_vote %}
+          {% if has_files and release.project.policy_manual_vote and 
(ongoing_tasks_count == 0) %}
             <a href="{{ as_url(get.manual.start_selected_revision, 
project_name=release.project.name, version_name=release.version, 
revision=revision_number) }}"
                title="Start a manual vote on this draft"
                class="btn btn-success"><i class="bi bi-check-circle me-1"></i> 
Start manual vote</a>
-          {% elif has_files and (not strict_checking_errors) %}
+          {% elif has_files and release.project.policy_manual_vote %}
+            <a href="#"
+               title="Background tasks must complete first"
+               class="btn btn-success disabled"
+               role="button"
+               aria-disabled="true"
+               tabindex="-1"><i class="bi bi-check-circle me-1"></i> Start 
manual vote</a>
+          {% elif has_files and (not strict_checking_errors) and 
(ongoing_tasks_count == 0) %}
             <a href="{{ as_url(get.voting.selected_revision, 
project_name=release.project.name, version_name=release.version, 
revision=revision_number) }}"
                title="Start a vote on this draft"
                class="btn btn-success"><i class="bi bi-check-circle me-1"></i> 
Start voting</a>
+          {% elif has_files and (not strict_checking_errors) %}
+            <a href="#"
+               title="Background tasks must complete first"
+               class="btn btn-success disabled"
+               role="button"
+               aria-disabled="true"
+               tabindex="-1"><i class="bi bi-check-circle me-1"></i> Start 
voting</a>
           {% else %}
             <a href="#"
                title="Upload files to enable voting"
diff --git a/atr/templates/check-selected.html 
b/atr/templates/check-selected.html
index 1c20499..123bd0f 100644
--- a/atr/templates/check-selected.html
+++ b/atr/templates/check-selected.html
@@ -81,7 +81,7 @@
   {% if ongoing_tasks_count > 0 %}
     <div class="alert alert-warning" role="alert">
       <i class="bi bi-exclamation-triangle me-2"></i>
-      There {{ 'is' if ongoing_tasks_count == 1 else 'are' }} currently 
<strong>{{ ongoing_tasks_count }}</strong> background verification {{ 'task' if 
ongoing_tasks_count == 1 else 'tasks' }} running for the latest revision. 
Results shown below may be incomplete or outdated until the tasks finish. 
Refresh the page to see updates.
+      There {{ 'is' if ongoing_tasks_count == 1 else 'are' }} currently 
<strong>{{ ongoing_tasks_count }}</strong> background verification {{ 'task' if 
ongoing_tasks_count == 1 else 'tasks' }} running for the latest revision. 
Results shown below may be incomplete or outdated until the tasks finish. You 
cannot start a vote until the tasks finish. Refresh the page to see updates.
     </div>
   {% endif %}
 


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to