Files
OpenSpec/test
Clay GoodandClaude Opus 5.5 760584ba9a fix(validate): fail --strict on requirements over the length limit (#2020)
* fix(validate): fail --strict on requirements over the length limit

A requirement description over 500 characters was an INFO finding, so
`openspec validate --all --strict` still exited 0 and CI could not hold
the limit. It is now a WARNING: normal validation and archive still pass,
while strict mode fails, the same split the SHALL/MUST keyword warning
already uses. The specs instruction and its docs page say so.

Closes #1976

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

* fix(validate): check ADDED requirement length and document splitting

With the length finding now failing --strict, a change could still add an
overlong requirement and pass `validate <change> --strict`; CI only went red
after archive merged it into the main spec. ADDED requirements now get the
same warning, using the shared body reader so the limit matches the main
spec exactly. MODIFIED is left alone, since its text is the existing
requirement the instruction says to keep whole.

The specs instruction (and its docs-lab page) now says how to split an
existing long requirement in a dedicated change: keep the MODIFIED header and
every scenario, cut the description to one behavior, and add each removed
behavior as its own ADDED requirement. Verified end to end: the split change
validates strict, archives, and the main spec then passes --strict.

Closes the rest of #1976.

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

---------

Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-01 20:42:19 +00:00
..