Handle the case of 'SUPPORT_PROFILES=None' 24/162724/1
authorSoonKyu Park <sk7.park@samsung.com>
Tue, 5 Dec 2017 05:55:04 +0000 (14:55 +0900)
committerSoonKyu Park <sk7.park@samsung.com>
Tue, 5 Dec 2017 05:55:04 +0000 (14:55 +0900)
Change-Id: Ia68f8b863fc248b78ea521dfe38e32a59c3c66ef

job_gbs_ref_fullbuild.py

index 06e8d85..f38e8dd 100644 (file)
@@ -498,8 +498,9 @@ def main():
             ref_binary[line.split('"')[1]] = line.split('"')[3]
 
     #Add default profile supported by gbs
-    for profile in gbs_meta_default_profile.split(' '):
-        ref_binary[profile]=profile+':ref:latest'
+    if gbs_meta_default_profile:
+        for profile in gbs_meta_default_profile.split(' '):
+            ref_binary[profile]=profile+':ref:latest'
 
     print 'Each reference snapshot numbers are like below'
     print ref_binary
@@ -519,11 +520,10 @@ def main():
 
         _update_ref_bin_index(ref_binary,build_profile)
 
-        if SUPPORT_PROFILES.find(build_profile) == -1:
+        if not SUPPORT_PROFILES or SUPPORT_PROFILES.find(build_profile) == -1:
             print "skip fullbuild...\nGBS reference fullbuild is triggered only for %s" %SUPPORT_PROFILES
             os.chdir(original_dir)
             gbsmeta_data = {"event": event,
-                              "triggered_from": 'gbs_ref_fullbuild',
                               }
             trigger_next("update-gbs-meta",gbsmeta_data)
             return 0