On this page
parse-toml
Prev: parse-yaml | Up: projects | Next: backpack-store
Rel: wispsy, Foundation, parse-yaml, parse-xml1
Ref: wispsy on GitHub
Tags: #public #wispsy #project #foundation #tier/standard
Role
Typed, bounded TOML 1.0 parser for Python 3.14+ (0.1.0, zero runtime deps)—backed by stdlib tomllib, preserving the original source alongside the parsed value (parse(), loads(), ParseOptions, and structured ParseError line/column/code diagnostics).
Install
python -m pip install parse-toml
Quickstart
from parse_toml import parse
document = parse('name = "Ada"\nactive = true\n')
assert document.value["name"] == "Ada"
assert document.to_toml() == 'name = "Ada"\nactive = true\n'
When to Reach for It
- Parsing TOML files (
pyproject.toml, workflow documents, or protocol profiles) with configurableParseOptionsresource limits and preserved source. - Reach for parse-yaml for YAML documents.
Gotchas & Pitfalls
- Read-only TOML 1.0 parser: Backed by stdlib
tomllib(>=3.14);document.to_toml()returns the preserved original source, not a round-trip comment-editing TOML writer. - Strict
ParseOptionsbounds: Large documents or deep table nesting raise structuredParseErrordiagnostics (with line, column, and code) when exceeding configured limits. - YAML/XML boundaries: Strictly TOML 1.0—reach for parse-yaml or parse-xml1 for other config formats.
Pairs With
- parse-yaml & parse-xml1 — Sibling bounded structured-data parsers.
- function-sequence & expose-protocol — Downstream consumers of TOML workflow and profile documents.
Metadata
type: project-card
slug: parse-toml
org: wispsy
repo: wispsy/parse-toml
package: parse-toml
import_name: parse_toml
version: 0.1.0
requires_python: ">=3.14"
layer: foundation
topic: wispsy-foundation
status: active
language: python
source_docs: README.md, docs/
Linked from
Related notes
- wiki/projects/backpack-store Linked here; links to this page; shared tags: #foundation, #project, #tier, #wispsy
- wiki/projects/parse-xml1 Linked here; links to this page; shared tags: #foundation, #project, #tier, #wispsy
- wiki/projects/parse-yaml Linked here; links to this page; shared tags: #foundation, #project, #tier, #wispsy
- wiki/stack/foundation Linked here; links to this page; shared tags: #foundation, #tier, #wispsy
- wiki/projects Linked here; links to this page; shared tags: #wispsy
- wiki/projects/expose-protocol Linked here; shared tags: #project, #tier, #wispsy
- wiki/projects/function-sequence Linked here; shared tags: #project, #tier, #wispsy
- wiki/choosing links to this page; shared tags: #tier, #wispsy
- wiki/compatibility links to this page; shared tags: #tier, #wispsy
- wiki/families links to this page; shared tags: #tier, #wispsy