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

API CSV files' quotes not properly escaped #3630

Closed
jsomeara opened this issue Aug 23, 2024 · 0 comments · Fixed by #3640
Closed

API CSV files' quotes not properly escaped #3630

jsomeara opened this issue Aug 23, 2024 · 0 comments · Fixed by #3640
Assignees

Comments

@jsomeara
Copy link
Collaborator

jsomeara commented Aug 23, 2024

Brief description of problem/feature

A column like description can have user-provided input that has quotes within it. This can result in an issue because these user-provided quotes are surrounded by system-added quotes, but the user-provided quotes are not properly escaped. This makes it practically impossible to properly read the CSV files.

Expected behavior

Quotes that are within quotes should be escaped.

Current behavior (add screenshots if applicable; check terminal & browser console for errors)

106737544,NoCurbRamp,2,false,176,6334751,"Mid-Beacon Hill",80572,fSo6mbIGlNVcNJALVY7nEw,47.56166,-122.31861,47.561657,-122.318634,149.125,-13.419642448425293,2,554,254,720,480,"https://maps.googleapis.com/maps/api/streetview?size=720x480&pano=fSo6mbIGlNVcNJALVY7nEw&heading=149.125&pitch=-13.419642448425293&fov=53.0&key=YOUR_API_KEY&signature=YOUR_SIGNATURE",2018-08,2019-09-17 09:19:32.636,4,false,2,1,0,"[]","Driveway that points into traffic without friction strip. It's a "ramp", but it's no curb ramp.",d52dc403-5474-4140-946a-74a09070835b

See underlined portion. This quoted word "ramp" is within quotes, meaning it should be escaped. However, the current system does not escape these user-provided quotes.

Steps to reproduce

image

  • Download CSV file with labels
  • Find a line with this issue
Potential solution

RFC-4180 says "If double-quotes are used to enclose fields, then a double-quote appearing inside a field must be escaped by preceding it with another double quote."
Source: https://stackoverflow.com/questions/17808511/how-to-properly-escape-a-double-quote-in-csv

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
2 participants