File tree Expand file tree Collapse file tree 2 files changed +11
-5
lines changed Expand file tree Collapse file tree 2 files changed +11
-5
lines changed Original file line number Diff line number Diff line change @@ -176,7 +176,9 @@ def search(self, i):
176
176
177
177
# Tags may be a list (if comes internally from CM scripts) or string if
178
178
# comes from CMD
179
- if not isinstance (tags , if ) tags = tags .strip ()
179
+ if not isinstance (tags , list ):
180
+ tags = tags .strip ()
181
+
180
182
if ' ' in artifact : # or ',' in artifact:
181
183
del (i ['artifact' ])
182
184
if 'parsed_artifact' in i :
Original file line number Diff line number Diff line change @@ -561,7 +561,8 @@ def doc(i):
561
561
desc = value
562
562
563
563
564
- if isinstance (value , if ) desc = value ['desc' ]
564
+ if isinstance (value , dict ):
565
+ desc = value ['desc' ]
565
566
566
567
choices = value .get ('choices' , [])
567
568
if len (choices ) > 0 :
@@ -1257,10 +1258,13 @@ def regenerate_script_cmd(i):
1257
1258
# Cleanup from env everything that has a host path value
1258
1259
if i_run_cmd .get ('env' ):
1259
1260
for key in list (i_run_cmd .get ('env' )):
1260
- if isinstance (i_run_cmd ['env' ][key ], if ) del (i_run_cmd ['env' ][key ])
1261
- elif isinstance (i_run_cmd ['env' ][key ], elif ) values_to_remove = []
1261
+ if isinstance (i_run_cmd ['env' ][key ], str ):
1262
+ del (i_run_cmd ['env' ][key ])
1263
+ elif isinstance (i_run_cmd ['env' ][key ], list ):
1264
+ values_to_remove = []
1262
1265
for val in i_run_cmd ['env' ][key ]:
1263
- if isinstance (val , if ) values_to_remove .append (val )
1266
+ if isinstance (val , str ):
1267
+ values_to_remove .append (val )
1264
1268
if values_to_remove == i_run_cmd ['env' ][key ]:
1265
1269
del (i_run_cmd ['env' ][key ])
1266
1270
else :
You can’t perform that action at this time.
0 commit comments