Skip to content

whitespace in csvs #32

@nonword

Description

@nonword

We should be careful not to allow whitespace to sneak into the CSVs and jsonlds. The only delimiter should be the ,; No optional whitespace.

For example, at some point recently the label for status:a became "Available ":

a,-,Available ,AVAILABLE,true,"for Sierra code ""-"", if hold present or if due date present, then requestable=false"

(From https://raw.githubusercontent.com/NYPL/nypl-core/master/vocabularies/csv/statuses.csv )

That, in turn, impacted the prefLabel: https://github.com/NYPL/nypl-core/blob/master/vocabularies/json-ld/statuses.json#L40 , which then drifted into serialized data. Which is not terrible but it breaks tests and could have other consequences downstream.

It's simple enough to trim values as a consumer of nypl-core, but ideally we'd trim it at the source so that integrators don't have to look for it.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions