bitwalker/toml-elixir
63.2
Adequate · 18 September 2026
2.6k
lines of production code
Elixir
primary language
1
measurement over time
What this system is
This system is a TOML parsing library for Elixir that decodes TOML documents into Elixir data structures. It supports custom value transformations to modify decoded data and enforces strict compliance with the TOML 1.0 specification, including robust error handling for invalid characters and UTF-8 sequences. The library includes benchmarking tools and comprehensive test coverage to ensure performance and correctness.
Removals
Removed unused application configuration file
The \config/config.exs\ file has been deleted from the project. This file contained only comments and no active configuration settings, so its removal has no impact on application behavior or runtime configuration.
config · high confidence
Behavioural changes
API rename from parse to decode and introduction of custom value transformations
The library's public API verbs have been renamed from 'parse' to 'decode' (e.g., \Toml.decode/2\, \Toml.decode\_file/2\) to better reflect the decoding process. A new \:transforms\ option allows users to provide custom transformation modules that modify decoded values depth-first, enabling automatic conversion of data types (such as IP strings to Erlang tuples) during the decoding phase. Additionally, the internal parsing logic has been moved from \lib/parser.ex\ to \lib/decoder.ex\, and the \Document\ struct now supports key conversion functions and transform pipelines.
lib · high confidence
API verb change from parse to decode and new value transformation support
The library's public API verbs have been renamed from 'parse' to 'decode' (e.g., \Toml.parse\ is now \Toml.decode\), aligning the terminology with the decoding process. Additionally, the library now supports custom value transformations via the \Toml.Transform\ behavior, allowing users to extend how specific values are converted during decoding. The README also reflects compliance with TOML spec version 1.0 and adds documentation for implementation-specific behaviors regarding infinity and NaN values.
(repo-wide) · high confidence
Improved TOML string lexing with stricter control character handling and type safety
The lexer now enforces stricter compliance with the TOML specification by rejecting invalid control characters (bytes 0-31 and 127) in single-quoted strings and multi-line literal strings, while allowing tabs in multi-line literals. It also correctly handles invalid UTF-8 byte sequences by returning an error instead of proceeding. Additionally, the string lexing module now includes explicit type specifications for better type safety, and uses \IO.chardata\_to\_string/1\ instead of \IO.iodata\_to\_binary/1\ for constructing final string binaries. Whitespace trimming logic around escaped newlines in quoted strings has also been refined.
lib/lexer · high confidence
Test coverage
Added benchmarking suite for TOML decoder and lexer; Expanded test coverage for TOML decoding, providers, and transforms; Updated test helpers to use new API and add JSON conversion support.
Dependencies
Upgrade to Elixir 1.9 and add development tooling
The project now requires Elixir 1.9 or later and introduces several new development dependencies: ExDoc for documentation generation, Dialyxir for static analysis, Benchee for benchmarking, and ExCoveralls for test coverage reporting. The Jason dependency has been expanded to include the :bench environment, and the application's extra applications list has been cleared. These changes support improved code quality checks, documentation, and performance testing workflows.
(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
Baseline
- First survey — no prior run to compare against. CAI 63.
Lenses
- Code Health 96
- Architecture 100
- Maturity 46
- Readiness 71
- Security 77
Changes since last survey
- 116 commits — 84 feature/other, 32 fixes
By area
- (root) — 53 commits
- lib/decoder.ex — 11 commits
- test/fixtures — 11 commits
- lib/provider.ex — 10 commits
- lib/builder.ex — 6 commits
- test/support — 5 commits
- lib/document.ex — 3 commits
- lib/lexer — 3 commits
- .github/workflows — 2 commits
- lib/error.ex — 2 commits
- lib/transform.ex — 2 commits
- test/provider_test.exs — 2 commits
- (repo) — 1 commit
- config/config.exs — 1 commit
- lib/lexer.ex — 1 commit
- lib/parser.ex — 1 commit
- test/decoder_test.exs — 1 commit
- test/toml_test_test.exs — 1 commit
Notable commits
- fix: Fix #10 - conversion of iodata to binaries
- fix: Fix #11 - validate :keys option, add error formatting for it
- fix: Fix #3 - Add using callback for Transform behaviour
- fix: Fix #9 - table redefinition in some cases has anomalous result
- fix: Fix bug with handling attempted key redefinition
- fix: Fix bugs in table construction
- fix: Fix clause in value which would improperly return leading zero error
- fix: Fix config provider
- fix: Fix dialyzer warning
- fix: Fix expected json for some tests, add many more tests, clean up existing test organization
- fix: Fix for edge case of table following table array of same name
- fix: Fix handful of edge cases
- fix: Fix handling of control chars in strings
- fix: Fix hex.pm badge
- fix: Fix missing clause in format_token
- fix: Fix newline escaping in lex_quoted to trim trailing whitespace after escape
- fix: Fix now incorrect assumption in test suite
- fix: Fix old references to parse
- fix: Fix provider test
- fix: Fix syntax error in example
- …and 96 more
Written by watchdog.canine.dev from the codebase's own history, inside the signed delivery this page is composed from.
Survey your own repository
bitwalker/toml-elixir 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 18 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 e32c89908205f4f99695796a268e91c44effe397 — the exact code this score is about.
- Scored under rubric-2026.09.15 — the same rubric and the same method as every other entry in this index.
- Measured by watchdog.canine.dev using codehealth-analyzer preprod-5d04157a340d.