Skip to content
CAI
Software that uses CAICheck a score

ron-rs/ron

70.4

Strong · 30 September 2026

9.5k

lines of production code

Rust

primary language

2

measurements over time

CAI band scale
CAI trend line
CAI lens gauges

What this system is

This system is the RON (Rusty Object Notation) library, a Rust crate for serializing and deserializing structured data. It provides core functionality for converting Rust types to and from the RON format, including support for runtime data representation via a \Value\ type and handling of byte strings. The library features configurable serialization and deserialization options, such as pretty-printing and recursion limits, and supports both standard and \no\_std\ environments.

Features

Introduce Value, Map, Number, and RawValue types for runtime data representation

This change introduces the core \Value\ enum and its supporting types (\Map\, \Number\, \RawValue\) in the \src/value\ module, providing a structured, runtime representation of RON data that can be manipulated and deserialized into Rust types. \Map\ offers a flexible key-value store that optionally preserves insertion order via the \indexmap\ feature, while \Number\ supports lossless storage of various integer and float primitives (including 128-bit integers when enabled) and is marked non-exhaustive to prevent breaking changes in user code. \RawValue\ allows capturing and manipulating raw RON strings without immediate deserialization, and the new \Value\ type implements Serde's \Deserializer\ to enable converting these runtime values back into strongly-typed Rust structs.

src/value · high confidence

New examples demonstrating RON v0.9+ byte string handling and file I/O

The examples directory now includes demonstrations of key RON v0.9+ features. The new \base64.rs\ example shows how to serialize and deserialize byte vectors using Rusty byte strings (the default since v0.9) or legacy base64-encoded strings, including a hybrid mode that accepts both formats. Additional examples (\decode.rs\, \decode\_file.rs\, \encode.rs\, \encode\_file.rs\, \file\_read\_write\_vec.rs\) illustrate modern serialization and deserialization patterns, including writing to \io::Writer\, handling \Vec\<T\>\ records in files, and using \PrettyConfig\ options like depth limits and compact formatting. The \transcode.rs\ example demonstrates converting RON data to JSON via the \Value\ type, while \example.ron\ provides a sample configuration file.

examples · high confidence

New serialization module with path-based metadata and raw value support

The \src/ser\ module has been restructured to introduce path-based field metadata serialization, allowing users to attach documentation comments to specific fields via \PrettyConfig.path\_meta\. The module now includes dedicated support for serializing \ron::value::RawValue\ (which outputs raw RON strings) and implements serialization for the \Value\ type. Additionally, the \PrettyConfig\ structure has been expanded with new options including \compact\_maps\, \compact\_structs\, \number\_suffixes\, and \compact\_ranges\ to control output formatting.

src/ser · high confidence

Architecture

Restructured deserialization module with dedicated ID and tag handlers

The deserialization logic in \src/de\ has been reorganized into a modular structure, introducing dedicated \id.rs\ and \tag.rs\ sub-modules to handle identifier and tagged-deserialization scenarios respectively. The main \mod.rs\ now coordinates these components and exposes convenience functions like \from\_reader\ (when the \std\ feature is enabled) and \from\_str\. This refactoring supports more precise error handling for identifiers and tags, while the existing test suite in \tests.rs\ and value deserialization logic in \value.rs\ remain integrated to ensure round-trip compatibility.

src/de · high confidence

Behavioural changes

Introduce RON 0.12.2 with no\_std support and explicit Options API

This release restructures the library to support \no\_std\ environments and introduces a new \Options\ struct that centralizes configuration for serialization and deserialization. Users can now explicitly enable extensions like \IMPLICIT\_SOME\ and set recursion limits via the \Options\ builder, rather than relying on global or implicit settings. The error handling is also refined with a new \SpannedError\ type that includes precise line/column spans for better debugging, and the \Extensions\ system is now backed by the \bitflags\ crate for more robust flag management.

src · high confidence

RON version 0.12.2 release with number range and string escape support

