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

Validate schemas towards the JSON metaschema #208

Closed
e-backmark-ericsson opened this issue May 6, 2024 · 1 comment · Fixed by #219
Closed

Validate schemas towards the JSON metaschema #208

e-backmark-ericsson opened this issue May 6, 2024 · 1 comment · Fixed by #219
Assignees
Milestone

Comments

@e-backmark-ericsson
Copy link
Contributor

There is a way to validate JSON schemas towards their JSON metaschemas. We should make use of that in our checks.

@afrittoli
Copy link
Contributor

This tool https://check-jsonschema.readthedocs.io/ has the option to validate a schema against the meta schema, so it might be a good option. It also supports pre-commit

@afrittoli afrittoli modified the milestones: v0.5, v0.4 May 9, 2024
afrittoli added a commit to afrittoli/cdevents-spec that referenced this issue May 10, 2024
Add validation of jsonschemas to our CI.
The links and embeddedlinks schemas where invalid,
as well as the references to them from the event
schemas, so fixing all those to let CI pass.

Switch to ajv for example validation, which allows for
validation of both JSON documents as well as schemas.

ajv let users load references schemas from files into
the tool offline databases, which enables offline
validation of unpublished schemas.

Since ajv is javascript, update the GitHub action
workflow to javascript.

Fixes: cdevents#208
Fixes: cdevents#211

Signed-off-by: Andrea Frittoli <andrea.frittoli@gmail.com>
afrittoli added a commit to afrittoli/cdevents-spec that referenced this issue May 10, 2024
Add validation of jsonschemas to our CI.
The links and embeddedlinks schemas where invalid,
as well as the references to them from the event
schemas, so fixing all those to let CI pass.

Switch to ajv for example validation, which allows for
validation of both JSON documents as well as schemas.

ajv let users load references schemas from files into
the tool offline databases, which enables offline
validation of unpublished schemas.

Since ajv is javascript, update the GitHub action
workflow to javascript.

Fixes: cdevents#208
Fixes: cdevents#211

Signed-off-by: Andrea Frittoli <andrea.frittoli@gmail.com>
afrittoli added a commit to afrittoli/cdevents-spec that referenced this issue May 10, 2024
Add validation of jsonschemas to our CI.
The links and embeddedlinks schemas where invalid,
as well as the references to them from the event
schemas, so fixing all those to let CI pass.

Switch to ajv for example validation, which allows for
validation of both JSON documents as well as schemas.

ajv let users load references schemas from files into
the tool offline databases, which enables offline
validation of unpublished schemas.

Since ajv is javascript, update the GitHub action
workflow to javascript.

Fixes: cdevents#208
Fixes: cdevents#211

Signed-off-by: Andrea Frittoli <andrea.frittoli@gmail.com>
afrittoli added a commit to afrittoli/cdevents-spec that referenced this issue May 10, 2024
Add validation of jsonschemas to our CI.
The links and embeddedlinks schemas where invalid,
as well as the references to them from the event
schemas, so fixing all those to let CI pass.

Switch to ajv for example validation, which allows for
validation of both JSON documents as well as schemas.

ajv let users load references schemas from files into
the tool offline databases, which enables offline
validation of unpublished schemas.

Since ajv is javascript, update the GitHub action
workflow to javascript.

Fixes: cdevents#208
Fixes: cdevents#211

Signed-off-by: Andrea Frittoli <andrea.frittoli@gmail.com>
afrittoli added a commit to afrittoli/cdevents-spec that referenced this issue May 10, 2024
Add validation of jsonschemas to our CI.
The links and embeddedlinks schemas where invalid,
as well as the references to them from the event
schemas, so fixing all those to let CI pass.

Switch to ajv for example validation, which allows for
validation of both JSON documents as well as schemas.

ajv let users load references schemas from files into
the tool offline databases, which enables offline
validation of unpublished schemas.

Since ajv is javascript, update the GitHub action
workflow to javascript.

Fixes: cdevents#208
Fixes: cdevents#211

Signed-off-by: Andrea Frittoli <andrea.frittoli@gmail.com>
afrittoli added a commit to afrittoli/cdevents-spec that referenced this issue May 10, 2024
Add validation of jsonschemas to our CI.
The links and embeddedlinks schemas where invalid,
as well as the references to them from the event
schemas, so fixing all those to let CI pass.

Switch to ajv for example validation, which allows for
validation of both JSON documents as well as schemas.

ajv let users load references schemas from files into
the tool offline databases, which enables offline
validation of unpublished schemas.

Since ajv is javascript, update the GitHub action
workflow to javascript.

Fixes: cdevents#208
Fixes: cdevents#211

Signed-off-by: Andrea Frittoli <andrea.frittoli@gmail.com>
afrittoli added a commit to afrittoli/cdevents-spec that referenced this issue May 10, 2024
Add validation of jsonschemas to our CI.
The links and embeddedlinks schemas where invalid,
as well as the references to them from the event
schemas, so fixing all those to let CI pass.

