Skip to main content

Opinionated YAML dump function for JSON serializable content.

Project description

JAMLDUMP

This library provides a to_jaml function that serializes JSON-serializable data in an arguably more readable YAML compatible fashion. The format chosen is supposed to be reproducible while avoiding the Norway-problem and it's cousins. We believe, this makes it useful for repeatedly templating the same (YAML) configuration files with the least expected surprise.

Notable features:

  • Dictionary keys need to be strings.
  • String values are always quoted (see Norway problem or versions decoded as numbers).
  • Indentation is always 2 spaces.
  • With level and embed_in, you can template a branch of a larger Yaml document.
  • When jinja2 is installed, a jinja2 filter is available.

For example usage, please take a look at the tests.

Versioning

This library follows SemVer. Its test suite specifies what is covered.

Development

This project is a case study for test driven development.

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

jamldump-1.2.2.tar.gz (15.1 kB view details)

Uploaded Source

Built Distribution

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

jamldump-1.2.2-py3-none-any.whl (15.9 kB view details)

Uploaded Python 3

File details

Details for the file jamldump-1.2.2.tar.gz.

File metadata

  • Download URL: jamldump-1.2.2.tar.gz
  • Upload date:
  • Size: 15.1 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.11.19 {"installer":{"name":"uv","version":"0.11.19","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Debian GNU/Linux","version":null,"id":"forky","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}

File hashes

Hashes for jamldump-1.2.2.tar.gz
Algorithm Hash digest
SHA256 9292ec70f71e56e4639050cda0deecb96f159a69ddec910e77a4a6105a6c1431
MD5 d739a57229e978cf68ed2541988d8d1b
BLAKE2b-256 f90f77e88028e33501cfa123f9f482fb66cfa9a1813c17de24226a3381ed51dd

See more details on using hashes here.

File details

Details for the file jamldump-1.2.2-py3-none-any.whl.

File metadata

  • Download URL: jamldump-1.2.2-py3-none-any.whl
  • Upload date:
  • Size: 15.9 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.11.19 {"installer":{"name":"uv","version":"0.11.19","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Debian GNU/Linux","version":null,"id":"forky","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}

File hashes

Hashes for jamldump-1.2.2-py3-none-any.whl
Algorithm Hash digest
SHA256 d0d10b8212062ef14c5412f73980373869cedf2c52bd74c1362536d63385d2da
MD5 9448f2e0b4eaa0d55ebd7ec5ed24c61a
BLAKE2b-256 53c8eb46229c0ddee7f3b3454c0126f0a2bef9f1e47ba7f893ccef6cf74da07c

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