Skip to content

Commit

Permalink
Fix CSV error text (#3822)
Browse files Browse the repository at this point in the history
  • Loading branch information
comphead authored Mar 9, 2023
1 parent 053973a commit fb1dcc6
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions arrow-csv/src/writer.rs
Original file line number Diff line number Diff line change
Expand Up @@ -169,7 +169,7 @@ impl<W: Write> Writer<W> {
buffer.clear();
converter.value(row_idx).write(&mut buffer).map_err(|e| {
ArrowError::CsvError(format!(
"Error formatting row {} and column {}: {e}",
"Error processing row {}, col {}: {e}",
row_idx + 1,
col_idx + 1
))
Expand Down Expand Up @@ -614,7 +614,7 @@ sed do eiusmod tempor,-556132.25,1,,2019-04-18T02:45:55.555000000,23:46:03,foo

for batch in batches {
let err = writer.write(batch).unwrap_err().to_string();
assert_eq!(err, "Csv error: Error formatting row 2 and column 2: Cast error: Failed to convert 1926632005177685347 to temporal for Date64")
assert_eq!(err, "Csv error: Error processing row 2, col 2: Cast error: Failed to convert 1926632005177685347 to temporal for Date64")
}
drop(writer);
}
Expand Down

0 comments on commit fb1dcc6

Please sign in to comment.