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

GitHub Pages validation badges don't validate the CSV against the schema #1002

Open
caiwilliamson opened this issue Jun 12, 2020 · 0 comments

Comments

@caiwilliamson
Copy link
Collaborator

Currently the validation badges on the GH Pages site only validate the CSV on its own, and do not validate the CSV against the schema, e.g. https://csvlint.io/?uri=https://caiwilliamson.github.io/test2/data/test2.csv&format=svg. I think it's possible to provide the url of a schema within that url (https://csvlint.io/documentation) to get the correct validation. For the static GH Pages site to be able to refer to the url of the schema file it needs to be in the git repo. And it is!

However, the schema file is only created in the repo on first publish (if you supply a schema) and never touched again. When the schema is changed it is actually updated in the datapackage.json (GH Pages site reads from this). Maybe someone was in the process of changing how this works and didn't finish. If you plan to fix the validation badges, you would need to ensure you also keep the schema file in the repo up to date (in the jekyll service).

Note: Octopub also generates validation pages using the csvlint gem internally e.g. /collection/53/file/64/validation. These results do validate the CSV against the schema. You may figure out a way to shove these links into the static html file for the GH Pages site by precompiling it somehow but it doesn't look trivial.

Related issue:
#953 (comment)

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

No branches or pull requests

1 participant