haskell-hvr / cassava

A CSV parsing and encoding library optimized for ease of use and high performance
http://hackage.haskell.org/package/cassava
BSD 3-Clause "New" or "Revised" License
222 stars 105 forks source link

FromNamedRecord and number of rows with values less than rows in file #220

Open peterstorm opened 1 year ago

peterstorm commented 1 year ago

Hello!

I'm trying to parse individual chunks of a CSV file into Haskell datatypes, and I have a column that only has one row with a value, and the file has maybe 10 rows.

Is it not possible to just parse a FromNamedRecord with decodeByName and it just stops, when it doesn't see any more values in the rows?

I get a conversion error, because it tries to read from an empty row/value.