Skip to main content

Agnostic Raw Data for Python

Project description

Agnostic Raw Data for Python

See the description of Agnostic Raw Data (ARD) in the Go ARD library.

The latest stable release of this library is available on PyPi:

pip install ard

This library has three main features:

  1. Allows you to easily transmit ARD in several formats: YAML, JSON, XML, and CBOR. Supports both encoding and decoding. Included is an ardconv CLI tool that can convert between all formats.
  2. Enable support for decoding YAML with complex keys. As it stands, the otherwise excellent ruamel.yaml library will choke on complex keys.
  3. Support for ARD-compatible extensions to JSON (CJSON). This allows for round-tripping ARD through JSON without losing type information, including support for integers, byte arrays, and maps with non-string keys.

Python's dict does not support un-hashable keys, making it difficult to work with complex keys. For this reason we provide the ard.Map class, which does support un-hashable keys and is otherwise a drop-in replacement for dict. It will be used automatically when decoding, if necessary.

Documentation is a work in progress! For now check out test.py for example use.

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

ard-0.0.5.tar.gz (8.1 kB view details)

Uploaded Source

Built Distribution

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

ard-0.0.5-py3-none-any.whl (13.4 kB view details)

Uploaded Python 3

File details

Details for the file ard-0.0.5.tar.gz.

File metadata

  • Download URL: ard-0.0.5.tar.gz
  • Upload date:
  • Size: 8.1 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.4.1 importlib_metadata/4.0.1 pkginfo/1.7.0 requests/2.25.1 requests-toolbelt/0.9.1 tqdm/4.60.0 CPython/3.9.4

File hashes

Hashes for ard-0.0.5.tar.gz
Algorithm Hash digest
SHA256 4e4c295a8b02132d50ead987da2324a8813247dbefbf554ed10f1d2a5e6dc05a
MD5 94ec8216be1aaf6328e89872b5319c94
BLAKE2b-256 4bb7bce4e29b1bbfc60e7fd24d62555d0e4a4c514006717cd5a504c416470165

See more details on using hashes here.

File details

Details for the file ard-0.0.5-py3-none-any.whl.

File metadata

  • Download URL: ard-0.0.5-py3-none-any.whl
  • Upload date:
  • Size: 13.4 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.4.1 importlib_metadata/4.0.1 pkginfo/1.7.0 requests/2.25.1 requests-toolbelt/0.9.1 tqdm/4.60.0 CPython/3.9.4

File hashes

Hashes for ard-0.0.5-py3-none-any.whl
Algorithm Hash digest
SHA256 739827da9de7b399a6801eec1781009695a4c83de345b024965b91254e08b83e
MD5 a31f512c7c3aa4431e0df7a61f6a567d
BLAKE2b-256 eb86c7b47a07f3da46dfd6191ec320b5a59dbbb5712f4943d491e1af29546235

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