forked from Imagelibrary/littlefs
scripts: Fixed some issues with -k/--keep-open
- Fixed a NameError in watch.py caused by an outdated variable name (renamed paths -> keep_open_paths). Yay for dynamic typing. - Fixed fieldnames is None issue when csv file is empty.
This commit is contained in:
@@ -207,7 +207,7 @@ def collect(csv_paths, defines=[]):
|
||||
with openio(path) as f:
|
||||
reader = csv.DictReader(f, restval='')
|
||||
fields.extend(
|
||||
k for k in reader.fieldnames
|
||||
k for k in reader.fieldnames or []
|
||||
if k not in fields)
|
||||
for r in reader:
|
||||
# filter by matching defines
|
||||
|
||||
Reference in New Issue
Block a user