Skip to content

Tento repozitář je udržován v rámci projektu č. CZ.03.4.74/0.0/0.0/15_025/0013983.

Notifications You must be signed in to change notification settings

datagov-cz/data-validator

Repository files navigation

Data Validator

Running using Docker

Data Validator is available as Docker image at GitHub registry.

Running using GitHub action

The configuration bellow runs the validator with every push and pull request. Create an action file (e.g. .github/workflows/data-validator.yml) with following content:

name: Validate data files
on:
  push:
  pull_request:
jobs:
  validate:
    runs-on: ubuntu-latest
    steps:
    - name: Checkout
      uses: actions/checkout@v4
    - name: Data validator
      uses: datagov-cz/data-validator/github@v2
      with:
        configuration: file://./.github/workflows/validate-syntax.ttl

Part of the configuration is path to configuration file (.github/workflows/validate-syntax.ttl). Please see section [Configuring the validation] for more information about this file.

Configuring the validation

Data Validator utilize RDF-based configuration to configure the validation process. See documentation/example-configurations.md file for examples of Data Validator configurations.

Validators

urn:DataValidator:TitaniumJsonLdSyntax

Check that file can be loaded as JSON-LD file with Titanium JSON-LD.

urn:DataValidator:JenaRdfNotEmpty

Using Jena loads the file and check it is not empty.

urn:DataValidator:JacksonJsonSyntax

Check that file can be loaded as JSON using Jackson.

urn:DataValidator:JenaRdfSyntax

Check that file can be loaded as RDF file using Jena.

Known issues and limitations

  • Validator fails to detect space between literal and language tag.

urn:DataValidator:Rdf4jRdfSyntax

Check that file can be loaded as RDF file using Eclipse RDF4J.

urn:DataValidator:Dom4jXmlSyntax

Check that file can be loaded as XML file using Dom4j.

urn:DataValidator:EveritJsonSchema

Validate JSON file using JSON Schema Validator.

Configuration

  • urn:schema : Path to JSON-Schema file.

urn:DataValidator:XercesXmlSchema

Validate XML document using dom4j and Apache Xerces2.

Configuration

  • urn:schemaUrl : Path to schema file.

Known issues and limitations

  • Apache Xerces2 does not fully support XML Schema 1.1.

urn:DataValidator:JenaRdfShaclSchema

Using Jena loads RDF content and check compliance with given SHACL shape.

Configuration

  • urn:shaclUrl : Path to file with SHACL.

Tento repozitář je udržován v rámci projektu OPZ č. CZ.03.4.74/0.0/0.0/15_025/0004172. Evropská unie - Evropský sociální fond - Operační program Zaměstnanost

About

Tento repozitář je udržován v rámci projektu č. CZ.03.4.74/0.0/0.0/15_025/0013983.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages