quentinsf / icsv2ledger

Interactive importing of CSV files to Ledger
196 stars 70 forks source link

Fix tags IndexError #50

Closed thdox closed 12 years ago

thdox commented 12 years ago

Without this fix, the auto completion exits (see message below) because m[3] is not defined. This because it was not saved.

Traceback (most recent call last): File "/home/thierry/dev/icsv2ledger/icsv2ledger.py", line 608, in main() File "/home/thierry/dev/icsv2ledger/icsv2ledger.py", line 605, in main process_input_output(options.infile, options.outfile) File "/home/thierry/dev/icsv2ledger/icsv2ledger.py", line 587, in process_input_output ledger_lines = process_csv_lines(csv_lines) File "/home/thierry/dev/icsv2ledger/icsv2ledger.py", line 599, in process_csv_lines payee, account, tags = get_payee_and_account(entry) File "/home/thierry/dev/icsv2ledger/icsv2ledger.py", line 523, in get_payee_and_account payee, account, tags = m[1], m[2], m[3] IndexError: tuple index out of range