This release introduces support for parsing Rust-style string continuation escapes and fixes the round-tripping of compact ranges containing infinity or NaN values. It also adds support for parsing number ranges (e.g., \3..5\) and ignores \\#!\[type = "..."\]\ and \\#!\[schema = "..."\]\ attributes. Additionally, it fixes parsing of integer type suffixes for non-decimal numbers.

(repo-wide) · high confidence

Test coverage

Added fuzzer for RON string parsing; Expanded test coverage for RON serialization and deserialization features.

Dependencies

RON library updated to version 0.12.2 with dependency and MSRV changes

The RON crate has been updated to version 0.12.2, raising the Minimum Supported Rust Version (MSRV) to 1.64.0. Key dependency updates include upgrading \base64\ to 0.22 (now a dev-dependency for testing), \bitflags\ to 2.1, \indexmap\ to 2.0, and \serde\/\serde\_derive\ to 1.0.193. The library also introduces a new \integer128\ feature to support 128-bit integers and adds several new examples including \transcode\, \base64\, and \decode\_file\.

(dependencies) · high confidence

Written by watchdog.canine.dev from the codebase's own history, inside the signed delivery this page is composed from.

How this codebase got here

Score

  • CAI 68 → 70 (+2.0)
  • Rubric changed (rubric-2026.09.11 → rubric-2026.09.18) — scores are not directly comparable.

Lenses

  • Code Health 89 → 89 (-0.0)
  • Architecture 100 → 99 (-1.0)
  • Maturity 55 → 55 (+0.5)
  • Readiness 79 → 81 (+2.3)
  • Security 73 → 82 (+9.0)

Resolved (1)

  • Hotspot: src/parse.rs (src/parse.rs)

New (9)

  • Confusingly similar method names with unclear distinction. to_writer and to_io_writer appear to do the same thing (writing to a writer), as do to_writer_pretty and to_io_writer_pretty. The prefix io_ suggests a distinction, but the signatures are identical (writer: W), making the duplication unnecessary and confusing.
  • Dependency hygiene PARTLY measured — Cargo dependencies read, no committed lock to grade for currency
  • Documentation: no installation or build instructions (README.md)
  • Documentation: no usage examples (README.md)
  • Inconsistent naming pattern for deserialization constructors. The methods from_reader, from_str, and from_bytes exist alongside from_reader_seed, from_str_seed, and from_bytes_seed. The seed suffix is non-standard and unclear. It is not obvious why some methods require a 'seed' and others do not, or if 'seed' implies a different deserialization strategy. This breaks the consistency of the from_ naming convention.
  • Inverted test pyramid
  • Low cohesion: Options (LCOM4 8) (src/options.rs)
  • Redundant entry points for deserialization. The module-level functions de.from_str and de.from_bytes perform the exact same operation as Deserializer.from_str and Deserializer.from_bytes. This creates two different ways to achieve the same result, confusing users about which API to prefer.
  • Redundant entry points for serialization. The module-level functions ser.to_string and ser.to_string_pretty duplicate the functionality of Options.to_string and Options.to_string_pretty. Users can serialize via the Options struct or directly via the module, leading to inconsistent usage patterns.

Written by watchdog.canine.dev from the codebase's own history, inside the signed delivery this page is composed from.

Survey your own repository

ron-rs/ron was measured the same way every project in this corpus was: the same rubric, at a pinned commit, with the result published in full. Point a surveyor at a repository you know and see whether you agree with it.

About this page

  • The score is its most recent published measurement, taken on 30 September 2026 at a pinned commit. It is not a live figure and does not change until the project is measured again.
  • Measured at commit 7cf000afe4de4783786db1e94f9c14b1da382c26 — the exact code this score is about.
  • Scored under rubric-2026.09.18 — the same rubric and the same method as every other entry in this index.
  • Measured by watchdog.canine.dev using codehealth-analyzer preprod-cb25ca4feafa.