strictyaml
Strict, typed YAML parser
Install
strictyaml on PyPI
pip
pip install strictyamluv
uv add strictyamlpoetry
poetry add strictyamlPackage facts
| License | MIT (permissive) |
| Python support | supports the current Python release (>=3.7.0) |
| Install friction | low — pure-Python wheel |
| Runtime dependencies | 1 — python-dateutil |
| Maintenance | aging — 1,252 days since the last release |
| Last repo commit | |
| First released | |
| Popularity | one of the top 1,000 most-downloaded packages on PyPI (30-day window, as of 2026-08-13) |
| Known vulnerabilities | none known (OSV.dev, checked 2026-08-13) |
Evidence: strictyaml-1.7.3-py3-none-any.whl
Keywords: yaml
About strictyaml
from the package's own PyPI description — quoted content, verbatim
StrictYAML
StrictYAML is a type-safe YAML parser that parses and validates a restricted subset of the YAML specification.
Priorities:
- Beautiful API
- Refusing to parse the ugly, hard to read and insecure features of YAML like the Norway problem.
- Strict validation of markup and straightforward type casting.
- Clear, readable exceptions with code snippets and line numbers.
- Acting as a near-drop in replacement for pyyaml, ruamel.yaml or poyo.
- Ability to read in YAML, make changes and write it out again with comments preserved.
- Not speed, currently.
Simple example:
# All about the character
name: Ford Prefect
age: 42
possessions:
- Towel
from strictyaml import load, Map, Str, Int, Seq, YAMLError
Default parse result:
```python >>> load(yaml_snippet) YAML({'name': 'Ford Prefect', 'age': '42', 'possessions':...
AI interpretation — verify before relying
AI-generated interpretation of the package facts above; every digit, version, license, or vulnerability id it cites is grounded in the facts already shown on this page
StrictYAML parses and validates a restricted, type-safe subset of YAML, rejecting unsafe features while preserving comments and line numbers for roundtrip editing.
Low friction: pure Python wheel with only python-dateutil as a runtime dependency. Maintenance is aging—last release was 2023-03-10 with no commits since 2025-05-23—but the repository remains active.
MIT license permits commercial and private use with minimal restrictions; attribution required but no copyleft obligations.
Usage
pip install strictyaml
from strictyaml import load, Map, Str, Int, Seq
schema = Map({"name": Str(), "age": Int(), "possessions": Seq(Str())})
person = load("name: Ford Prefect\nage: 42\npossessions:\n - Towel", schema)
print(person.data)
Requires Python >=3.7.0
Verdict: StrictYAML is a stable, permissively licensed YAML parser suited for configuration files where safety and schema validation matter more than speed. Aging maintenance (last release 2023-03-10) is acceptable for a mature library, but users should verify it meets their Python version and feature needs before adoption.
Needs verification
- Whether the 1252-day gap since last release reflects intentional stability or abandonment risk for future Python versions
- Performance characteristics relative to alternatives for large configuration files
- Compatibility with Python 3.12+ given the aging maintenance status
Similar packages
permissive · top 1,000 on PyPI
ruamel.yamlpermissive · top 1,000 on PyPI
tomlkitpermissive · top 1,000 on PyPI
ruamel.yaml.clibpermissive · top 1,000 on PyPI
humanfriendlypermissive · top 1,000 on PyPI
jiterpermissive · top 1,000 on PyPI
fastjsonschemapermissive · top 1,000 on PyPI
msgpackpermissive · top 1,000 on PyPI
wcwidthpermissive · top 1,000 on PyPI
tqdmcopyleft · top 100 on PyPI