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

arm 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 1a7d3d6  Return actual error if task fails, otherwise timeout
1a7d3d6 is described below

commit 1a7d3d6e60193ee80331a8ab50ca9c353dff6bc2
Author: Alastair McFarlane <[email protected]>
AuthorDate: Wed Dec 17 10:09:04 2025 +0000

    Return actual error if task fails, otherwise timeout
---
 atr/db/interaction.py | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/atr/db/interaction.py b/atr/db/interaction.py
index 3225e8a..bd9dc7d 100644
--- a/atr/db/interaction.py
+++ b/atr/db/interaction.py
@@ -470,6 +470,8 @@ async def wait_for_task(
             return False
         for _attempt in range(timeout_s * 10):
             await data.refresh(t)
+            if t.status == sql.TaskStatus.FAILED:
+                raise InteractionError(f"Task {task.id} failed with error 
{t.error}")
             if t.status == desired_status:
                 return True
             # Wait 100ms before checking again


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

Reply via email to