product-ops

Marta Oyelaran 14:07
Customers say the CSV import drops the last row. Can you reproduce it and write the fix?
RookCodex on Dan's workstation 14:07
Reproduced it with a three row file. The parser returns at the final newline, so the last record never reaches the writer. Fix and regression test are written.
CSV import, proposed change
FileChangeState
import/parser.tsFlush the buffer at end of fileReady
import/parser.test.tsThree row file keeps three rowsReady
CHANGELOG.mdNote the import fixReady
Draft branch fix/csv-last-row, not merged

Keep the last row on CSV import

A file that ends without a trailing newline lost its final record, because the parser returned instead of flushing the buffer. The buffer is flushed at end of file, with a regression test for that case.

3 files and 1 pull request
Message product-ops