Skip to main content

Validator for ARGO sensor metadata JSON

Project description

Argo Metadata Validator

DOI

Validator for ARGO sensor metadata JSON.

Schema definitions are taken from https://github.com/euroargodev/sensor_metadata_json.

Package: https://pypi.org/project/argo-metadata-validator

Usage

Installation

Install the package from PyPi with

pip install argo-metadata-validator

From the Terminal

Once installed, you can run the tool to validate files from the terminal (Bash, Powershell, etc.) as follows

argo-validate file_1.json,file_2.json

To output the results to a JSON file you can specify a path for this, e.g.

argo-validate input/file_1.json --output-file output/results.json

To see the available CLI options you can run argo-validate --help.

From Python

As well as the command-line script version the validator can be used as a Python package, e.g. from Python scripts or Jupyter notebooks.

See demos/argo_validator.ipynb for an example of how to validate and parse input metadata from within Python scripts.

Development

Poetry is used to manage the building of this package and managing the package dependencies.

To run the script locally:

  • poetry install
  • poetry run argo-validate

For example, from the root of the repo

poetry run argo-validate tests/files/valid_sensor.json

To run lint/tests, first install dev dependencies poetry install --with dev

  • poetry run task lint - Check linting
  • poetry run task format - Autofix lint errors (where possible)
  • poetry run task test - Run unit tests

Releasing a new version

This done by creating a new release in Github. Make sure the created tag follows SemVer conventions.

Project details


Download files

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

Source Distribution

argo_metadata_validator-0.0.7.tar.gz (27.5 kB view details)

Uploaded Source

Built Distribution

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

argo_metadata_validator-0.0.7-py3-none-any.whl (44.0 kB view details)

Uploaded Python 3

File details

Details for the file argo_metadata_validator-0.0.7.tar.gz.

File metadata

  • Download URL: argo_metadata_validator-0.0.7.tar.gz
  • Upload date:
  • Size: 27.5 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/2.0.1 CPython/3.11.14 Linux/6.11.0-1018-azure

File hashes

Hashes for argo_metadata_validator-0.0.7.tar.gz
Algorithm Hash digest
SHA256 b3f9d91ca0ec4aaadb178954a3d10b4c760c45fa8f4ca10ddb3c1a241ac1eff4
MD5 997c57fee2559662cae64a8f2a0bcecd
BLAKE2b-256 c3dfd0236584ca897f8c88f12bab219fd1df06948a62e91a28f92fab2d9d5c0d

See more details on using hashes here.

File details

Details for the file argo_metadata_validator-0.0.7-py3-none-any.whl.

File metadata

File hashes

Hashes for argo_metadata_validator-0.0.7-py3-none-any.whl
Algorithm Hash digest
SHA256 3b5547b4a46d674e98b5134f3ceb2ab1c0c734fd2f3d17029db03efa4c5c5733
MD5 94d6249c530578034f4cd154720e657c
BLAKE2b-256 51dd348c35c181e4366152ed273c0be4d23164aa3d7a126837e09b00eea0cb43

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page