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.2.tar.gz (209.6 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.2-py3-none-win_arm64.whl (2.1 MB view details)

Uploaded Python 3Windows ARM64

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

Uploaded Python 3Windows x86-64

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

Uploaded Python 3musllinux: musl 1.2+ x86-64

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

Uploaded Python 3musllinux: musl 1.2+ ARM64

ryl-0.10.2-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.2-py3-none-manylinux_2_17_s390x.manylinux2014_s390x.whl (2.7 MB view details)

Uploaded Python 3manylinux: glibc 2.17+ s390x

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

Uploaded Python 3manylinux: glibc 2.17+ ppc64le

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

Uploaded Python 3manylinux: glibc 2.17+ i686

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

Uploaded Python 3manylinux: glibc 2.17+ ARMv7l

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

Uploaded Python 3manylinux: glibc 2.17+ ARM64

ryl-0.10.2-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.2.tar.gz.

File metadata

  • Download URL: ryl-0.10.2.tar.gz
  • Upload date:
  • Size: 209.6 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.2.tar.gz
Algorithm Hash digest
SHA256 44cb5291cc2ab27aa5dfa14cbf28fb1888b23820edea89b45843a1592183734a
MD5 5ff51545141e566d4e4b8e06d050d3f5
BLAKE2b-256 fcf255c918a2c6553262c9cf915bb47ebd40f2ae797d726842bfa3708bd2269b

See more details on using hashes here.

Provenance

The following attestation bundles were made for ryl-0.10.2.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.2-py3-none-win_arm64.whl.

File metadata

  • Download URL: ryl-0.10.2-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.2-py3-none-win_arm64.whl
Algorithm Hash digest
SHA256 9a807f5f7dbaac364f0693587a138e22b2f323d7353ad4d3a09eca4438c7f602
MD5 0dd1a4bf7be0de22a0d7531d76f73472
BLAKE2b-256 36a865a106dd60048e0e56b45330e6ddb6ca48c341fde42406e0378e9c7924b7

See more details on using hashes here.

Provenance

The following attestation bundles were made for ryl-0.10.2-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.2-py3-none-win_amd64.whl.

File metadata

  • Download URL: ryl-0.10.2-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.2-py3-none-win_amd64.whl
Algorithm Hash digest
SHA256 ca86ab41ae1526c2df247a9381af20efef948972c921d418f7863369bccb4790
MD5 4a0fd63a690c7cfc577b94200c6af384
BLAKE2b-256 e8e9c0932e4a6c7303831104d9b695ff83b7815470a6800a47721e12db50c853

See more details on using hashes here.

Provenance

The following attestation bundles were made for ryl-0.10.2-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.2-py3-none-musllinux_1_2_x86_64.whl.

File metadata

  • Download URL: ryl-0.10.2-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.2-py3-none-musllinux_1_2_x86_64.whl
Algorithm Hash digest
SHA256 f1588ff964ec432f865ad06bfbf5809949ffd250ef031bc4b54b6976b991dd91
MD5 56d9bd5c391a5cd2a53af845f2e472ab
BLAKE2b-256 5750082846ecf2d0e51d25f0890b730183347325b49bb578859ad2a7282cbf8b

See more details on using hashes here.

Provenance

The following attestation bundles were made for ryl-0.10.2-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.2-py3-none-musllinux_1_2_aarch64.whl.

File metadata

File hashes

Hashes for ryl-0.10.2-py3-none-musllinux_1_2_aarch64.whl
Algorithm Hash digest
SHA256 0495df3c2a1ea1a3e9b5a2d4714a0eae1c28d5b125d7279599039c1062eecf37
MD5 5345ae5e9aaeb45a828b06789a313f59
BLAKE2b-256 b092468f727e03ac535814b0670727e3a321b156aaa72dfb25653b5173855771

See more details on using hashes here.

Provenance

The following attestation bundles were made for ryl-0.10.2-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.2-py3-none-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.

File metadata

File hashes

Hashes for ryl-0.10.2-py3-none-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 c11620cdae78cff6c2c37d7e19b53f4cb36b1ad01a76262922876875953a3774
MD5 5dd680116cf1bac58b7171207182709c
BLAKE2b-256 4e0d5ed5457b3f70b96329131466532c11cfd1e9e137e45b4fe80381652ea798

See more details on using hashes here.

Provenance

The following attestation bundles were made for ryl-0.10.2-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.2-py3-none-manylinux_2_17_s390x.manylinux2014_s390x.whl.

File metadata

File hashes

Hashes for ryl-0.10.2-py3-none-manylinux_2_17_s390x.manylinux2014_s390x.whl
Algorithm Hash digest
SHA256 dae4d527612e9e3eb4976bedb317a2b7ce045d3657f0be57d7b23d8461c299ff
MD5 14205ccdbaf65bf311da37010111a5b5
BLAKE2b-256 006c00b176ef672032da9c527e50ce23c00448193b4aeb7cdcd4d5a7a07a36b5

See more details on using hashes here.

Provenance

The following attestation bundles were made for ryl-0.10.2-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.2-py3-none-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl.

File metadata

File hashes

Hashes for ryl-0.10.2-py3-none-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl
Algorithm Hash digest
SHA256 c4ab26a452007c90fe9a5a4570b6a9f779f81ebe51c6f941d5b210a44cf829f1
MD5 67ab77af625a8dc4ddefee92b774d2ea
BLAKE2b-256 7bc364b30f87c8ecac17b0ea817b0473dfb63326dfcf23a8bb87cdfe56b25794

See more details on using hashes here.

Provenance

The following attestation bundles were made for ryl-0.10.2-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.2-py3-none-manylinux_2_17_i686.manylinux2014_i686.whl.

File metadata

File hashes

Hashes for ryl-0.10.2-py3-none-manylinux_2_17_i686.manylinux2014_i686.whl
Algorithm Hash digest
SHA256 669f2289f18257866e85c68cf172f77c4c3ab8273fd493fc132e2e9ea8f98ba8
MD5 e475fee536f459fde2d2d833b70327b9
BLAKE2b-256 6b125167afc0b6979edff03b0165a08deb046486517b37c6d62c8d213a9a7475

See more details on using hashes here.

Provenance

The following attestation bundles were made for ryl-0.10.2-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.2-py3-none-manylinux_2_17_armv7l.manylinux2014_armv7l.whl.

File metadata

File hashes

Hashes for ryl-0.10.2-py3-none-manylinux_2_17_armv7l.manylinux2014_armv7l.whl
Algorithm Hash digest
SHA256 3952f3534e87a559759b899680e48db334cb88175222516121195b6d1b60dfbf
MD5 15c5856fefb63e9a8a055c1d2e6a19a4
BLAKE2b-256 b4a34b594a3741671abb78617ce2bda73442a3d0c8ca0ca89213d8948f80450a

See more details on using hashes here.

Provenance

The following attestation bundles were made for ryl-0.10.2-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.2-py3-none-manylinux_2_17_aarch64.manylinux2014_aarch64.whl.

File metadata

File hashes

Hashes for ryl-0.10.2-py3-none-manylinux_2_17_aarch64.manylinux2014_aarch64.whl
Algorithm Hash digest
SHA256 a1d74f8bf72838c21c76e9f7c0eea81a226717f0a4408542300866b2ec887bce
MD5 5ce4601a34161a5ac83c189508f2d7b7
BLAKE2b-256 c3d136649aab3874fd0b5a073fd2af99d355568a58a9f7444b825f4cb6b0f67b

See more details on using hashes here.

Provenance

The following attestation bundles were made for ryl-0.10.2-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.2-py3-none-macosx_11_0_arm64.whl.

File metadata

  • Download URL: ryl-0.10.2-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.2-py3-none-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 a957afb2d89b1f33b8ff00ec7e744d6f7fbc8d595fca21ff5d8373f1f27fc466
MD5 3e0b35d16148f234fdeea5e0424aedaa
BLAKE2b-256 ef0c5d33823c4ffac46eb0882b0bf484988d25c4ae512476952cb9e27b41b56a

See more details on using hashes here.

Provenance

The following attestation bundles were made for ryl-0.10.2-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