Skip to content

Inconsistent CSV output #276

@mcauer

Description

@mcauer

Bug Description

The way the CSV output is configured differs between endpoints.
Sometimes fields are quoted with double-quotes (/elements/count) and s.t. not (/elements/count/groupBy/boundary)
E.g.:

elements/count/

curl -X GET "https://api.ohsome.org/v1/elements/count?bboxes=8.67%2C49.39%2C8.71%2C49.42&filter=type%3Away%20and%20natural%3D*&format=csv&time=2014-01-01%2F2017-01-01%2FP1Y" -H  "accept: application/json"

# Copyright URL: https://ohsome.org/copyrights
# Copyright Text: © OpenStreetMap contributors
# API Version: 1.6.3
timestamp;value
"2014-01-01T00:00:00Z";"42.0"
"2015-01-01T00:00:00Z";"42.0"
"2016-01-01T00:00:00Z";"43.0"
"2017-01-01T00:00:00Z";"43.0"

elements/count/groupBy/boundary

curl -X GET "https://api.ohsome.org/v1/elements/count/groupBy/boundary?bboxes=8.67%2C49.39%2C8.71%2C49.42&filter=type%3Away%20and%20natural%3D*&format=csv&time=2014-01-01%2F2017-01-01%2FP1Y" -H  "accept: application/json"

# Copyright URL: https://ohsome.org/copyrights
# Copyright Text: © OpenStreetMap contributors
# API Version: 1.6.3
timestamp;boundary1
2014-01-01T00:00:00Z;42.0
2015-01-01T00:00:00Z;42.0
2016-01-01T00:00:00Z;43.0
2017-01-01T00:00:00Z;43.0

General Information

Please include the following general information about the issue and list any additional steps needed to reproduce the bug.

  • Version of the ohsome API : v1.6.3
  • Which API instance was requested: https://api.ohsome.org/v1`
  • Affected endpoint(s) /elements/count and /elements/count/groupbBy/boundary may be more
  • URL of your request (and request body if applicable): see above
  • Used HTTP method [GET or POST]: see above
  • Utilized tool/library for the request [e.g. cURL, Postman, ohsome-py, etc.]: see above

Expected Behaviour

Expected is that all ohsomeAPI CSV output follows the same encoding

Further Information

Error Messages, Logs, Screenshots

If applicable, add printed error messages, log files or screenshots to help explain your problem.

Additional Information

Add any other further information about the problem here.

Notes

Please consider to upload a file if request parameters, responses, error messages or logs are too long or poorly displayed in your bug report.

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions