Skip to main content

Fast YAML linter inspired by yamllint

Project description

ryl

ryl - the Rust YAML linter - is intended to ultimately be a drop-in replacement for yamllint. It is usable today, but parity and edge-case behaviour are still maturing.

Full documentation lives at https://ryl-docs.pages.dev/.

Compatibility note

  • ryl aims to match yamllint behaviour and includes many parity tests.
  • ryl uses the granit-parser parser stack, while yamllint uses the PyYAML parser stack.
  • granit-parser and PyYAML do not always agree on which files are valid YAML.
  • ryl targets YAML 1.2 strictly. yamllint defaults to YAML 1.1 semantics, so bareword booleans like yes / no / on / off (and case variants) are plain strings in ryl and booleans in yamllint. Leading-zero integers like 0755 are decimal in ryl and octal in yamllint. The same 1.2 semantics also apply when ryl parses .yamllint configuration files inherited from yamllint. See the YAML version compatibility page for the practical implications.

Quick start

# Using uv (Python)
uvx ryl .

# Using npx (Node.js)
npx @owenlamont/ryl .

For prek / pre-commit integration, see ryl-pre-commit.

Installation

uv tool install ryl                 # uv
npm install -g @owenlamont/ryl      # npm
pip install ryl                     # pip
cargo install ryl                   # cargo

Status and scope

  • All 23 yamllint rules are implemented. The current rule reference and per-rule pages are at https://ryl-docs.pages.dev/rules/.
  • Auto-fixing (--fix) is supported for braces, brackets, commas, comments, comments-indentation, new-line-at-end-of-file, new-lines, and quoted-strings. The set of rules that may apply fixes is configurable via the TOML [fix] table.
  • TOML is the recommended configuration format and supports ryl-only features that have no upstream equivalent: the [fix] table, [per-file-ignores], and rule options such as allow-double-quotes-for-escaping.
  • yamllint-style YAML configuration is also accepted (.yamllint, .yamllint.yml, .yamllint.yaml) for drop-in compatibility, including the built-in default, relaxed, and empty presets via extends. An existing yamllint configuration can be converted with ryl --migrate-configs --migrate-write.
  • --list-files prints the files ryl would lint (after ignores and config discovery) and exits, without running rules. --no-warnings suppresses warning-level diagnostics in the output. --strict turns a warning-only run into exit code 2.
  • Pass - as the input to read YAML from stdin (ruff convention). Add --stdin-filename <PATH> so diagnostics, project-config discovery, and path-based filtering (yaml-files, per-file-ignores, per-rule ignore) use that filename. Without it, diagnostics are labelled <stdin>, config is anchored at the current working directory, and all path-based filtering is skipped so every enabled rule runs. - cannot be combined with other inputs or with --fix.
  • Run ryl --help for the authoritative CLI reference.

For installation walkthroughs, configuration presets, and per-rule documentation, see the docs site.

Performance

ryl is significantly faster than yamllint on large trees. The figure below is from a 5x5 file-count × file-size matrix with 5 runs per point:

Benchmark: ryl vs yamllint scaling (5x5 matrix, 5 runs per point)

The benchmark script is in scripts/benchmark_perf_vs_yamllint.py; run it with --help for the full option set.

Acknowledgements

This project exists thanks to the tooling and ecosystems around YAML linting and developer automation, especially:

  • yamllint - for giving me the shoulders to stand on and the source of many of the automated tests that ryl uses now to check for behaviour parity. Copying the behaviour of an existing tool is infinitely easier than building one from scratch - there'd be no ryl without yamllint.
  • ruff - for showing the power of Rust tooling for Python development and inspiring the config and API for ryl.
  • rumdl - for giving me another template to follow for Rust tooling and showing me almost the only dev tool I was still using after this that wasn't written in Rust was yamllint (which inspired me to tackle this project).
  • saphyr - ryl's vendored YAML DOM is derived from saphyr, and saphyr's developers were very patient in showing some of the nuance and complexity of parsing YAML which I was embarrassingly ignorant of when starting ryl.
  • granit-parser - a saphyr-parser fork with comment and style metadata that ryl uses for event-stream parsing.
  • esbuild and biome - for providing the "binary wrapper" blueprint for distributing high-performance native tools via NPM.

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

ryl-0.10.1.tar.gz (208.7 kB view details)

Uploaded Source

Built Distributions

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

ryl-0.10.1-py3-none-win_arm64.whl (2.1 MB view details)

Uploaded Python 3Windows ARM64

ryl-0.10.1-py3-none-win_amd64.whl (2.2 MB view details)

Uploaded Python 3Windows x86-64

ryl-0.10.1-py3-none-musllinux_1_2_x86_64.whl (2.7 MB view details)

Uploaded Python 3musllinux: musl 1.2+ x86-64

ryl-0.10.1-py3-none-musllinux_1_2_aarch64.whl (2.6 MB view details)

Uploaded Python 3musllinux: musl 1.2+ ARM64

ryl-0.10.1-py3-none-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (2.6 MB view details)

Uploaded Python 3manylinux: glibc 2.17+ x86-64

ryl-0.10.1-py3-none-manylinux_2_17_s390x.manylinux2014_s390x.whl (2.7 MB view details)

Uploaded Python 3manylinux: glibc 2.17+ s390x

ryl-0.10.1-py3-none-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl (2.9 MB view details)

Uploaded Python 3manylinux: glibc 2.17+ ppc64le

ryl-0.10.1-py3-none-manylinux_2_17_i686.manylinux2014_i686.whl (2.8 MB view details)

Uploaded Python 3manylinux: glibc 2.17+ i686

ryl-0.10.1-py3-none-manylinux_2_17_armv7l.manylinux2014_armv7l.whl (2.5 MB view details)

Uploaded Python 3manylinux: glibc 2.17+ ARMv7l

ryl-0.10.1-py3-none-manylinux_2_17_aarch64.manylinux2014_aarch64.whl (2.5 MB view details)

Uploaded Python 3manylinux: glibc 2.17+ ARM64

ryl-0.10.1-py3-none-macosx_11_0_arm64.whl (2.4 MB view details)

Uploaded Python 3macOS 11.0+ ARM64

File details

Details for the file ryl-0.10.1.tar.gz.

File metadata

  • Download URL: ryl-0.10.1.tar.gz
  • Upload date:
  • Size: 208.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.13

File hashes

Hashes for ryl-0.10.1.tar.gz
Algorithm Hash digest
SHA256 83c13c5573701c53e41db71c74c146659566372913c4e863849a122a47359d10
MD5 5fd30e73f028636e179a16ccf20de94c
BLAKE2b-256 fb0d6ab17bbbe0b2c1e5b1195bb591e8c6f7ffd38f33f2cb2e68b67c6d4a6e0a

See more details on using hashes here.

Provenance

The following attestation bundles were made for ryl-0.10.1.tar.gz:

Publisher: release.yml on owenlamont/ryl

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

File details

Details for the file ryl-0.10.1-py3-none-win_arm64.whl.

File metadata

  • Download URL: ryl-0.10.1-py3-none-win_arm64.whl
  • Upload date:
  • Size: 2.1 MB
  • Tags: Python 3, Windows ARM64
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.13

File hashes

Hashes for ryl-0.10.1-py3-none-win_arm64.whl
Algorithm Hash digest
SHA256 1b396a0693475dded12f77818cc6c5cd94243eedd672e651b23960a8fc6fafd7
MD5 8c25f0c99ac7d0f14b12245cada9e5e8
BLAKE2b-256 975e186fe3738a85d4a6787f220cc7c62814073baf2551be58d5f154d63051e3

See more details on using hashes here.

Provenance

The following attestation bundles were made for ryl-0.10.1-py3-none-win_arm64.whl:

Publisher: release.yml on owenlamont/ryl

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

File details

Details for the file ryl-0.10.1-py3-none-win_amd64.whl.

File metadata

  • Download URL: ryl-0.10.1-py3-none-win_amd64.whl
  • Upload date:
  • Size: 2.2 MB
  • Tags: Python 3, Windows x86-64
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.13

