Repository navigation
Description
Summary
src/lib/ac-parser.ts requires a colon attached to the AC identifier. All four patterns in AC_PATTERNS demand it:
/^-\s*\[[x\s]\]\s*\*\*([A-Za-z]+-?\d+):\*\*\s*(.+)$/gim // **AC-1:** Desc
/^-\s*\[[x\s]\]\s*\*\*([A-Za-z]\d+):\*\*\s*(.+)$/gim // **B2:** Desc
/^-\s*\[[x\s]\]\s*\*\*([A-Za-z]+-?\d+):\s*(.+?)\*\*\s*(.*)$/gim // **AC-1: Desc**
/^-\s*\[[x\s]\]\s*([A-Za-z]+-?\d+):\s*(.+)$/gim // AC-1: DescSo a very common authoring style — bold identifier, no colon — matches nothing:
- [ ] **AC-1** After assembling the combined state, reinstall dependencies…
- [ ] **AC-2** With deps reinstalled, a combined state reports test/build passed…extractAcceptanceCriteria() returns { items: [], summary: { total: 0, … } }.
Why this matters
It fails silently. There is no warning, no error, no "0 ACs parsed — did you mean…". Downstream:
.sequant/state.jsonrecords zero acceptance criteria for the issue/qahas nothing to verify against and its AC coverage table is empty- The
/specAC linter reports nothing, because there is nothing to lint
Real-world evidence
Hit on #803. Its five ACs were authored as - [ ] **AC-1** … and parsed as zero items. Caught only because /spec happened to run the parser and print the count; the issue body was normalized to **AC-1:** by hand to unblock state tracking. Any run that did not eyeball that number would have proceeded with an empty AC set and a /qa pass that verified nothing.
Proposed fix
Add two patterns for the bold-without-colon form:
- [ ] **AC-1** Description- [ ] **B2** Description
Scope deliberately limited to the bold variants. A bare - [ ] AC1 something without bold or colon is genuinely ambiguous against ordinary checklist prose, and widening that far risks false positives; bold is a strong enough signal that the token is an identifier.
Acceptance Criteria
- AC-1:
parseAcceptanceCriteriaextracts- [ ] **AC-1** Description(bold ID, no colon) with idAC-1and the correct description. - AC-2: The same holds for the no-hyphen form
- [ ] **B2** Descriptionand for checked boxes- [x] **AC-1** Description. - AC-3: All four existing colon-bearing formats continue to parse unchanged — no regression in the existing ac-parser test suite.
- AC-4: A bold token that is not an identifier (e.g.
- [ ] **Note** something) is still not extracted as an AC. - AC-5: Unit tests cover each new format plus the fix(merge-check): combined-branch-test runs npm test/build without reinstalling deps after a lockfile change → false BLOCKED #803 issue body verbatim as a fixture.
Notes
Found while running /fullsolve 803. Not fixed there — different module, and folding it into the merge-check PR would make that change incoherent.
Activity
fix(#808): parse bold AC markers that have no colon (#809)