mirror of
https://github.com/littlefs-project/littlefs.git
synced 2025-12-26 09:08:30 +00:00
Fixed a couple corner cases in scripts when fields are empty
- Fixed added/removed count in scripts when an entry has no field in the expected results - Fixed a python-sort-type issue when by-field is missing in a result
This commit is contained in:
@@ -596,6 +596,9 @@ def main(gcda_paths, *,
|
||||
with openio(args['use']) as f:
|
||||
reader = csv.DictReader(f, restval='')
|
||||
for r in reader:
|
||||
if not any('cov_'+k in r and r['cov_'+k].strip()
|
||||
for k in CovResult._fields):
|
||||
continue
|
||||
try:
|
||||
results.append(CovResult(
|
||||
**{k: r[k] for k in CovResult._by
|
||||
@@ -639,6 +642,9 @@ def main(gcda_paths, *,
|
||||
with openio(args['diff']) as f:
|
||||
reader = csv.DictReader(f, restval='')
|
||||
for r in reader:
|
||||
if not any('cov_'+k in r and r['cov_'+k].strip()
|
||||
for k in CovResult._fields):
|
||||
continue
|
||||
try:
|
||||
diff_results.append(CovResult(
|
||||
**{k: r[k] for k in CovResult._by
|
||||
|
||||
Reference in New Issue
Block a user