mirror of
https://github.com/Fission-AI/OpenSpec.git
synced 2026-09-14 20:16:53 +08:00
1.5 KiB
1.5 KiB
ADDED Requirements
Requirement: Scope-Aware Change Validation
The validator SHALL validate only artifacts that exist for a change, avoiding errors for proposal-only or tooling-only changes.
Scenario: Proposal-only change
- WHEN a change contains
proposal.mdbut has nospecs/directory or contains no*/spec.mdfiles - THEN validate the proposal (Why/What sections)
- AND do not require or validate spec deltas
Scenario: Delta validation when specs exist
- WHEN a change contains one or more
specs/<capability>/spec.mdfiles - THEN validate delta-formatted specs with existing rules (SHALL/MUST, scenarios, duplicates, conflicts)
MODIFIED Requirements
Requirement: Validation SHALL provide actionable remediation steps
Validation output SHALL include specific guidance to fix each error, including expected structure, example headers, and suggested commands to verify fixes.
Scenario: No deltas found in change
- WHEN validating a change that contains
specs/with one or more*/spec.mdfiles but the parser finds zero deltas - THEN show error "No deltas found" with guidance:
- Ensure
openspec/changes/{id}/specs/has.mdfiles that include delta headers - Use delta headers:
## ADDED Requirements,## MODIFIED Requirements,## REMOVED Requirements,## RENAMED Requirements - Each requirement must include at least one
#### Scenario:block - Try:
openspec change show {id} --json --deltas-onlyto inspect parsed deltas
- Ensure