aboutsummaryrefslogtreecommitdiffstats
path: root/tasks.py
diff options
context:
space:
mode:
Diffstat (limited to 'tasks.py')
-rw-r--r--tasks.py9
1 files changed, 9 insertions, 0 deletions
diff --git a/tasks.py b/tasks.py
index 74ff6b19..76d0d029 100644
--- a/tasks.py
+++ b/tasks.py
@@ -47,7 +47,16 @@ def download_artifacts(session):
paths = []
+ last_build_number = response.json()["number"]
for run in response.json()["runs"]:
+ if run["number"] != last_build_number:
+ print(
+ "Skipping {0} as it is not from the latest build ({1})".format(
+ run["url"], last_build_number
+ )
+ )
+ continue
+
response = session.get(
run["url"] + "api/json/",
headers={