dkb-visa
dkb-visa copied to clipboard
html included in csv file
Note that sometimes the original csv-file includes information, formatted via html. I solved it like this:
# check that unparseable lines are not included as transactions
# dkb should really fix their csv export, they should have the
# money for that, right?
csv_text = csv_text.splitlines()
csv_text_filtered = []
for line in csv_text:
if "<br />" in line:
continue
else:
csv_text_filtered.append(line)
csv_text = "\n".join(csv_text_filtered)
This will exclude transactions that have <br />
in their description.