gdp icon indicating copy to clipboard operation
gdp copied to clipboard

Column 3 has bad format

Open roll opened this issue 8 years ago • 5 comments

$ goodtables datapackage http://data.okfn.org/data/core/gdp/datapackage.json
DATASET
=======
{'error-count': 999, 'table-count': 1, 'time': 2.588, 'valid': False}

TABLE [1]
=========
{'datapackage': 'http://data.okfn.org/data/core/gdp/datapackage.json',
 'error-count': 999,
 'headers': ['Country Name', 'Country Code', 'Year', 'Value'],
 'row-count': 1000,
 'source': 'https://raw.githubusercontent.com/datasets/gdp/master/data/gdp.csv',
 'time': 1.948,
 'valid': False}
---------
[2,3] [non-castable-value] Row 2 has non castable value in column 3 (type: date, format: yyyy)
[3,3] [non-castable-value] Row 3 has non castable value in column 3 (type: date, format: yyyy)
...

from https://github.com/frictionlessdata/jsontableschema-py/issues/145

roll avatar Jan 16 '17 16:01 roll

@roll that is not a super informative output ;-) - what exactly is wrong with row 2? yyyy should count as a valid date no and the data looks ok:

https://github.com/datasets/gdp/blob/master/data/gdp.csv#L3

rufuspollock avatar Jan 16 '17 18:01 rufuspollock

@rufuspollock I suppose this format string is just against the prev stable spec (yyyy => fmt:%y): http://specs.frictionlessdata.io/json-table-schema/#date

It looks like the same issue https://github.com/datasets/gdp/issues/5 (cc @Fak3)

roll avatar Jan 17 '17 07:01 roll

Yes. Looking at the spec, the correct type of the column should be 'gyear' http://specs.frictionlessdata.io/json-table-schema/#gyear or 'date' with '%Y' format

Fak3 avatar Jan 17 '17 11:01 Fak3

@Fak3 but that type change is very recent. I guess we should change to gyear ... - will that work @roll?

rufuspollock avatar Jan 20 '17 12:01 rufuspollock

@rufuspollock gyear is not supported yet. Also wasn't there a plan to rename it to year? (we have many moving parts for now..)

roll avatar Jan 20 '17 12:01 roll