Repository navigation
v0.11.2: A broken config fails loud
A focused patch that stops a broken openspec/config.yaml from masquerading as no config. When the file that declares your verification.layers can't be read or parsed, cospec now fails on the real cause instead of mislabeling a declared @<layer> row as unknown.
Fixed
-
A broken
openspec/config.yamlnow fails loud (#99 by @replygirl, fixes #98) — previously, a config that existed but couldn't be read (a permissions error, a directory in its place) or didn't parse as YAML was silently treated as absent. With layers declared, a@uatrow then failed withverification/layer-unknown … @uat is not a known layer, the hint told you to declare the layer the broken config already declared,status/listreportedarchiveReady: falsefor that same wrong reason, and stderr stayed empty.cospec,
doctor, and the upstream port now share one reader, so they classify a file the same way:-
A missing config is still no config.
-
A config that can't be read or parsed (including an unresolved YAML alias, which the parser throws as a plain
ReferenceError) now fails on the real cause. Every ledger gate —validate,apply,archive,sync-specs— refuses the change with a newverification/config-unreadableERROR naming the file and the cause, instead of a per-rowlayer-unknown.status/listreportarchiveReady: falsewith that single reason inverification.blockedReasons. -
Every read of a broken config prints OpenSpec's own line once per invocation:
Warning: could not parse openspec/config.yaml (EISDIR: illegal operation on a directory, read); ignoring it.A command that relays the binary's stderr (
apply) drops the binary's copy so it isn't printed twice. -
cospec doctornow reports an unreadable config as<file> could not be read (<code>)rather thandoes not parse as YAML. -
A bare change with no
.openspec.yamlstill falls back tospec-driven, now with the warning instead of silence.
A malformed-but-parseable declaration (e.g.
verification: uat,layersas a mapping, a bad entry) is still read leniently anddoctorstill warns about it. -
Full Changelog: v0.11.1...v0.11.2