File hashes

Hashes for ryl-0.10.1-py3-none-win_amd64.whl
Algorithm Hash digest
SHA256 c477a6d670050404c3ba694b85f43eea326ef538ccb5bb36d7942a9ae52588a9
MD5 90865c7939763355ef545d6f3da29bbb
BLAKE2b-256 98f14819a6e8bb66d31465de034998a7c7db1e6a5b136da2f759a2e332247183

See more details on using hashes here.

Provenance

The following attestation bundles were made for ryl-0.10.1-py3-none-win_amd64.whl:

Publisher: release.yml on owenlamont/ryl

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

File details

Details for the file ryl-0.10.1-py3-none-musllinux_1_2_x86_64.whl.

File metadata

  • Download URL: ryl-0.10.1-py3-none-musllinux_1_2_x86_64.whl
  • Upload date:
  • Size: 2.7 MB
  • Tags: Python 3, musllinux: musl 1.2+ x86-64
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.13

File hashes

Hashes for ryl-0.10.1-py3-none-musllinux_1_2_x86_64.whl
Algorithm Hash digest
SHA256 cd3321c1338774eaaf17ce544317e788f236256a31ede5ce5ac02de3f3ee7b26
MD5 f57aa1e4b78ecb297c380a27b47c795e
BLAKE2b-256 1168130d8d9faadbcd26918abb0e8091153145c56dd4f03b3828a13a53335d43

See more details on using hashes here.

Provenance

The following attestation bundles were made for ryl-0.10.1-py3-none-musllinux_1_2_x86_64.whl:

Publisher: release.yml on owenlamont/ryl

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

File details

Details for the file ryl-0.10.1-py3-none-musllinux_1_2_aarch64.whl.

File metadata

File hashes

Hashes for ryl-0.10.1-py3-none-musllinux_1_2_aarch64.whl
Algorithm Hash digest
SHA256 19018f36a28eded33ab7e3a5fac9effd92331532259bcec7ed8e295ef26e6ab4
MD5 664c50876e1a8ea040afee7060bc1fab
BLAKE2b-256 a11d1a6347087a5f1da742c2406b64cb796885bcc781006a544036e279bff56d

See more details on using hashes here.

Provenance

The following attestation bundles were made for ryl-0.10.1-py3-none-musllinux_1_2_aarch64.whl:

Publisher: release.yml on owenlamont/ryl

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

File details

Details for the file ryl-0.10.1-py3-none-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.

File metadata

File hashes

Hashes for ryl-0.10.1-py3-none-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 a4e165e7e5157f7ae6a9d01e9534a55b59ec23f7db8d73b8a6d040ded486c28f
MD5 b7e8098a6a0fabf95208a9d246824df2
BLAKE2b-256 20e03a6e782926e20030c71c1937adb6319c8d15621dd344277a574d2f802920

See more details on using hashes here.

Provenance

The following attestation bundles were made for ryl-0.10.1-py3-none-manylinux_2_17_x86_64.manylinux2014_x86_64.whl:

Publisher: release.yml on owenlamont/ryl

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

File details

Details for the file ryl-0.10.1-py3-none-manylinux_2_17_s390x.manylinux2014_s390x.whl.

File metadata

File hashes

Hashes for ryl-0.10.1-py3-none-manylinux_2_17_s390x.manylinux2014_s390x.whl
Algorithm Hash digest
SHA256 fd6dd42766cb58d2d44b0afe3e13bfac6ad212da5e88960248280d5f0063cb16
MD5 3ad962e7b5fb7c37b6a58bb2f9a3bd7c
BLAKE2b-256 4c9ed3151c8418c66d8e09dc73199317f2c7672a950bb09d54b75315c26b3a54

See more details on using hashes here.

Provenance

The following attestation bundles were made for ryl-0.10.1-py3-none-manylinux_2_17_s390x.manylinux2014_s390x.whl:

Publisher: release.yml on owenlamont/ryl

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

File details

Details for the file ryl-0.10.1-py3-none-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl.

