Algorithmic-Trading icon indicating copy to clipboard operation
Algorithmic-Trading copied to clipboard

Invalid input CSV files result in fatal failure

Open mobeigi opened this issue 10 years ago • 4 comments

If you feed an invalid CSV file (filled with junk or in wrong format) into the program, the program will fail and the program will terminate with some run time error.

We need a nicer way to terminate if junk is fed into the program.

mobeigi avatar Apr 02 '15 06:04 mobeigi

I doubt this should happen for the purposes of the project.

jsnng avatar Apr 03 '15 01:04 jsnng

Yeah but there is always the chance someone will feed it an invalid CSV (junk) and we should probably have a nicer fail.

mobeigi avatar Apr 03 '15 03:04 mobeigi

btw, there is some error checking (since we can't input the CSV files that we were given without it), and it will simply not return anything if the CSV is wrong in some way. Can always the logger to the code if you want, but it will flood the log file with "errors" every time there is a "no trade" in the CSV.

jsnng avatar Apr 07 '15 04:04 jsnng

small fix (see #5): the issue where there is "no trade" means we can now log if the CSV isn't in the expected format. Unless we rewrite the whole thing and add all the data like how it is done in the parameters class we can't be sure that the file is in the correct format.

jsnng avatar Apr 21 '15 03:04 jsnng