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

Analyse "schema" objects and not only { } #202

Open
quadrophobiac opened this issue Jul 7, 2017 · 1 comment
Open

Analyse "schema" objects and not only { } #202

quadrophobiac opened this issue Jul 7, 2017 · 1 comment

Comments

@quadrophobiac
Copy link
Contributor

From @CharlesNepote on March 28, 2017 22:36

For the moment, schemas are parsed from an unamed object { }, like in:
https://gist.githubusercontent.com/ldodds/9070198/raw/44076fa619d9c89188197130ca596cc99a25d693/senior-staff-organagram.json

In frictionlessdata specs and elsewhere, schemas might be embeded in another objects, like in Tabular Data spec: http://specs.frictionlessdata.io/tabular-data-package/#examples

datapackage.json
----------------

{
  "name": "my-dataset",
  "resources": [
    {
      "data": [ "data.csv" ],
      "schema": {
        "fields": [
          {
            "name": "var1",
            "type": "string"
          }
        ]
      }
    }
  ]
}

I'm also currently working on schemas embeded in a { "schema": { } } object, like in:
https://gist.githubusercontent.com/anonymous/1a6e20bd47945e9d8152ef43f5908082/raw/db03dd8938896c36914b6d9f73846e8148d6be58/schema.json

I think that CSV Lint could search for the "schema" object and parse this one. For the moment, CSV Lint treat it as an "Empty schema", see: http://csvlint.io/validation/58dade893235610004000051

Copied from original issue: Data-Liberation-Front/csvlint.io#280

@quadrophobiac
Copy link
Contributor Author

Hi @CharlesNepote, thanks for flagging this up for us. I am thinking this issue better belongs in the CSVlint Library repository due to it addressing schema validation, which is a function of the library more than the service. What do you think - would you mind if I closed and reopened the issue against the CSVlint library, and tag you so you can be kept updated on progress on it?

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

No branches or pull requests

1 participant