File metadata

File hashes

Hashes for ryl-0.10.1-py3-none-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl
Algorithm Hash digest
SHA256 a6518ab6554dfd744e5718a9af986f0389ca71eaa4338afc9f0b653d76e895d6
MD5 e9b3a50fc96a57ea2ac65f116be84a4c
BLAKE2b-256 e1e1f4a8ef40b5699e786134370c18c12d6670db322e793bb5dbce6285d59508

See more details on using hashes here.

Provenance

The following attestation bundles were made for ryl-0.10.1-py3-none-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl:

Publisher: release.yml on owenlamont/ryl

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

File details

Details for the file ryl-0.10.1-py3-none-manylinux_2_17_i686.manylinux2014_i686.whl.

File metadata

File hashes

Hashes for ryl-0.10.1-py3-none-manylinux_2_17_i686.manylinux2014_i686.whl
Algorithm Hash digest
SHA256 77b3df04702327026991187ebbec0e57ca4654c4b7392248506fc19d67f0d165
MD5 a397f73653b65cd047836774fc43f03f
BLAKE2b-256 1a58bded082f05b05f6738a16c52113d8c66075b9ba7d5329c756c257ec3b8e7

See more details on using hashes here.

Provenance

The following attestation bundles were made for ryl-0.10.1-py3-none-manylinux_2_17_i686.manylinux2014_i686.whl:

Publisher: release.yml on owenlamont/ryl

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

File details

Details for the file ryl-0.10.1-py3-none-manylinux_2_17_armv7l.manylinux2014_armv7l.whl.

File metadata

File hashes

Hashes for ryl-0.10.1-py3-none-manylinux_2_17_armv7l.manylinux2014_armv7l.whl
Algorithm Hash digest
SHA256 5f83dd7eb69d045344174d80f50a0d2efccd555b39b4390b4ca4a5b2c1a21c63
MD5 3b2d2e373f996c40ea53416a78894bcd
BLAKE2b-256 15dbf79e8f7f1c81da5b7c55d7ae1dc053344dd9f6241b52af81872c12329453

See more details on using hashes here.

Provenance

The following attestation bundles were made for ryl-0.10.1-py3-none-manylinux_2_17_armv7l.manylinux2014_armv7l.whl:

Publisher: release.yml on owenlamont/ryl

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

File details

Details for the file ryl-0.10.1-py3-none-manylinux_2_17_aarch64.manylinux2014_aarch64.whl.

File metadata

File hashes

Hashes for ryl-0.10.1-py3-none-manylinux_2_17_aarch64.manylinux2014_aarch64.whl
Algorithm Hash digest
SHA256 fb7771a5c1203f0b9b6e64885b999a4b02b287c7139234e18fa460090fcbadae
MD5 b4949f1aa5e2992bce59bbc9f844a31f
BLAKE2b-256 4dcfce65dfabe0974269888432beb942ea1510aada2cead490ad067e1676446c

See more details on using hashes here.

Provenance

The following attestation bundles were made for ryl-0.10.1-py3-none-manylinux_2_17_aarch64.manylinux2014_aarch64.whl:

Publisher: release.yml on owenlamont/ryl

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

File details

Details for the file ryl-0.10.1-py3-none-macosx_11_0_arm64.whl.

File metadata

  • Download URL: ryl-0.10.1-py3-none-macosx_11_0_arm64.whl
  • Upload date:
  • Size: 2.4 MB
  • Tags: Python 3, macOS 11.0+ ARM64
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.13

File hashes

Hashes for ryl-0.10.1-py3-none-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 5f739055615794f450a5d8981448b7bd8493ca5c51dc5a648abd0d85c7442b71
MD5 ae1b98359bd8d6ab4038e153fe146373
BLAKE2b-256 f682ce6203d696f8052061e75025020e0d97be34c2bff8ee2e7d889a9262484e

See more details on using hashes here.

Provenance

The following attestation bundles were made for ryl-0.10.1-py3-none-macosx_11_0_arm64.whl:

Publisher: release.yml on owenlamont/ryl

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

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