This shows you the differences between two versions of the page.
| Both sides previous revisionPrevious revision | |||
| docu:csheet:sysadm:script:python:read_csv [2022/01/05 13:47] – admin | docu:csheet:sysadm:script:python:read_csv [2022/01/05 13:48] (current) – admin | ||
|---|---|---|---|
| Line 34: | Line 34: | ||
| # and also convert the field to lowercase | # and also convert the field to lowercase | ||
| fields.append(re.sub(r' | fields.append(re.sub(r' | ||
| + | first = False | ||
| else: | else: | ||
| i = 0 | i = 0 | ||
| Line 45: | Line 46: | ||
| i += 1 | i += 1 | ||
| data.append(item) | data.append(item) | ||
| - | first = False | ||
| return data | return data | ||
| return [] | return [] | ||
| </ | </ | ||