Skip to main content

rac_schema_validator

Validators for RAC-specific JSONSchemas.

Requirements

Installation

The recommended way to install this package is using pip:

pip install rac_schema_validator

After installing pre-commit, install the git-hook scripts:

$ pre-commit install

Usage

This library has one main public method, is_valid(), which takes two required arguments:

  • the data to be validated
  • the JSONSchema to validate against

and a third optional argument:

  • a base schema to resolve references against (see official docs)
from rac_schema_validator import is_valid

data = {"key": "value" ... }
schema = { ... }
is_valid(data, schema)

Invalid data will raise a rac_schema_validator.exceptions.ValidationError, and an invalid schema will raise a jsonschema.exceptions.SchemaError.

Tests

rac_schema_validator comes with unit tests as well as linting. The easiest way to make sure all tests pass is to run tox from the root of the repository. This will execute all tests, and will also run autopep8 and flake8 linters against the codebase.

License

Code is released under an MIT license. SeeLICENSE.md.

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

rac_schema_validator-1.1.4.tar.gz (4.3 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

rac_schema_validator-1.1.4-py3-none-any.whl (4.1 kB view details)

Uploaded Python 3

File details

Details for the file rac_schema_validator-1.1.4.tar.gz.

File metadata

  • Download URL: rac_schema_validator-1.1.4.tar.gz
  • Upload date:
  • Size: 4.3 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/7.0.0 CPython/3.13.14

File hashes

Hashes for rac_schema_validator-1.1.4.tar.gz
Algorithm Hash digest
SHA256 b6feb0b31906976fe29537800287bce84e6d218e9040b52dcd2caa1921ee98ce
MD5 5dc76a80aabc190e6f2d1f27f84b11e3
BLAKE2b-256 31b3dd4725dcc433b732e68adb88699faea38823e00a9070a88837ceaba053c3

See more details on using hashes here.

Provenance

The following attestation bundles were made for rac_schema_validator-1.1.4.tar.gz:

Publisher: pythonpublish.yml on RockefellerArchiveCenter/rac_schema_validator

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file rac_schema_validator-1.1.4-py3-none-any.whl.

File metadata

File hashes

Hashes for rac_schema_validator-1.1.4-py3-none-any.whl
Algorithm Hash digest
SHA256 708cd483868503c8c7be7fff780ec2ee3cacca997b9500587c1ccf64c8162b95
MD5 5535ee47eb5ec440bec87f81f62a5fee
BLAKE2b-256 56c774dd5b48ebae0cf75b78b853e1d731b5107250bf6cf5cbc907a572dba85a

See more details on using hashes here.

Provenance

The following attestation bundles were made for rac_schema_validator-1.1.4-py3-none-any.whl:

Publisher: pythonpublish.yml on RockefellerArchiveCenter/rac_schema_validator

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Release history Release notifications | RSS feed

This release

1.1.4 This release

2 files

1.1.3

2 files

1.1.2

2 files

1.1.1

2 files

1.0

2 files

0.1

2 files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page