rosettify 3.1.0 → 3.2.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/commands/specs/add.d.ts +1 -1
- package/dist/commands/specs/add.d.ts.map +1 -1
- package/dist/commands/specs/add.js +39 -11
- package/dist/commands/specs/add.js.map +1 -1
- package/dist/commands/specs/core.d.ts +100 -22
- package/dist/commands/specs/core.d.ts.map +1 -1
- package/dist/commands/specs/core.js +173 -30
- package/dist/commands/specs/core.js.map +1 -1
- package/dist/commands/specs/errors.d.ts +13 -5
- package/dist/commands/specs/errors.d.ts.map +1 -1
- package/dist/commands/specs/errors.js +19 -7
- package/dist/commands/specs/errors.js.map +1 -1
- package/dist/commands/specs/field-guide.d.ts +3 -0
- package/dist/commands/specs/field-guide.d.ts.map +1 -0
- package/dist/commands/specs/field-guide.js +243 -0
- package/dist/commands/specs/field-guide.js.map +1 -0
- package/dist/commands/specs/help-content.d.ts +15 -0
- package/dist/commands/specs/help-content.d.ts.map +1 -1
- package/dist/commands/specs/help-content.js +99 -35
- package/dist/commands/specs/help-content.js.map +1 -1
- package/dist/commands/specs/index.d.ts.map +1 -1
- package/dist/commands/specs/index.js +9 -5
- package/dist/commands/specs/index.js.map +1 -1
- package/dist/commands/specs/info.d.ts.map +1 -1
- package/dist/commands/specs/info.js +1 -1
- package/dist/commands/specs/info.js.map +1 -1
- package/dist/commands/specs/markup-grammar.d.ts +56 -0
- package/dist/commands/specs/markup-grammar.d.ts.map +1 -0
- package/dist/commands/specs/markup-grammar.js +99 -0
- package/dist/commands/specs/markup-grammar.js.map +1 -0
- package/dist/commands/specs/migrate.d.ts +1 -1
- package/dist/commands/specs/migrate.d.ts.map +1 -1
- package/dist/commands/specs/migrate.js +36 -19
- package/dist/commands/specs/migrate.js.map +1 -1
- package/dist/commands/specs/output.d.ts +32 -11
- package/dist/commands/specs/output.d.ts.map +1 -1
- package/dist/commands/specs/output.js +2 -2
- package/dist/commands/specs/output.js.map +1 -1
- package/dist/commands/specs/purge.d.ts.map +1 -1
- package/dist/commands/specs/purge.js +8 -0
- package/dist/commands/specs/purge.js.map +1 -1
- package/dist/commands/specs/query-filter.d.ts +1 -1
- package/dist/commands/specs/query-filter.d.ts.map +1 -1
- package/dist/commands/specs/query-filter.js +30 -0
- package/dist/commands/specs/query-filter.js.map +1 -1
- package/dist/commands/specs/render.d.ts +4 -2
- package/dist/commands/specs/render.d.ts.map +1 -1
- package/dist/commands/specs/render.js +184 -18
- package/dist/commands/specs/render.js.map +1 -1
- package/dist/commands/specs/req-parser.d.ts +43 -42
- package/dist/commands/specs/req-parser.d.ts.map +1 -1
- package/dist/commands/specs/req-parser.js +225 -223
- package/dist/commands/specs/req-parser.js.map +1 -1
- package/dist/commands/specs/rubric.d.ts +35 -5
- package/dist/commands/specs/rubric.d.ts.map +1 -1
- package/dist/commands/specs/rubric.js +120 -28
- package/dist/commands/specs/rubric.js.map +1 -1
- package/dist/commands/specs/schemas.d.ts.map +1 -1
- package/dist/commands/specs/schemas.js +69 -32
- package/dist/commands/specs/schemas.js.map +1 -1
- package/dist/commands/specs/update.d.ts.map +1 -1
- package/dist/commands/specs/update.js +45 -20
- package/dist/commands/specs/update.js.map +1 -1
- package/dist/commands/specs/validate.d.ts.map +1 -1
- package/dist/commands/specs/validate.js +83 -25
- package/dist/commands/specs/validate.js.map +1 -1
- package/dist/commands/specs/write.d.ts +9 -4
- package/dist/commands/specs/write.d.ts.map +1 -1
- package/dist/commands/specs/write.js +23 -6
- package/dist/commands/specs/write.js.map +1 -1
- package/dist/frontends/cli.d.ts.map +1 -1
- package/dist/frontends/cli.js +20 -4
- package/dist/frontends/cli.js.map +1 -1
- package/dist/registry/types.d.ts +2 -0
- package/dist/registry/types.d.ts.map +1 -1
- package/dist/shared/constants.d.ts +2 -1
- package/dist/shared/constants.d.ts.map +1 -1
- package/dist/shared/constants.js +2 -1
- package/dist/shared/constants.js.map +1 -1
- package/dist/shared/logger.d.ts +2 -0
- package/dist/shared/logger.d.ts.map +1 -1
- package/dist/shared/logger.js +12 -3
- package/dist/shared/logger.js.map +1 -1
- package/package.json +5 -4
|
@@ -1,43 +1,36 @@
|
|
|
1
|
-
// Implements FR-SPECS-0025's
|
|
2
|
-
//
|
|
3
|
-
//
|
|
4
|
-
//
|
|
1
|
+
// Implements FR-SPECS-0025's reader for the canonical requirement-unit markup. Pure module — no
|
|
2
|
+
// IO, no envelopes, no error codes: always returns data plus findings, never throws, and never
|
|
3
|
+
// decides file-level outcomes (source_not_found/migrate_parse_error are migrate.ts's concern — it
|
|
4
|
+
// calls scanReqBlocks and treats a zero-length result as unparseable).
|
|
5
5
|
//
|
|
6
|
-
//
|
|
7
|
-
//
|
|
8
|
-
//
|
|
9
|
-
// carry. So every top-level `<tag>...</tag>` body is opaque text, located by its enclosing tag
|
|
10
|
-
// pair only, never re-parsed as markup. The one exception is `<acceptance>`, whose `<criteria>`
|
|
11
|
-
// children are extracted by the same shallow tag-pair technique one level down, since splitting
|
|
12
|
-
// Given/When/Then needs to know where each criterion starts.
|
|
6
|
+
// This reader is the exact inverse of render.ts's markup emitter. Neither holds an attribute name
|
|
7
|
+
// or an ordering decision of its own: both take the vocabulary from markup-grammar.ts. Attribute
|
|
8
|
+
// order and line breaks are never depended on here — attributes are read by name.
|
|
13
9
|
//
|
|
14
|
-
//
|
|
15
|
-
//
|
|
16
|
-
//
|
|
17
|
-
//
|
|
18
|
-
//
|
|
19
|
-
//
|
|
20
|
-
//
|
|
21
|
-
//
|
|
22
|
-
//
|
|
23
|
-
//
|
|
24
|
-
//
|
|
25
|
-
//
|
|
26
|
-
//
|
|
27
|
-
//
|
|
28
|
-
//
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
//
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
"changed", "verification", "acceptance", "depends", "related", "implementation",
|
|
35
|
-
"implementationNotes", "notes",
|
|
36
|
-
];
|
|
10
|
+
// CANONICAL FORM ONLY. Every single-value field is an attribute of the unit element; only prose
|
|
11
|
+
// and structured children are child elements; every acceptance criterion is a self-closing
|
|
12
|
+
// element carrying its pattern, its condition word, its responder, and its outcome as attributes.
|
|
13
|
+
// A unit in any other shape is reported with a stated reason and is NOT reconstructed by
|
|
14
|
+
// inference — a criterion recovered from prose would need its responder invented, and an invented
|
|
15
|
+
// responder in an approved requirement is worse than a unit a human must carry across by hand.
|
|
16
|
+
// The superseded shapes (single-value fields as child elements, Given/When/Then prose criteria,
|
|
17
|
+
// and the bracketed `[Status: X] [Additional Notes: Y]` implementation field) are deliberately
|
|
18
|
+
// not tolerated: reading them is what produced content nobody wrote.
|
|
19
|
+
//
|
|
20
|
+
// Deliberately hand-rolled, NOT a real XML parser: unit bodies embed ```code fences```, literal
|
|
21
|
+
// angle brackets, and other prose that a strict parser would choke on. Every element's body is
|
|
22
|
+
// located by its enclosing tag pair and then treated as opaque text, so anything bracket-shaped
|
|
23
|
+
// inside it is skipped wholesale rather than re-parsed. The one level of descent is
|
|
24
|
+
// `<acceptance>`, whose criterion children are located by the same shallow technique.
|
|
25
|
+
import { EARS_PATTERNS, assignCriterionIds, } from "./core.js";
|
|
26
|
+
import { ACCEPTANCE_ELEMENT, CANONICAL_ATTR_ORDER, CONDITION_ATTRS, CRITERION_ELEMENT, ELEMENT_FIELDS, EVIDENCE_ELEMENT, EVIDENCE_SEPARATOR, ID_LIST_SEPARATOR, MARKUP_TO_FIELD, ROOT_ELEMENT, } from "./markup-grammar.js";
|
|
27
|
+
// ---------------------------------------------------------------------------
|
|
28
|
+
// Low-level scanning
|
|
29
|
+
// ---------------------------------------------------------------------------
|
|
37
30
|
/** `s[i]` MUST be a quote char (`"` or `'`). Returns the index just past the matching close
|
|
38
31
|
* quote, or -1 if the string ends first (unterminated — the opening-tag scan treats this as a
|
|
39
|
-
* malformed
|
|
40
|
-
*
|
|
32
|
+
* malformed tag and stops). No backslash-escape handling: an attribute value never contains the
|
|
33
|
+
* quote character it is wrapped in, because the emitter escapes it. */
|
|
41
34
|
function scanAttrQuote(s, i) {
|
|
42
35
|
const quote = s[i];
|
|
43
36
|
let j = i + 1;
|
|
@@ -48,8 +41,8 @@ function scanAttrQuote(s, i) {
|
|
|
48
41
|
}
|
|
49
42
|
return -1;
|
|
50
43
|
}
|
|
51
|
-
/** Finds the first unquoted `>` at or after `from`, respecting quoted attribute values so a
|
|
52
|
-
*
|
|
44
|
+
/** Finds the first unquoted `>` at or after `from`, respecting quoted attribute values so a `>`
|
|
45
|
+
* inside e.g. `classification="a>b"` never ends the opening tag early. */
|
|
53
46
|
function findUnquotedGt(s, from) {
|
|
54
47
|
let i = from;
|
|
55
48
|
while (i < s.length) {
|
|
@@ -68,165 +61,123 @@ function findUnquotedGt(s, from) {
|
|
|
68
61
|
return -1;
|
|
69
62
|
}
|
|
70
63
|
const ATTR_RE = /([a-zA-Z_:][\w:.-]*)\s*=\s*(?:"([^"]*)"|'([^']*)')/g;
|
|
71
|
-
|
|
64
|
+
const TAG_NAME_RE = /^<([a-zA-Z_][\w:.-]*)/;
|
|
65
|
+
/** Inverse of the emitter's escaping. `&` is decoded LAST so that an escaped ampersand in the
|
|
66
|
+
* source (`&lt;`) decodes to the literal text `<` rather than to `<`. */
|
|
67
|
+
function unescapeMarkup(value) {
|
|
68
|
+
return value
|
|
69
|
+
.replace(/</g, "<")
|
|
70
|
+
.replace(/>/g, ">")
|
|
71
|
+
.replace(/"/g, '"')
|
|
72
|
+
.replace(/&/g, "&");
|
|
73
|
+
}
|
|
74
|
+
/** Parses `name="value"` (or `name='value'`) pairs out of a raw opening-tag string, decoding each
|
|
75
|
+
* value. */
|
|
72
76
|
export function extractAttrs(openTag) {
|
|
73
77
|
const attrs = {};
|
|
74
78
|
ATTR_RE.lastIndex = 0;
|
|
75
79
|
let m;
|
|
76
80
|
while ((m = ATTR_RE.exec(openTag)) !== null) {
|
|
77
|
-
attrs[m[1]] = m[2] !== undefined ? m[2] : m[3] ?? "";
|
|
81
|
+
attrs[m[1]] = unescapeMarkup(m[2] !== undefined ? m[2] : (m[3] ?? ""));
|
|
78
82
|
}
|
|
79
83
|
return attrs;
|
|
80
84
|
}
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
85
|
+
function escapeForRegex(literal) {
|
|
86
|
+
return literal.replace(/[.*+?^${}()|[\]\\]/g, "\\$&");
|
|
87
|
+
}
|
|
88
|
+
/**
|
|
89
|
+
* FR-SPECS-0025 — locates every child element of `body` by name, in document order. A paired
|
|
90
|
+
* element's body is consumed whole, so nothing bracket-shaped inside it is ever mistaken for a
|
|
91
|
+
* sibling element. An element with no closing tag is skipped and scanning continues past its
|
|
92
|
+
* opening tag (tolerant — one broken element never hides the rest).
|
|
93
|
+
*
|
|
94
|
+
* Names are collected for EVERY child element, not just the expected ones: a unit that carries a
|
|
95
|
+
* single-value field as a child element is only detectable if the unexpected names are seen.
|
|
96
|
+
*/
|
|
97
|
+
export function scanElements(body) {
|
|
98
|
+
const found = [];
|
|
99
|
+
let i = 0;
|
|
100
|
+
while (i < body.length) {
|
|
101
|
+
const lt = body.indexOf("<", i);
|
|
102
|
+
if (lt === -1)
|
|
103
|
+
break;
|
|
104
|
+
const nameMatch = TAG_NAME_RE.exec(body.slice(lt, lt + 64));
|
|
105
|
+
if (!nameMatch) {
|
|
106
|
+
i = lt + 1;
|
|
107
|
+
continue;
|
|
108
|
+
}
|
|
109
|
+
const name = nameMatch[1];
|
|
110
|
+
const tagEnd = findUnquotedGt(body, lt + 1);
|
|
111
|
+
if (tagEnd === -1)
|
|
112
|
+
break; // unterminated opening tag — nothing further is trustworthy
|
|
113
|
+
const openTag = body.slice(lt, tagEnd + 1);
|
|
114
|
+
if (openTag.endsWith("/>")) {
|
|
115
|
+
found.push({ name, openTag, selfClosing: true, text: "" });
|
|
116
|
+
i = tagEnd + 1;
|
|
117
|
+
continue;
|
|
118
|
+
}
|
|
119
|
+
const closeMatch = new RegExp(`</${escapeForRegex(name)}\\s*>`, "i").exec(body.slice(tagEnd + 1));
|
|
120
|
+
if (!closeMatch) {
|
|
121
|
+
i = tagEnd + 1;
|
|
122
|
+
continue;
|
|
123
|
+
}
|
|
124
|
+
const textStart = tagEnd + 1;
|
|
125
|
+
const textEnd = textStart + closeMatch.index;
|
|
126
|
+
found.push({ name, openTag, selfClosing: false, text: body.slice(textStart, textEnd).trim() });
|
|
127
|
+
i = textEnd + closeMatch[0].length;
|
|
91
128
|
}
|
|
92
|
-
return
|
|
129
|
+
return found;
|
|
93
130
|
}
|
|
94
131
|
/**
|
|
95
|
-
* FR-SPECS-0025 — scans `md` for
|
|
96
|
-
*
|
|
97
|
-
*
|
|
98
|
-
*
|
|
99
|
-
*
|
|
132
|
+
* FR-SPECS-0025 — scans `md` for requirement units. Units are never nested, so each is found by:
|
|
133
|
+
* locate the opening tag, scan to its unquoted `>`, then find the next closing tag — everything
|
|
134
|
+
* between is the body. Surrounding prose (headings, narrative) is ignored, which is what lets a
|
|
135
|
+
* rendered requirements document be read straight back. A malformed opening tag (unterminated
|
|
136
|
+
* attribute quote) or a missing closing tag stops that occurrence and moves on — one broken unit
|
|
137
|
+
* never prevents finding the rest of the file's valid units.
|
|
100
138
|
*/
|
|
101
139
|
export function scanReqBlocks(md) {
|
|
102
140
|
const blocks = [];
|
|
103
|
-
const openRe =
|
|
141
|
+
const openRe = new RegExp(`<${ROOT_ELEMENT}\\b`, "gi");
|
|
104
142
|
let match;
|
|
105
143
|
while ((match = openRe.exec(md)) !== null) {
|
|
106
144
|
const tagStart = match.index;
|
|
107
|
-
const tagEnd = findUnquotedGt(md, tagStart +
|
|
145
|
+
const tagEnd = findUnquotedGt(md, tagStart + ROOT_ELEMENT.length + 1);
|
|
108
146
|
if (tagEnd === -1) {
|
|
109
|
-
//
|
|
110
|
-
//
|
|
111
|
-
// untouched here, so it already sits just past this "<req" match (the engine advances it
|
|
112
|
-
// automatically on every exec()) — the next exec() call resumes strictly forward from
|
|
113
|
-
// there, guaranteeing progress (no infinite loop) while still finding any later
|
|
114
|
-
// well-formed <req> block in the rest of the document.
|
|
147
|
+
// Malformed opening tag: this occurrence is skipped, NOT the rest of the scan.
|
|
148
|
+
// openRe.lastIndex already sits just past this match, so progress is guaranteed.
|
|
115
149
|
continue;
|
|
116
150
|
}
|
|
117
151
|
const openTag = md.slice(tagStart, tagEnd + 1);
|
|
118
|
-
const closeMatch =
|
|
152
|
+
const closeMatch = new RegExp(`</${ROOT_ELEMENT}\\s*>`, "i").exec(md.slice(tagEnd + 1));
|
|
119
153
|
if (!closeMatch) {
|
|
120
154
|
openRe.lastIndex = tagEnd + 1;
|
|
121
|
-
continue; // unterminated
|
|
155
|
+
continue; // unterminated unit — skip it, keep scanning for later valid ones
|
|
122
156
|
}
|
|
123
157
|
const bodyStart = tagEnd + 1;
|
|
124
158
|
const bodyEnd = bodyStart + closeMatch.index;
|
|
125
159
|
const body = md.slice(bodyStart, bodyEnd);
|
|
126
|
-
const closeTagEnd = bodyEnd + closeMatch[0].length;
|
|
127
160
|
blocks.push({
|
|
128
161
|
attrs: extractAttrs(openTag),
|
|
129
|
-
|
|
162
|
+
elements: scanElements(body),
|
|
130
163
|
sourceLine: md.slice(0, tagStart).split("\n").length,
|
|
131
164
|
});
|
|
132
|
-
openRe.lastIndex =
|
|
165
|
+
openRe.lastIndex = bodyEnd + closeMatch[0].length;
|
|
133
166
|
}
|
|
134
167
|
return blocks;
|
|
135
168
|
}
|
|
136
|
-
|
|
137
|
-
// concatenated triples (see file header); each is located by its own "Given:" marker.
|
|
138
|
-
const GIVEN_RE = /\bGiven:\s*/gi;
|
|
139
|
-
const WHEN_RE = /\bWhen:\s*/i;
|
|
140
|
-
const THEN_RE = /\bThen:\s*/i;
|
|
141
|
-
/**
|
|
142
|
-
* FR-SPECS-0025 — splits `criteria` into one AcceptanceCriterion per "Given:" marker found. If
|
|
143
|
-
* no "Given:" marker exists anywhere, the whole text is unsplittable and is returned as
|
|
144
|
-
* `{verbatim}` for the caller to place into `then` + flag a warning (report-don't-drop).
|
|
145
|
-
* Within a "Given:"-led chunk, "When:" and "Then:" are each independently optional — real docs
|
|
146
|
-
* (e.g. rosettify/PLAN.md's FR-PLAN-0034) commonly write "Given: ... Then: ..." with no
|
|
147
|
-
* explicit When: clause — so every present marker is used; only a chunk with NEITHER When: nor
|
|
148
|
-
* Then: is truly unsplittable and degrades to `{given:"", when:"", then: <chunk verbatim>}`
|
|
149
|
-
* (mapToSpec's extractAcceptance detects that exact empty-given/when shape and warns).
|
|
150
|
-
*/
|
|
151
|
-
export function splitGwt(criteria) {
|
|
152
|
-
const text = criteria.trim();
|
|
153
|
-
if (!text)
|
|
154
|
-
return { verbatim: "" };
|
|
155
|
-
const givenPositions = [];
|
|
156
|
-
GIVEN_RE.lastIndex = 0;
|
|
157
|
-
let gm;
|
|
158
|
-
while ((gm = GIVEN_RE.exec(text)) !== null)
|
|
159
|
-
givenPositions.push(gm.index);
|
|
160
|
-
if (givenPositions.length === 0)
|
|
161
|
-
return { verbatim: text };
|
|
162
|
-
const chunks = givenPositions.map((start, i) => {
|
|
163
|
-
const end = i + 1 < givenPositions.length ? givenPositions[i + 1] : text.length;
|
|
164
|
-
return text.slice(start, end);
|
|
165
|
-
});
|
|
166
|
-
return chunks.map((chunk) => {
|
|
167
|
-
const trimmedChunk = chunk.trim();
|
|
168
|
-
const afterGiven = trimmedChunk.replace(/^Given:\s*/i, "");
|
|
169
|
-
const whenMatch = WHEN_RE.exec(afterGiven);
|
|
170
|
-
const thenBase = whenMatch ? afterGiven.slice(whenMatch.index + whenMatch[0].length) : afterGiven;
|
|
171
|
-
const thenMatch = THEN_RE.exec(thenBase);
|
|
172
|
-
if (!whenMatch && !thenMatch)
|
|
173
|
-
return { given: "", when: "", then: trimmedChunk };
|
|
174
|
-
if (whenMatch && thenMatch) {
|
|
175
|
-
return {
|
|
176
|
-
given: afterGiven.slice(0, whenMatch.index).trim(),
|
|
177
|
-
when: thenBase.slice(0, thenMatch.index).trim(),
|
|
178
|
-
then: thenBase.slice(thenMatch.index + thenMatch[0].length).trim(),
|
|
179
|
-
};
|
|
180
|
-
}
|
|
181
|
-
if (whenMatch)
|
|
182
|
-
return { given: afterGiven.slice(0, whenMatch.index).trim(), when: thenBase.trim(), then: "" };
|
|
183
|
-
return { given: thenBase.slice(0, thenMatch.index).trim(), when: "", then: thenBase.slice(thenMatch.index + thenMatch[0].length).trim() };
|
|
184
|
-
});
|
|
185
|
-
}
|
|
186
|
-
// normalizeImplementation — handles both the split-tag and legacy bracketed forms.
|
|
187
|
-
// Strict legacy form: "[Status: X] [Additional Notes: Y]" (Y may itself be empty).
|
|
188
|
-
const LEGACY_STRICT_RE = /^\[Status:\s*([^\]]+)\]\s*\[Additional Notes:\s*([\s\S]*)\]\s*$/i;
|
|
189
|
-
// Looser legacy form: "[Status: X] <trailing text>" — trailing text not itself bracketed.
|
|
190
|
-
const LEGACY_LOOSE_RE = /^\[Status:\s*([^\]]+)\]\s*([\s\S]*)$/i;
|
|
191
|
-
/**
|
|
192
|
-
* FR-SPECS-0025 — normalizes `tags.implementation`/`tags.implementationNotes` for any of the
|
|
193
|
-
* three real-world shapes: (1) modern split tags; (2) legacy strict bracketed "[Status: X]
|
|
194
|
-
* [Additional Notes: Y]"; (3) legacy loose bracketed "[Status: X] <free text>" with no second
|
|
195
|
-
* bracket (docs/requirements/CHANGES.md's own description of the pre-split format). Never
|
|
196
|
-
* throws and never validates the extracted status against IMPLS — that is migrate.ts's job
|
|
197
|
-
* over the assembled document; this module stays a pure, validation-free mapper.
|
|
198
|
-
*/
|
|
199
|
-
export function normalizeImplementation(tags) {
|
|
200
|
-
const raw = (tags["implementation"] ?? "").trim();
|
|
201
|
-
const strict = LEGACY_STRICT_RE.exec(raw);
|
|
202
|
-
if (strict) {
|
|
203
|
-
return { implementation: strict[1].trim(), implementation_notes: strict[2].trim() };
|
|
204
|
-
}
|
|
205
|
-
const loose = LEGACY_LOOSE_RE.exec(raw);
|
|
206
|
-
if (loose) {
|
|
207
|
-
const trailing = (loose[2] ?? "").trim();
|
|
208
|
-
if (trailing.length > 0) {
|
|
209
|
-
return { implementation: loose[1].trim(), implementation_notes: trailing };
|
|
210
|
-
}
|
|
211
|
-
// "[Status: X]" alone — fall back to a separate implementationNotes tag if present.
|
|
212
|
-
return { implementation: loose[1].trim(), implementation_notes: (tags["implementationNotes"] ?? "").trim() };
|
|
213
|
-
}
|
|
214
|
-
// Modern split-tag form (no brackets at all).
|
|
215
|
-
return { implementation: (raw || "NotStarted"), implementation_notes: (tags["implementationNotes"] ?? "").trim() };
|
|
216
|
-
}
|
|
217
|
-
// mapToSpec — assembles a Partial<Spec> + warnings from one RawReq.
|
|
218
|
-
function splitIdList(raw) {
|
|
169
|
+
function splitList(raw, separator) {
|
|
219
170
|
return raw
|
|
220
|
-
.split(
|
|
171
|
+
.split(separator)
|
|
221
172
|
.map((s) => s.trim())
|
|
222
173
|
.filter((s) => s.length > 0);
|
|
223
174
|
}
|
|
224
175
|
function warn(id, check, message) {
|
|
225
176
|
return { id: id || "(unknown)", check, severity: "warning", message };
|
|
226
177
|
}
|
|
227
|
-
/** Best-effort ISO8601 UTC normalization of
|
|
228
|
-
*
|
|
229
|
-
*
|
|
178
|
+
/** Best-effort ISO8601 UTC normalization of the `changed` value. The canonical markup carries a
|
|
179
|
+
* calendar date; a full timestamp is accepted too. Unparseable input is preserved verbatim
|
|
180
|
+
* (report-don't-drop) with a warning rather than discarded or defaulted. */
|
|
230
181
|
function normalizeChanged(raw, id, warnings) {
|
|
231
182
|
if (!raw)
|
|
232
183
|
return "";
|
|
@@ -241,85 +192,136 @@ function normalizeChanged(raw, id, warnings) {
|
|
|
241
192
|
warnings.push(warn(id, "migrate_unparseable_changed", "The changed timestamp could not be parsed and was preserved verbatim."));
|
|
242
193
|
return raw;
|
|
243
194
|
}
|
|
244
|
-
|
|
245
|
-
|
|
246
|
-
|
|
247
|
-
|
|
248
|
-
|
|
249
|
-
|
|
250
|
-
|
|
251
|
-
|
|
252
|
-
|
|
253
|
-
|
|
254
|
-
|
|
255
|
-
if (
|
|
256
|
-
|
|
257
|
-
|
|
258
|
-
const
|
|
259
|
-
|
|
260
|
-
|
|
261
|
-
|
|
262
|
-
|
|
263
|
-
|
|
264
|
-
|
|
265
|
-
|
|
266
|
-
|
|
267
|
-
|
|
268
|
-
|
|
269
|
-
|
|
270
|
-
|
|
271
|
-
|
|
272
|
-
|
|
195
|
+
const EARS_SET = new Set(EARS_PATTERNS);
|
|
196
|
+
const ATTRIBUTE_VOCABULARY = new Set(CANONICAL_ATTR_ORDER);
|
|
197
|
+
const ELEMENT_VOCABULARY = new Set(ELEMENT_FIELDS);
|
|
198
|
+
/** The one criterion reader. Returns the criterion, or the reason it is not canonical — never a
|
|
199
|
+
* partially invented one. */
|
|
200
|
+
function readCriterion(element) {
|
|
201
|
+
if (!element.selfClosing) {
|
|
202
|
+
return { reason: "carries a criterion written as prose rather than as a self-closing element with pattern attributes" };
|
|
203
|
+
}
|
|
204
|
+
const attrs = extractAttrs(element.openTag);
|
|
205
|
+
const ears = (attrs["ears"] ?? "").trim();
|
|
206
|
+
if (!EARS_SET.has(ears)) {
|
|
207
|
+
return { reason: "carries a criterion whose pattern is missing or is not one of the five recognized patterns" };
|
|
208
|
+
}
|
|
209
|
+
const system = (attrs["system"] ?? "").trim();
|
|
210
|
+
const shall = (attrs["shall"] ?? "").trim();
|
|
211
|
+
if (!system || !shall) {
|
|
212
|
+
return { reason: "carries a criterion that names no responder or no outcome" };
|
|
213
|
+
}
|
|
214
|
+
// FR-SPECS-0025 draws the canonical-shape line at fields-as-attributes and pattern-attribute
|
|
215
|
+
// criteria (checked above); which condition word a criterion carries relative to its declared
|
|
216
|
+
// `ears` is a content rule owned by FR-SPECS-0006 and enforced by validate.ts's
|
|
217
|
+
// checkCriterionEars/checkSingleConditionWord — this reader does not gate on it. Every attribute
|
|
218
|
+
// here is explicit, so carrying a present-but-mismatched (or absent) condition word across is not
|
|
219
|
+
// inference; it is imported as-is for validate to flag.
|
|
220
|
+
const criterion = {
|
|
221
|
+
id: (attrs["id"] ?? "").trim(),
|
|
222
|
+
ears: ears,
|
|
223
|
+
system,
|
|
224
|
+
shall,
|
|
225
|
+
};
|
|
226
|
+
for (const word of CONDITION_ATTRS) {
|
|
227
|
+
const value = (attrs[word] ?? "").trim();
|
|
228
|
+
if (value)
|
|
229
|
+
criterion[word] = value;
|
|
273
230
|
}
|
|
274
|
-
return
|
|
231
|
+
return { criterion };
|
|
275
232
|
}
|
|
276
233
|
/**
|
|
277
|
-
* FR-SPECS-0025 —
|
|
278
|
-
*
|
|
279
|
-
*
|
|
280
|
-
*
|
|
281
|
-
*
|
|
282
|
-
*
|
|
234
|
+
* FR-SPECS-0025 — reads one scanned unit into a Partial<Spec>. Never throws. A unit that is not in
|
|
235
|
+
* the canonical shape carries a `skip` reason instead of being repaired: fields found as child
|
|
236
|
+
* elements, or a criterion written as prose, both mean the unit was authored against a shape this
|
|
237
|
+
* reader does not read, and guessing at it is what would invent content.
|
|
238
|
+
*
|
|
239
|
+
* status/approved_by/changed/implementation are read as-is (not stripped the way add/update's
|
|
240
|
+
* stripGuarded would) — an import carries pre-existing historical state, not a fresh user-authored
|
|
241
|
+
* item.
|
|
283
242
|
*/
|
|
284
243
|
export function mapToSpec(raw) {
|
|
285
244
|
const warnings = [];
|
|
286
|
-
|
|
287
|
-
const
|
|
245
|
+
// Attribute names fold onto spec field names once, here; nothing below knows a markup name.
|
|
246
|
+
const fields = {};
|
|
247
|
+
for (const [markupName, value] of Object.entries(raw.attrs)) {
|
|
248
|
+
fields[MARKUP_TO_FIELD[markupName] ?? markupName] = value;
|
|
249
|
+
}
|
|
250
|
+
const id = (fields["id"] ?? "").trim();
|
|
288
251
|
if (!id) {
|
|
289
|
-
warnings.
|
|
290
|
-
|
|
291
|
-
|
|
292
|
-
|
|
293
|
-
|
|
294
|
-
|
|
252
|
+
return { spec: {}, warnings, skip: `The unit at line ${raw.sourceLine} carries no id and was skipped.` };
|
|
253
|
+
}
|
|
254
|
+
const asElements = raw.elements.filter((e) => ATTRIBUTE_VOCABULARY.has(e.name)).map((e) => e.name);
|
|
255
|
+
if (asElements.length > 0) {
|
|
256
|
+
return {
|
|
257
|
+
spec: {},
|
|
258
|
+
warnings,
|
|
259
|
+
skip: `The unit ${id} carries single-value fields as child elements (${asElements.join(", ")}) instead of attributes and was skipped rather than reconstructed by inference.`,
|
|
260
|
+
};
|
|
261
|
+
}
|
|
262
|
+
const elementText = {};
|
|
263
|
+
for (const element of raw.elements) {
|
|
264
|
+
if (!ELEMENT_VOCABULARY.has(element.name))
|
|
265
|
+
continue;
|
|
266
|
+
const field = MARKUP_TO_FIELD[element.name] ?? element.name;
|
|
267
|
+
if (elementText[field] === undefined)
|
|
268
|
+
elementText[field] = unescapeMarkup(element.text);
|
|
269
|
+
}
|
|
270
|
+
const acceptanceElement = raw.elements.find((e) => e.name.toLowerCase() === ACCEPTANCE_ELEMENT);
|
|
271
|
+
let acceptance = [];
|
|
272
|
+
if (acceptanceElement) {
|
|
273
|
+
const children = scanElements(acceptanceElement.text).filter((e) => e.name.toLowerCase() === CRITERION_ELEMENT);
|
|
274
|
+
if (children.length === 0 && acceptanceElement.text.trim().length > 0) {
|
|
275
|
+
return {
|
|
276
|
+
spec: {},
|
|
277
|
+
warnings,
|
|
278
|
+
skip: `The unit ${id} carries a criterion written as prose rather than as pattern attributes and was skipped rather than reconstructed by inference.`,
|
|
279
|
+
};
|
|
280
|
+
}
|
|
281
|
+
for (const child of children) {
|
|
282
|
+
const read = readCriterion(child);
|
|
283
|
+
if ("reason" in read) {
|
|
284
|
+
return {
|
|
285
|
+
spec: {},
|
|
286
|
+
warnings,
|
|
287
|
+
skip: `The unit ${id} ${read.reason} and was skipped rather than reconstructed by inference.`,
|
|
288
|
+
};
|
|
289
|
+
}
|
|
290
|
+
acceptance.push(read.criterion);
|
|
291
|
+
}
|
|
292
|
+
// An omitted criterion id is filled by the same rule the write path uses; a supplied one is
|
|
293
|
+
// never renumbered. This assigns an identifier, it never invents content.
|
|
294
|
+
acceptance = assignCriterionIds(id, acceptance);
|
|
295
295
|
}
|
|
296
|
-
const spec = {
|
|
297
|
-
|
|
298
|
-
|
|
299
|
-
|
|
300
|
-
|
|
301
|
-
|
|
296
|
+
const spec = {
|
|
297
|
+
id,
|
|
298
|
+
type: (fields["type"] ?? "").trim(),
|
|
299
|
+
level: ((fields["level"] ?? "").trim() || "System"),
|
|
300
|
+
subsystem: (fields["subsystem"] ?? "").trim(),
|
|
301
|
+
component: (fields["component"] ?? "").trim(),
|
|
302
|
+
title: elementText["title"] ?? "",
|
|
303
|
+
statement: elementText["statement"] ?? "",
|
|
304
|
+
rationale: elementText["rationale"] ?? "",
|
|
305
|
+
evidence: splitList(elementText[MARKUP_TO_FIELD[EVIDENCE_ELEMENT] ?? EVIDENCE_ELEMENT] ?? "", EVIDENCE_SEPARATOR),
|
|
306
|
+
source: (fields["source"] ?? "").trim(),
|
|
307
|
+
priority: (fields["priority"] ?? "").trim(),
|
|
308
|
+
status: ((fields["status"] ?? "").trim() || "Draft"),
|
|
309
|
+
approved_by: (fields["approved_by"] ?? "").trim(),
|
|
310
|
+
changed: normalizeChanged((fields["changed"] ?? "").trim(), id, warnings),
|
|
311
|
+
verification: (fields["verification"] ?? "").trim(),
|
|
312
|
+
acceptance,
|
|
313
|
+
depends_on: splitList(fields["depends_on"] ?? "", ID_LIST_SEPARATOR),
|
|
314
|
+
related: splitList(fields["related"] ?? "", ID_LIST_SEPARATOR),
|
|
315
|
+
implementation: ((fields["implementation"] ?? "").trim() || "NotStarted"),
|
|
316
|
+
implementation_notes: elementText["implementation_notes"] ?? "",
|
|
317
|
+
notes: elementText["notes"] ?? "",
|
|
318
|
+
};
|
|
319
|
+
const ticketId = (fields["ticket_id"] ?? "").trim();
|
|
302
320
|
if (ticketId)
|
|
303
321
|
spec.ticket_id = ticketId;
|
|
304
|
-
const classification = (
|
|
322
|
+
const classification = (fields["classification"] ?? "").trim();
|
|
305
323
|
if (classification)
|
|
306
324
|
spec.classification = classification;
|
|
307
|
-
spec.title = (tags["title"] ?? "").trim();
|
|
308
|
-
spec.statement = (tags["statement"] ?? "").trim();
|
|
309
|
-
spec.rationale = (tags["rationale"] ?? "").trim();
|
|
310
|
-
spec.source = (tags["source"] ?? "");
|
|
311
|
-
spec.priority = (tags["priority"] ?? "");
|
|
312
|
-
spec.status = (tags["status"] ?? "Draft");
|
|
313
|
-
spec.approved_by = (tags["approved_by"] ?? "").trim();
|
|
314
|
-
spec.changed = normalizeChanged((tags["changed"] ?? "").trim(), id, warnings);
|
|
315
|
-
spec.verification = (tags["verification"] ?? "");
|
|
316
|
-
spec.notes = (tags["notes"] ?? "").trim();
|
|
317
|
-
spec.depends_on = splitIdList(tags["depends"] ?? "");
|
|
318
|
-
spec.related = splitIdList(tags["related"] ?? "");
|
|
319
|
-
const { implementation, implementation_notes } = normalizeImplementation(tags);
|
|
320
|
-
spec.implementation = implementation;
|
|
321
|
-
spec.implementation_notes = implementation_notes;
|
|
322
|
-
spec.acceptance = extractAcceptance(tags["acceptance"] ?? "", id, warnings);
|
|
323
325
|
return { spec, warnings };
|
|
324
326
|
}
|
|
325
327
|
//# sourceMappingURL=req-parser.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"req-parser.js","sourceRoot":"","sources":["../../../src/commands/specs/req-parser.ts"],"names":[],"mappings":"AAAA,+FAA+F;AAC/F,4FAA4F;AAC5F,gGAAgG;AAChG,oFAAoF;AACpF,EAAE;AACF,6FAA6F;AAC7F,wFAAwF;AACxF,0FAA0F;AAC1F,+FAA+F;AAC/F,gGAAgG;AAChG,gGAAgG;AAChG,6DAA6D;AAC7D,EAAE;AACF,8DAA8D;AAC9D,qFAAqF;AACrF,yFAAyF;AACzF,gGAAgG;AAChG,gFAAgF;AAChF,oEAAoE;AACpE,gFAAgF;AAChF,oFAAoF;AACpF,sEAAsE;AACtE,WAAW;AACX,8FAA8F;AAC9F,0FAA0F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,CAAC,CAAC;IACrD,IAAI,CAAC,OAAO,GAAG,WAAW,CAAC,IAAI,CAAC,SAAS,CAAC,IAAI,EAAE,CAAC,CAAC;IAElD,MAAM,EAAE,cAAc,EAAE,oBAAoB,EAAE,GAAG,uBAAuB,CAAC,IAAI,CAAC,CAAC;IAC/E,IAAI,CAAC,cAAc,GAAG,cAAc,CAAC;IACrC,IAAI,CAAC,oBAAoB,GAAG,oBAAoB,CAAC;IAEjD,IAAI,CAAC,UAAU,GAAG,iBAAiB,CAAC,IAAI,CAAC,YAAY,CAAC,IAAI,EAAE,EAAE,EAAE,EAAE,QAAQ,CAAC,CAAC;IAE5E,OAAO,EAAE,IAAI,EAAE,QAAQ,EAAE,CAAC;AAC5B,CAAC"}
|
|
1
|
+
{"version":3,"file":"req-parser.js","sourceRoot":"","sources":["../../../src/commands/specs/req-parser.ts"],"names":[],"mappings":"AAAA,gGAAgG;AAChG,+FAA+F;AAC/F,kGAAkG;AAClG,uEAAuE;AACvE,EAAE;AACF,kGAAkG;AAClG,iGAAiG;AACjG,kFAAkF;AAClF,EAAE;AACF,gGAAgG;AAChG,2FAA2F;AAC3F,kGAAkG;AAClG,yFAAyF;AACzF,kGAAkG;AAClG,+FAA+F;AAC/F,gGAAgG;AAChG,+FAA+F;AAC/F,qEAAqE;AACrE,EAAE;AACF,gGAAgG;AAChG,+FAA+F;AAC/F,gGAAgG;AAChG,oFAAoF;AACpF,sFAAsF;AAEtF,OAAO,EAWL,aAAa,EACb,kBAAkB,GACnB,MAAM,WAAW,CAAC;AAEnB,OAAO,EACL,kBAAkB,EAClB,oBAAoB,EACpB,eAAe,EACf,iBAAiB,EACjB,cAAc,EACd,gBAAgB,EAChB,kBAAkB,EAClB,iBAAiB,EACjB,eAAe,EACf,YAAY,GACb,MAAM,qBAAqB,CAAC;AAgB7B,8EAA8E;AAC9E,qBAAqB;AACrB,8EAA8E;AAE9E;;;uEAGuE;AACvE,SAAS,aAAa,CAAC,CAAS,EAAE,CAAS;IACzC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