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

Provide more fields in TableSchemaError #147

Open
ffflabs opened this issue Jun 26, 2018 · 0 comments
Open

Provide more fields in TableSchemaError #147

ffflabs opened this issue Jun 26, 2018 · 0 comments
Labels

Comments

@ffflabs
Copy link

ffflabs commented Jun 26, 2018

As said in README.md

There is a missingValues property in Table Schema specification. As a first try we set missingValues to N/A in table.schema.descriptor

It would be nice if TableSchemaError, instead of having attributes:

{
message: 'The value "N/A" in column "geometry" is not type "geojson" and format "topojson"',
columnNumber: 10,
rowNumber: 5
}

could have:

{
message: 'The value "N/A" in column "geometry" is not type "geojson" and format "topojson"',
columnNumber: 10,
rowNumber: 5,
offendingValue: 'N/A',
column: 'geometry',
expectedType: 'geojson',
expectedFormat: 'topojson'
}

(honestly, offendingValue would be enough)

Currently, if I want to add offending values to missingValues I have to do a regex on TableSchemaError.message.

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

No branches or pull requests

2 participants