Files
OpenSpec/docs-lab/reference/configuration
88692b3bb4 fix(change-metadata): warn on unrecognized .openspec.yaml keys (#1925)
* fix(change-metadata): warn on unrecognized .openspec.yaml keys

Unknown keys such as skip_design were stripped with no signal, so status
still demanded design and validate --strict exited 0. Warn on the shared
status/validate/archive read path without rejecting the file.

Closes #1920

AI-assisted (Grok)

* fix(change-metadata): sanitize unknown keys before they are printed

A quoted YAML key can carry a terminal control sequence, and the warning
printed it as it was written. The listed keys now go through
sanitizeInline, which also flattens C1 controls from now on.

Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>

* test(change-metadata): cover sanitized archive warnings

* fix(change-metadata): keep warnings safe and structured

* fix(change-metadata): label key names as untrusted

* test(change-metadata): keep known keys in step with the schema

CHANGE_METADATA_KNOWN_KEYS is a hand-kept copy of ChangeMetadataSchema's
keys. A key added to the schema but not the list would warn on, and fail
validate --strict for, every change that uses it. Pin the two together.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

---------

Co-authored-by: Claude Fable 5.1 <noreply@anthropic.com>
Co-authored-by: Clay Good <hi@claygood.com>
2026-09-29 18:25:42 +00:00
..