Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix spaces around CSV quoted strings #15727

Merged
Prev Previous commit
Next Next commit
update comment
  • Loading branch information
thabetx committed May 11, 2024
commit a0e8ed0bac260351311b7b6bddee995fc3aec1ef
2 changes: 1 addition & 1 deletion cpp/src/io/csv/csv_gpu.cu
Original file line number Diff line number Diff line change
Expand Up @@ -351,7 +351,7 @@ CUDF_KERNEL void __launch_bounds__(csvparse_block_dim)
if (dtypes[actual_col].id() == cudf::type_id::STRING) {
auto end = next_delimiter;
if (not options.keepquotes) {
// Remove whitepaces only if there are quotes
// If the string is quoted, whitespace around the quotes get removed as well
auto const trimmed_field =
trim_whitespaces(field_start, end);
if ((*trimmed_field.first == options.quotechar) && (*(trimmed_field.second-1) == options.quotechar)) {
Expand Down