Switch to ajv for example validation, which allows for
validation of both JSON documents as well as schemas.

ajv let users load references schemas from files into
the tool offline databases, which enables offline
validation of unpublished schemas.

Since ajv is javascript, update the GitHub action
workflow to javascript.

Fixes: cdevents#208
Fixes: cdevents#211

Signed-off-by: Andrea Frittoli <andrea.frittoli@gmail.com>
afrittoli added a commit to afrittoli/cdevents-spec that referenced this issue May 10, 2024
Add validation of jsonschemas to our CI.
The links and embeddedlinks schemas where invalid,
as well as the references to them from the event
schemas, so fixing all those to let CI pass.

Switch to ajv for example validation, which allows for
validation of both JSON documents as well as schemas.

ajv let users load references schemas from files into
the tool offline databases, which enables offline
validation of unpublished schemas.

Since ajv is javascript, update the GitHub action
workflow to javascript.

Fixes: cdevents#208
Fixes: cdevents#211

Signed-off-by: Andrea Frittoli <andrea.frittoli@gmail.com>
afrittoli added a commit to afrittoli/cdevents-spec that referenced this issue May 10, 2024
Add validation of jsonschemas to our CI.
The links and embeddedlinks schemas where invalid,
as well as the references to them from the event
schemas, so fixing all those to let CI pass.

Switch to ajv for example validation, which allows for
validation of both JSON documents as well as schemas.

ajv let users load references schemas from files into
the tool offline databases, which enables offline
validation of unpublished schemas.

Since ajv is javascript, update the GitHub action
workflow to javascript.

Fixes: cdevents#208
Fixes: cdevents#211

Signed-off-by: Andrea Frittoli <andrea.frittoli@gmail.com>
afrittoli added a commit to afrittoli/cdevents-spec that referenced this issue May 10, 2024
Add validation of jsonschemas to our CI.
The links and embeddedlinks schemas where invalid,
as well as the references to them from the event
schemas, so fixing all those to let CI pass.

Switch to ajv for example validation, which allows for
validation of both JSON documents as well as schemas.

ajv let users load references schemas from files into
the tool offline databases, which enables offline
validation of unpublished schemas.

Since ajv is javascript, update the GitHub action
workflow to javascript.

Fixes: cdevents#208
Fixes: cdevents#211

Signed-off-by: Andrea Frittoli <andrea.frittoli@gmail.com>
afrittoli added a commit to afrittoli/cdevents-spec that referenced this issue May 10, 2024
Add validation of jsonschemas to our CI.
The links and embeddedlinks schemas where invalid,
as well as the references to them from the event
schemas, so fixing all those to let CI pass.

Switch to ajv for example validation, which allows for
validation of both JSON documents as well as schemas.

ajv let users load references schemas from files into
the tool offline databases, which enables offline
validation of unpublished schemas.

Since ajv is javascript, update the GitHub action
workflow to javascript.

Fixes: cdevents#208
Fixes: cdevents#211

Signed-off-by: Andrea Frittoli <andrea.frittoli@gmail.com>
afrittoli added a commit to afrittoli/cdevents-spec that referenced this issue May 10, 2024
Add validation of jsonschemas to our CI.
The links and embeddedlinks schemas where invalid,
as well as the references to them from the event
schemas, so fixing all those to let CI pass.

Switch to ajv for example validation, which allows for
validation of both JSON documents as well as schemas.

ajv let users load references schemas from files into
the tool offline databases, which enables offline
validation of unpublished schemas.

Since ajv is javascript, update the GitHub action
workflow to javascript.

Fixes: cdevents#208
Fixes: cdevents#211

Signed-off-by: Andrea Frittoli <andrea.frittoli@gmail.com>
afrittoli added a commit that referenced this issue May 14, 2024
Add validation of jsonschemas to our CI.
The links and embeddedlinks schemas where invalid,
as well as the references to them from the event
schemas, so fixing all those to let CI pass.

Switch to ajv for example validation, which allows for
validation of both JSON documents as well as schemas.

ajv let users load references schemas from files into
the tool offline databases, which enables offline
validation of unpublished schemas.

Since ajv is javascript, update the GitHub action
workflow to javascript.

Fixes: #208
Fixes: #211

Signed-off-by: Andrea Frittoli <andrea.frittoli@gmail.com>
afrittoli added a commit that referenced this issue May 14, 2024
Add validation of jsonschemas to our CI.
The links and embeddedlinks schemas where invalid,
as well as the references to them from the event
schemas, so fixing all those to let CI pass.

Switch to ajv for example validation, which allows for
validation of both JSON documents as well as schemas.

ajv let users load references schemas from files into
the tool offline databases, which enables offline
validation of unpublished schemas.

Since ajv is javascript, update the GitHub action
workflow to javascript.

Fixes: #208
Fixes: #211

Signed-off-by: Andrea Frittoli <andrea.frittoli@gmail.com>
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

Successfully merging a pull request may close this issue.

2 participants