Skip to content

Commit 49a6b14

Browse files
committed
Dont iterate over None
1 parent 5ae144f commit 49a6b14

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

cpueff-goweb/spark/cpueff_stepchain_goweb.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -71,7 +71,7 @@ def udf_step_extract(row):
7171
_jobtype = row['meta_data']['jobtype']
7272
_ts = row['meta_data']['ts']
7373
if 'steps' in row and row['steps']:
74-
for step in row['steps']:
74+
for step in filter(None, row['steps']):
7575
if ('name' in step) and step['name'].lower().startswith('cmsrun'):
7676
step_res = {'Task': _task_name, 'ts': _ts, 'fwjr_id': _fwjr_id, 'JobType': _jobtype}
7777

0 commit comments

Comments
 (0)