Fix: PAL Trending csv and txt tables 56/11656/2
authorTibor Frank <tifrank@cisco.com>
Tue, 10 Apr 2018 10:20:41 +0000 (12:20 +0200)
committerTibor Frank <tifrank@cisco.com>
Tue, 10 Apr 2018 10:22:05 +0000 (10:22 +0000)
 - Fix the problem with missing builds in the range of builds

Change-Id: I17fbc083ad88ee7c1b30c05f4f05022a1c92683d
Signed-off-by: Tibor Frank <tifrank@cisco.com>
resources/tools/presentation/generator_CPTA.py

index 967eb60..69a8df6 100644 (file)
@@ -362,9 +362,13 @@ def _generate_all_charts(spec, input_data):
     :type input_data: InputData
     """
 
-    builds = spec.cpta["data"].values()[0]
     job_name = spec.cpta["data"].keys()[0]
-    builds_lst = [str(build) for build in range(builds[0], builds[-1] + 1)]
+
+    builds_lst = list()
+    for build in spec.input["builds"][job_name]:
+        status = build["status"]
+        if status != "failed" and status != "not found":
+            builds_lst.append(str(build["build"]))
 
     # Get "build ID": "date" dict:
     build_dates = dict()

©2016 FD.io a Linux Foundation Collaborative Project. All Rights Reserved.
Linux Foundation is a registered trademark of The Linux Foundation. Linux is a registered trademark of Linus Torvalds.
Please see our privacy policy and terms of use.