@boyingliu01/xp-gate 0.38.12 → 0.38.14

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.
Files changed (32) hide show
  1. package/adapters/gate-13-compiler-strictness.sh +22 -7
  2. package/gate-13-compiler-strictness.sh +22 -7
  3. package/hooks/gate-13-compiler-strictness.sh +22 -7
  4. package/hooks/gate-entries/gate-11-entry.sh +4 -0
  5. package/hooks/gate-entries/gate-12-entry.sh +7 -1
  6. package/hooks/gate-entries/gate-13-entry.sh +9 -0
  7. package/hooks/gate-entries/gate-5-entry.sh +91 -4
  8. package/hooks/gate-entries/gate-6-entry.sh +6 -0
  9. package/hooks/gate-entries/gate-9-entry.sh +4 -0
  10. package/lib/__tests__/baseline-unevaluated.test.js +142 -0
  11. package/lib/baseline.js +83 -8
  12. package/lib/mattpocock-license-verdict.json +1 -1
  13. package/package.json +1 -1
  14. package/plugins/claude-code/.claude-plugin/plugin.json +1 -1
  15. package/plugins/claude-code/skills/delphi-review/AGENTS.md +1 -1
  16. package/plugins/claude-code/skills/sprint-flow/AGENTS.md +1 -1
  17. package/plugins/claude-code/skills/test-specification-alignment/AGENTS.md +1 -1
  18. package/plugins/dsh/package.json +1 -1
  19. package/plugins/dsh/skills/delphi-review/AGENTS.md +1 -1
  20. package/plugins/dsh/skills/sprint-flow/AGENTS.md +1 -1
  21. package/plugins/dsh/skills/test-specification-alignment/AGENTS.md +1 -1
  22. package/plugins/opencode/package.json +1 -1
  23. package/plugins/opencode/skills/delphi-review/AGENTS.md +1 -1
  24. package/plugins/opencode/skills/sprint-flow/AGENTS.md +1 -1
  25. package/plugins/opencode/skills/test-specification-alignment/AGENTS.md +1 -1
  26. package/plugins/qoder/plugin.json +1 -1
  27. package/plugins/qoder/skills/delphi-review/AGENTS.md +1 -1
  28. package/plugins/qoder/skills/sprint-flow/AGENTS.md +1 -1
  29. package/plugins/qoder/skills/test-specification-alignment/AGENTS.md +1 -1
  30. package/skills/delphi-review/AGENTS.md +1 -1
  31. package/skills/sprint-flow/AGENTS.md +1 -1
  32. package/skills/test-specification-alignment/AGENTS.md +1 -1
@@ -1077,6 +1077,28 @@ gate13_run_cpp_analysis() {
1077
1077
  return "$GATE13_WARN"
1078
1078
  fi
1079
1079
 
1080
+ # INPUT SHORTCIRCUIT FIRST. This block used to sit ~30 lines below, after the
1081
+ # toolchain had already been selected, cross-compilation probed, flags compiled
1082
+ # and the compiler version queried. Measured on a repo with no staged C/C++
1083
+ # (the normal case for a TypeScript project), that order spent 1954 ms per
1084
+ # commit before discovering there was nothing to compile:
1085
+ #
1086
+ # select_cxx 192 + is_cross_compiling 501 + cpp_flags 112
1087
+ # + probe_flags 752 + compiler_id 397 = 1954 ms
1088
+ # gate13_classify_changed (the actual question) = 273 ms, asked last
1089
+ #
1090
+ # The project's rule is the reverse -- ask "is there anything here to check?"
1091
+ # from the change set before asking "is the tool installed?". The Java and C#
1092
+ # arms already do this; only this arm was inverted. Output changes as a result:
1093
+ # on an empty change set the compiler/budget banner is no longer printed, which
1094
+ # is desired -- it described a toolchain that was never used.
1095
+ local classified
1096
+ classified=$(gate13_classify_changed)
1097
+ if [ -z "$classified" ]; then
1098
+ echo " ℹ️ No staged C/C++ source files — nothing to compile"
1099
+ return "$GATE13_PASS"
1100
+ fi
1101
+
1080
1102
  budget=$(gate13_timeout_budget)
1081
1103
  cxx=$(gate13_select_cxx)
1082
1104
  local sel_rc=$?
@@ -1103,13 +1125,6 @@ gate13_run_cpp_analysis() {
1103
1125
  echo "compiler: ${cxx} ($(gate13_compiler_id "$cxx"))"
1104
1126
  echo "strictness: ${tier} | flags: ${flags} | budget: ${budget}s"
1105
1127
 
1106
- local classified
1107
- classified=$(gate13_classify_changed)
1108
- if [ -z "$classified" ]; then
1109
- echo " ℹ️ No staged C/C++ source files — nothing to compile"
1110
- return "$GATE13_PASS"
1111
- fi
1112
-
1113
1128
  if ! gate13_baseline_exists; then
1114
1129
  echo " ⚠️ baseline missing — run 'xp-gate compiler-baseline create' to enable enforcement on modified files"
1115
1130
  echo " (new files are still -Werror; modified files are report-only until then)"
@@ -1077,6 +1077,28 @@ gate13_run_cpp_analysis() {
1077
1077
  return "$GATE13_WARN"
1078
1078
  fi
1079
1079
 
1080
+ # INPUT SHORTCIRCUIT FIRST. This block used to sit ~30 lines below, after the
1081
+ # toolchain had already been selected, cross-compilation probed, flags compiled
1082
+ # and the compiler version queried. Measured on a repo with no staged C/C++
1083
+ # (the normal case for a TypeScript project), that order spent 1954 ms per
1084
+ # commit before discovering there was nothing to compile:
1085
+ #
1086
+ # select_cxx 192 + is_cross_compiling 501 + cpp_flags 112
1087
+ # + probe_flags 752 + compiler_id 397 = 1954 ms
1088
+ # gate13_classify_changed (the actual question) = 273 ms, asked last
1089
+ #
1090
+ # The project's rule is the reverse -- ask "is there anything here to check?"
1091
+ # from the change set before asking "is the tool installed?". The Java and C#
1092
+ # arms already do this; only this arm was inverted. Output changes as a result:
1093
+ # on an empty change set the compiler/budget banner is no longer printed, which
1094
+ # is desired -- it described a toolchain that was never used.
1095
+ local classified
1096
+ classified=$(gate13_classify_changed)
1097
+ if [ -z "$classified" ]; then
1098
+ echo " ℹ️ No staged C/C++ source files — nothing to compile"
1099
+ return "$GATE13_PASS"
1100
+ fi
1101
+
1080
1102
  budget=$(gate13_timeout_budget)
1081
1103
  cxx=$(gate13_select_cxx)
1082
1104
  local sel_rc=$?
@@ -1103,13 +1125,6 @@ gate13_run_cpp_analysis() {
1103
1125
  echo "compiler: ${cxx} ($(gate13_compiler_id "$cxx"))"
1104
1126
  echo "strictness: ${tier} | flags: ${flags} | budget: ${budget}s"
1105
1127
 
1106
- local classified
1107
- classified=$(gate13_classify_changed)
1108
- if [ -z "$classified" ]; then
1109
- echo " ℹ️ No staged C/C++ source files — nothing to compile"
1110
- return "$GATE13_PASS"
1111
- fi
1112
-
1113
1128
  if ! gate13_baseline_exists; then
1114
1129
  echo " ⚠️ baseline missing — run 'xp-gate compiler-baseline create' to enable enforcement on modified files"
1115
1130
  echo " (new files are still -Werror; modified files are report-only until then)"
@@ -1077,6 +1077,28 @@ gate13_run_cpp_analysis() {
1077
1077
  return "$GATE13_WARN"
1078
1078
  fi
1079
1079
 
1080
+ # INPUT SHORTCIRCUIT FIRST. This block used to sit ~30 lines below, after the
1081
+ # toolchain had already been selected, cross-compilation probed, flags compiled
1082
+ # and the compiler version queried. Measured on a repo with no staged C/C++
1083
+ # (the normal case for a TypeScript project), that order spent 1954 ms per
1084
+ # commit before discovering there was nothing to compile:
1085
+ #
1086
+ # select_cxx 192 + is_cross_compiling 501 + cpp_flags 112
1087
+ # + probe_flags 752 + compiler_id 397 = 1954 ms
1088
+ # gate13_classify_changed (the actual question) = 273 ms, asked last
1089
+ #
1090
+ # The project's rule is the reverse -- ask "is there anything here to check?"
1091
+ # from the change set before asking "is the tool installed?". The Java and C#
1092
+ # arms already do this; only this arm was inverted. Output changes as a result:
1093
+ # on an empty change set the compiler/budget banner is no longer printed, which
1094
+ # is desired -- it described a toolchain that was never used.
1095
+ local classified
1096
+ classified=$(gate13_classify_changed)
1097
+ if [ -z "$classified" ]; then
1098
+ echo " ℹ️ No staged C/C++ source files — nothing to compile"
1099
+ return "$GATE13_PASS"
1100
+ fi
1101
+
1080
1102
  budget=$(gate13_timeout_budget)
1081
1103
  cxx=$(gate13_select_cxx)
1082
1104
  local sel_rc=$?
@@ -1103,13 +1125,6 @@ gate13_run_cpp_analysis() {
1103
1125
  echo "compiler: ${cxx} ($(gate13_compiler_id "$cxx"))"
1104
1126
  echo "strictness: ${tier} | flags: ${flags} | budget: ${budget}s"
1105
1127
 
1106
- local classified
1107
- classified=$(gate13_classify_changed)
1108
- if [ -z "$classified" ]; then
1109
- echo " ℹ️ No staged C/C++ source files — nothing to compile"
1110
- return "$GATE13_PASS"
1111
- fi
1112
-
1113
1128
  if ! gate13_baseline_exists; then
1114
1129
  echo " ⚠️ baseline missing — run 'xp-gate compiler-baseline create' to enable enforcement on modified files"
1115
1130
  echo " (new files are still -Werror; modified files are report-only until then)"
@@ -27,9 +27,13 @@
27
27
  # here, and why sub-shell exits are deliberately left as `exit`.
28
28
  gate_11_run() {
29
29
  if ! gate_enabled 11; then
30
+ # Recorded, not merely printed: this arm set the status and returned with no
31
+ # journal line, so wherever XP_GATE_ONLY_GATE selects a subset, "deselected on
32
+ # purpose" and "not part of this chain" were identical to every audit consumer.
30
33
  echo "⏭️ SKIPPED - Gate 11: Sprint flow (not selected by XP_GATE_ONLY_GATE)"
31
34
  GATE_11_STATUS="SKIP"
32
35
  GATE_11_DETAIL="not_selected"
36
+ record_gate_audit "gate-11" "sprint-flow" "$GATE_11_STATUS" "0" "$(gate_start_ms)"
33
37
  return 0
34
38
  fi
35
39
 
@@ -28,12 +28,18 @@
28
28
  # here, and why sub-shell exits are deliberately left as `exit`.
29
29
  gate_12_run() {
30
30
  if ! gate_enabled 12; then
31
- echo "⏭️ SKIPPED - Gate 12: File hygiene (not selected by XP_GATE_ONLY_GATE)"
32
31
  # No GATE_12_DETAIL here (removed with #806 G12a): pre-commit's blocking-exit
33
32
  # journal reads GATE_<id>_DETAIL, but only on a blocking exit, and Gate 12 is
34
33
  # non-blocking -- so a detail variable for this gate is write-only. Gate 0/1
35
34
  # populate one legitimately because they CAN block.
35
+ #
36
+ # The audit line, by contrast, is exactly what #806 G12a says must not be
37
+ # omitted -- and this arm still omitted it: the status was set and the function
38
+ # returned, leaving no journal line. The sibling "script not found" arm below
39
+ # does record, so the two skip paths disagreed with each other.
40
+ echo "⏭️ SKIPPED - Gate 12: File hygiene (not selected by XP_GATE_ONLY_GATE)"
36
41
  GATE_12_STATUS="SKIP"
42
+ record_gate_audit "gate-12" "file-hygiene" "$GATE_12_STATUS" "0" "$(gate_start_ms)"
37
43
  return 0
38
44
  fi
39
45
 
@@ -529,10 +529,15 @@ gate_13_run() {
529
529
  # XP_GATE_COMPILER_STRICTNESS=strict|balanced|warn-only,
530
530
  # XP_GATE_COMPILER_ANALYZER=1 (gcc -fanalyzer, C only, opt-in).
531
531
  # Design: docs/plans/2026-10-26-gate-13-compiler-strictness-design.md
532
+ # This gate has THREE skip paths and all three were silent: deselect, kill switch
533
+ # and missing-script. Only the analysis path recorded. Recorded: "a gate that
534
+ # cannot run must set the status AND write an audit line" -- otherwise a skip is
535
+ # indistinguishable from a gate the chain does not contain.
532
536
  if ! gate_enabled 13; then
533
537
  echo "⏭️ SKIPPED - Gate 13: Compiler strictness (not selected by XP_GATE_ONLY_GATE)"
534
538
  GATE_13_STATUS="SKIP"
535
539
  GATE_13_DETAIL="not_selected"
540
+ record_gate_audit "gate-13" "compiler-strictness" "$GATE_13_STATUS" "0" "$(gate_start_ms)"
536
541
  return 0
537
542
  fi
538
543
 
@@ -540,6 +545,8 @@ GATE_13_STATUS="SKIP"
540
545
  if [ "${XP_GATE_DISABLE_13:-}" = "1" ]; then
541
546
  echo "⏭️ SKIPPED - Gate 13: Compiler Strictness (XP_GATE_DISABLE_13=1)"
542
547
  GATE_13_STATUS="SKIP"
548
+ GATE_13_DETAIL="kill_switch"
549
+ record_gate_audit "gate-13" "compiler-strictness" "$GATE_13_STATUS" "0" "$(gate_start_ms)"
543
550
  elif [ -f "$GATE_DIR/gate-13-compiler-strictness.sh" ] || [ -f "$(git rev-parse --show-toplevel 2>/dev/null)/githooks/gate-13-compiler-strictness.sh" ]; then
544
551
  echo "⚙️ Gate 13: Compiler Strictness Check..."
545
552
  GATE13_START=$(gate_start_ms)
@@ -599,6 +606,8 @@ elif [ -f "$GATE_DIR/gate-13-compiler-strictness.sh" ] || [ -f "$(git rev-parse
599
606
  else
600
607
  echo "⏭️ SKIPPED - Gate 13: Compiler Strictness (gate-13-compiler-strictness.sh not found)"
601
608
  GATE_13_STATUS="SKIP"
609
+ GATE_13_DETAIL="script_missing"
610
+ record_gate_audit "gate-13" "compiler-strictness" "$GATE_13_STATUS" "0" "$(gate_start_ms)"
602
611
  fi
603
612
  echo ""
604
613
  # ============================================================================
@@ -17,6 +17,64 @@
17
17
  # on - there is no copy left in the hook.
18
18
  # ============================================================================
19
19
 
20
+ # ============================================================================
21
+ # Is the coverage report on disk evidence for THIS commit?
22
+ #
23
+ # TOP-LEVEL on purpose, like generate_quality_report(): it is a predicate about a
24
+ # file, not part of the gate's control flow, and keeping it out of gate_5_run is
25
+ # what lets a test exercise it without triggering a full test run.
26
+ #
27
+ # The gate previously asked this question three different ways and answered it
28
+ # inconsistently. #821 fixed the EVIDENCE check to ask the git index:
29
+ #
30
+ # git cat-file -e ":coverage/coverage-summary.json"
31
+ #
32
+ # but the three sites that READ the report still asked the working directory with
33
+ # `[ -f ... ]`. Those are different questions:
34
+ #
35
+ # - coverage/ is gitignored, so a report produced by a local `--coverage` run
36
+ # is never in the index. Replacing `-f` with the index test outright would
37
+ # discard real local measurements -- which is why the `-f` sites survived.
38
+ # - a leftover report from an earlier run is also absent from the index, and
39
+ # `-f` accepts it just as readily.
40
+ #
41
+ # Reproduced 2026-11-18: a commit staging only hook shell sources was blocked by
42
+ # BLOCKED - TypeScript coverage 1% below 78% threshold
43
+ # reading a five-hour-old partial report (574/45329 lines). The comment at the
44
+ # evidence check records the same artifact family blocking a commit on
45
+ # 2026-11-16, so this is a recurrence, not a one-off.
46
+ #
47
+ # Neither question is the right one. The right one is "was this report produced
48
+ # by THIS run?", which the gate can answer because it stamps GATE_5_START before
49
+ # running the tests. Staged evidence (#601) still wins outright: the commit
50
+ # carries it deliberately, so its mtime is not an objection.
51
+ #
52
+ # Returns 0 when the report may be read, non-zero when it must be ignored.
53
+ _gate5_coverage_usable() {
54
+ if [ "${GATE_5_COVERAGE_EVIDENCE:-false}" = "true" ]; then
55
+ return 0
56
+ fi
57
+ local start="${GATE_5_START:-}"
58
+ # No stamp means the gate is not mid-run; nothing can be attributed to it.
59
+ case "$start" in
60
+ ''|*[!0-9]*) return 1 ;;
61
+ esac
62
+ local f mtime
63
+ for f in coverage/coverage-summary.json coverage/coverage-final.json; do
64
+ [ -f "$f" ] || continue
65
+ # GNU stat first, BSD stat second: the hooks run on both.
66
+ mtime=$(stat -c %Y "$f" 2>/dev/null || stat -f %m "$f" 2>/dev/null) || continue
67
+ case "$mtime" in
68
+ ''|*[!0-9]*) continue ;;
69
+ esac
70
+ # stat reports whole seconds, the stamp is milliseconds.
71
+ if [ $(( mtime * 1000 )) -ge "$start" ]; then
72
+ return 0
73
+ fi
74
+ done
75
+ return 1
76
+ }
77
+
20
78
  # ============================================================================
21
79
  # Gate body. `return` is used instead of `exit` so the driver decides to
22
80
  # stop: see scripts/wrap-gate-entries.cjs for why the two are equivalent
@@ -75,7 +133,19 @@ else
75
133
  if [ -n "$STAGED_TEST_FILES" ]; then
76
134
  while IFS= read -r _tf; do
77
135
  [ -n "$_tf" ] || continue
78
- _tf_content=$(git show ":$tf" 2>/dev/null) || _tf_content=$(cat "$_tf" 2>/dev/null || true)
136
+ # `git show ":<path>"` reads the STAGED blob, which is what the commit
137
+ # will contain. The path variable here was `$tf` -- never assigned in this
138
+ # scope -- so the command was always `git show ":"`, which git rejects
139
+ # with "ambiguous argument", and every file fell through to the working
140
+ # tree copy. Measured: the fallback ran for 100% of files, so this gate
141
+ # has only ever inspected the working tree.
142
+ #
143
+ # That is the wrong direction for a commit gate: the user controls the
144
+ # working tree AND the index independently, so "clean in the index, marker
145
+ # still in the working copy" bypassed the focus check, and the reverse
146
+ # ("marker only in the index") was read as a false positive against a
147
+ # file the commit did not contain.
148
+ _tf_content=$(git show ":$_tf" 2>/dev/null) || _tf_content=$(cat "$_tf" 2>/dev/null || true)
79
149
  [ -n "$_tf_content" ] || continue
80
150
 
81
151
  # --- focus markers: BLOCK ---
@@ -989,9 +1059,17 @@ else
989
1059
  # real unusable shape) and a staged 42% BOTH passed, because the
990
1060
  # threshold comparison below never ran. "No evidence" and "evidence
991
1061
  # says 42%" must not take the same branch.
992
- if [ -f "coverage/coverage-summary.json" ] || [ -f "coverage/coverage-final.json" ]; then
1062
+ if { [ -f "coverage/coverage-summary.json" ] || [ -f "coverage/coverage-final.json" ]; } \
1063
+ && _gate5_coverage_usable; then
993
1064
  echo "TypeScript coverage collected during test run."
994
1065
  COV_EXIT=$((COV_EXIT || 0))
1066
+ elif [ -f "coverage/coverage-summary.json" ] || [ -f "coverage/coverage-final.json" ]; then
1067
+ # Present but produced by a different run: saying "collected during
1068
+ # test run" here is what made a five-hour-old report block a commit
1069
+ # with a percentage that described neither this commit nor this tree.
1070
+ echo "ℹ️ Coverage report on disk predates this run — ignored as stale."
1071
+ echo " Run 'npx vitest run --coverage' to measure this tree."
1072
+ COV_EXIT=$((COV_EXIT || 0))
995
1073
  elif [ "${TESTS_SKIPPED:-false}" = "true" ]; then
996
1074
  echo "ℹ️ No TypeScript tests were selected — no TS coverage to evaluate."
997
1075
  COV_EXIT=$((COV_EXIT || 0))
@@ -1214,7 +1292,7 @@ else
1214
1292
  # "no test/source files changed" was wrong, and it read as a pass. That is
1215
1293
  # the fail-open shape this whole issue exists to remove, sitting one branch
1216
1294
  # below a sibling that had already been fixed for it.
1217
- if [ -f "coverage/coverage-summary.json" ]; then
1295
+ if [ -f "coverage/coverage-summary.json" ] && _gate5_coverage_usable; then
1218
1296
  # #594: reject NaN at the SOURCE, not after the fact. Math.round() does
1219
1297
  # not fail on a non-numeric input -- it returns NaN and console.log prints
1220
1298
  # "NaN" -- so istanbul's "Unknown" (a file with no executable lines) sailed
@@ -1314,6 +1392,15 @@ else
1314
1392
  fi
1315
1393
  fi
1316
1394
  else
1395
+ # This arm is now reached for two different inputs: no report at all, and
1396
+ # a report too old to describe this run. Name the second one before the
1397
+ # #570/#823 decision, which stays exactly as it was -- "no measurement
1398
+ # was produced" still blocks unless nothing was selected. Without this
1399
+ # line an operator reads "not found" while the file is plainly there.
1400
+ if [ -f "coverage/coverage-summary.json" ] && ! _gate5_coverage_usable; then
1401
+ echo "ℹ️ Coverage report on disk predates this run — ignored as stale."
1402
+ echo " Run 'npx vitest run --coverage' to measure this tree."
1403
+ fi
1317
1404
  # #570: the report file is absent, so nothing was measured. Warning and
1318
1405
  # continuing made "delete coverage/coverage-summary.json" an effective way
1319
1406
  # to switch this gate off.
@@ -1648,7 +1735,7 @@ else
1648
1735
  # Default: attempt to parse coverage from common formats regardless of language
1649
1736
  COVERAGE_ENFORCED=true
1650
1737
  COVERAGE_PERCENT=""
1651
- if [ -f "coverage/coverage-summary.json" ]; then
1738
+ if [ -f "coverage/coverage-summary.json" ] && _gate5_coverage_usable; then
1652
1739
  COVERAGE_PERCENT=$(node -e "
1653
1740
  try {
1654
1741
  const fs = require('fs');
@@ -25,9 +25,15 @@
25
25
  # here, and why sub-shell exits are deliberately left as `exit`.
26
26
  gate_6_run() {
27
27
  if ! gate_enabled 6; then
28
+ # Recorded, not merely printed: this arm set the status and returned with no
29
+ # journal line, so wherever XP_GATE_ONLY_GATE selects a subset, "deselected on
30
+ # purpose" and "not part of this chain" were identical to every audit consumer.
31
+ # The stamp is taken in the arm itself so the normal path's measured duration is
32
+ # untouched -- a deselected gate genuinely does no work.
28
33
  echo "⏭️ SKIPPED - Gate 6: Architecture & tech debt (not selected by XP_GATE_ONLY_GATE)"
29
34
  GATE_6_STATUS="SKIP"
30
35
  GATE_6_DETAIL="not_selected"
36
+ record_gate_audit "gate-6" "architecture-boy-scout" "$GATE_6_STATUS" "0" "$(gate_start_ms)"
31
37
  return 0
32
38
  fi
33
39
 
@@ -31,9 +31,13 @@ gate_9_run() {
31
31
  # removes. Verdict codes (mirror of the java.sh G1 contract):
32
32
  # 0=PASS 2=BLOCK(compile failed) 3=SKIP+WARN(reason printed)
33
33
  if ! gate_enabled 9; then
34
+ # Recorded, not merely printed: this arm set the status and returned with no
35
+ # journal line, so wherever XP_GATE_ONLY_GATE selects a subset, "deselected on
36
+ # purpose" and "not part of this chain" were identical to every audit consumer.
34
37
  echo "⏭️ SKIPPED - Gate 9: Build integrity (not selected by XP_GATE_ONLY_GATE)"
35
38
  GATE_9_STATUS="SKIP"
36
39
  GATE_9_DETAIL="not_selected"
40
+ record_gate_audit "gate-9" "build-integrity" "$GATE_9_STATUS" "0" "$(gate_start_ms)"
37
41
  return 0
38
42
  fi
39
43
 
@@ -0,0 +1,142 @@
1
+ /**
2
+ * @test REQ-152 Baseline CLI handler
3
+ * @intent `xp-gate baseline create` rebuilt the baseline from an empty object and
4
+ * then wrote it unconditionally. Files whose linter could not RUN were
5
+ * therefore recorded as "no entry", which the gate reads as "no known
6
+ * issues" -- and because the write always happened, a run in which every
7
+ * tool failed replaced a good baseline with `{}`.
8
+ *
9
+ * That is not hypothetical in this repo. It presents as
10
+ * BLOCKED - 50 NEW shellcheck issue(s) (baseline: 0, current: 50)
11
+ * on a tree where nothing had changed, and the two states that must never
12
+ * be confused are exactly the ones being confused:
13
+ * "the linter found nothing"
14
+ * "the linter never answered"
15
+ * The second was being written to disk as the first.
16
+ *
17
+ * The repair keeps the ratchet honest in both directions, which is why
18
+ * these tests come in a pair: a fix that preserved every old entry would
19
+ * pass the failure test while making the baseline unable to ever shrink.
20
+ * @covers AC-BASELINE-05 AC-BASELINE-06
21
+ */
22
+ const path = require('path');
23
+ const fs = require('fs');
24
+ const os = require('os');
25
+
26
+ const { execFileSync } = require('child_process');
27
+
28
+ const { createBaseline } = require('../baseline.js');
29
+
30
+ describe('baseline rebuild — an unevaluated file is not a clean file', () => {
31
+ let tmpDir;
32
+ const originalCwd = process.cwd;
33
+
34
+ /**
35
+ * Write an eslint stand-in in the layout this platform actually executes.
36
+ *
37
+ * On Windows cmd.exe cannot run an extensionless POSIX wrapper, so npm installs
38
+ * a `.cmd` launcher; a stub named only `eslint` would exercise a path that never
39
+ * exists here and the test would fail for an unrelated reason.
40
+ *
41
+ * @param {string} jsBody statements the fake linter runs
42
+ */
43
+ function writeEslintStub(jsBody) {
44
+ const binDir = path.join(tmpDir, 'node_modules', '.bin');
45
+ fs.mkdirSync(binDir, { recursive: true });
46
+ const js = `#!/usr/bin/env node\n${jsBody}\n`;
47
+ if (process.platform === 'win32') {
48
+ fs.writeFileSync(path.join(binDir, 'eslint-stub.js'), js);
49
+ fs.writeFileSync(
50
+ path.join(binDir, 'eslint.cmd'),
51
+ '@node "%~dp0eslint-stub.js" %*\r\n'
52
+ );
53
+ return;
54
+ }
55
+ const stub = path.join(binDir, 'eslint');
56
+ fs.writeFileSync(stub, js);
57
+ fs.chmodSync(stub, 0o755);
58
+ }
59
+
60
+ function git(...args) {
61
+ execFileSync('git', ['-c', 'user.email=t@t', '-c', 'user.name=t', ...args], {
62
+ cwd: tmpDir,
63
+ stdio: 'pipe',
64
+ });
65
+ }
66
+
67
+ function readBaseline() {
68
+ return JSON.parse(
69
+ fs.readFileSync(path.join(tmpDir, '.xp-gate', 'lint-baseline.json'), 'utf8')
70
+ );
71
+ }
72
+
73
+ beforeEach(() => {
74
+ tmpDir = fs.mkdtempSync(path.join(os.tmpdir(), 'baseline-unevaluated-'));
75
+ process.cwd = () => tmpDir;
76
+ // findFilesByExt enumerates with `git ls-files`, so a fixture outside a work
77
+ // tree yields no files and the linter is never invoked -- every assertion
78
+ // below would then pass while the code under test never ran.
79
+ execFileSync('git', ['init', '-q'], { cwd: tmpDir });
80
+ fs.writeFileSync(path.join(tmpDir, '.eslintrc.json'), '{}\n');
81
+ // Under src/, not at the root: findFilesByExt enumerates with
82
+ // `git ls-files "**/*.js"`, and that glob matches only files in a
83
+ // subdirectory -- a root-level a.js is invisible to it, so the linter branch
84
+ // would never run and both tests would pass without exercising the fix.
85
+ // Measured: `git ls-files "**/*.js"` returns "" for a tracked root a.js.
86
+ fs.mkdirSync(path.join(tmpDir, 'src'), { recursive: true });
87
+ fs.writeFileSync(path.join(tmpDir, 'src', 'a.js'), 'const a = 1;\n');
88
+ git('add', '.eslintrc.json', 'src/a.js');
89
+
90
+ // A baseline from a previous successful run: this file had two warnings.
91
+ fs.mkdirSync(path.join(tmpDir, '.xp-gate'), { recursive: true });
92
+ fs.writeFileSync(
93
+ path.join(tmpDir, '.xp-gate', 'lint-baseline.json'),
94
+ JSON.stringify({
95
+ 'src/a.js': { eslint: { warnings: 2, errors: 0 }, totalWarnings: 2 },
96
+ }, null, 2)
97
+ );
98
+ });
99
+
100
+ afterEach(() => {
101
+ process.cwd = originalCwd;
102
+ fs.rmSync(tmpDir, { recursive: true, force: true });
103
+ });
104
+
105
+ it('AC-BASELINE-05: keeps the previous entry when the linter cannot run', async () => {
106
+ // Exit non-zero with no stdout: the shape of a crashed or unspawnable tool,
107
+ // and the only shape runLintInBatches treats as "not evaluated".
108
+ writeEslintStub('process.exit(1);');
109
+
110
+ const baseline = await createBaseline();
111
+
112
+ // The defect: without the carry-over this entry vanished, so Gate 1 compared
113
+ // a.js against a baseline of nothing and reported its two known warnings as
114
+ // brand new.
115
+ expect(baseline['src/a.js']).toBeDefined();
116
+ expect(baseline['src/a.js'].eslint.warnings).toBe(2);
117
+ expect(readBaseline()['src/a.js'].eslint.warnings).toBe(2);
118
+ });
119
+
120
+ it('AC-BASELINE-06: still shrinks when the linter DOES answer', async () => {
121
+ // The companion the failure test cannot provide: a "preserve everything" fix
122
+ // would pass AC-BASELINE-05 and leave the baseline permanently unshrinkable.
123
+ writeEslintStub(`
124
+ const files = process.argv.slice(2).filter(
125
+ a => !a.startsWith('-') && a !== 'json'
126
+ );
127
+ const out = files.map(f => ({
128
+ filePath: require('path').resolve(f),
129
+ warningCount: 0,
130
+ errorCount: 0,
131
+ }));
132
+ process.stdout.write(JSON.stringify(out));
133
+ `);
134
+
135
+ const baseline = await createBaseline();
136
+
137
+ // Evaluated and clean: the stale count must be replaced, not carried.
138
+ expect(baseline['src/a.js']).toBeDefined();
139
+ expect(baseline['src/a.js'].eslint.warnings).toBe(0);
140
+ expect(readBaseline()['src/a.js'].eslint.warnings).toBe(0);
141
+ });
142
+ });
package/lib/baseline.js CHANGED
@@ -22,6 +22,27 @@ function getBaselineFile() {
22
22
  return path.join(getXpGateDir(), 'lint-baseline.json');
23
23
  }
24
24
 
25
+ /**
26
+ * Read the baseline currently on disk for use as a fallback while rebuilding.
27
+ *
28
+ * Returns `{}` when there is nothing to read. Both "no baseline yet" and "the
29
+ * existing baseline is corrupt" must behave the same way here: this value only
30
+ * ever RESTORES entries for files the rebuild could not evaluate, so a repair
31
+ * path is not needed. Note the difference from the readers elsewhere in this
32
+ * file, which fail loudly -- those answer "what is the baseline", and a wrong
33
+ * answer there changes a verdict. This one only decides whether to keep a row
34
+ * it already had.
35
+ */
36
+ function readBaselineForMerge() {
37
+ try {
38
+ const raw = fs.readFileSync(getBaselineFile(), 'utf8');
39
+ const parsed = JSON.parse(raw);
40
+ return parsed && typeof parsed === 'object' && !Array.isArray(parsed) ? parsed : {};
41
+ } catch {
42
+ return {};
43
+ }
44
+ }
45
+
25
46
  function ensureDir(dirPath) {
26
47
  if (!fs.existsSync(dirPath)) {
27
48
  fs.mkdirSync(dirPath, { recursive: true });
@@ -61,13 +82,21 @@ const LINT_BATCH_SIZE = 100;
61
82
  * @param {string[]} files project-relative paths
62
83
  * @param {(batch: string[]) => string} buildCmd builds the command line for a batch
63
84
  * @param {string} jsonFlag flag that makes the tool emit JSON on stdout
64
- * @returns {{results: any[], errors: string[]}} parsed per-batch results, or a
65
- * list of failure messages. An empty `results` with a non-empty `errors` means
66
- * "not evaluated", never "clean".
85
+ * @returns {{results: any[], errors: string[], failedFiles: string[]}} parsed
86
+ * per-batch results, a list of failure messages, and the files that were in a
87
+ * batch which produced no usable output. An empty `results` with a non-empty
88
+ * `errors` means "not evaluated", never "clean".
89
+ *
90
+ * `failedFiles` exists because the caller must be able to tell an evaluated
91
+ * file from an unevaluated one. Without it, a batch that crashed was
92
+ * indistinguishable from a batch that reported nothing, and the baseline
93
+ * writer treated both as "no issues here" -- then wrote that conclusion to
94
+ * disk, overwriting the entries the previous successful run had recorded.
67
95
  */
68
96
  function runLintInBatches(files, buildCmd, jsonFlag) {
69
97
  const results = [];
70
98
  const errors = [];
99
+ const failedFiles = [];
71
100
 
72
101
  for (let i = 0; i < files.length; i += LINT_BATCH_SIZE) {
73
102
  const batch = files.slice(i, i + LINT_BATCH_SIZE);
@@ -83,20 +112,28 @@ function runLintInBatches(files, buildCmd, jsonFlag) {
83
112
  stdout = e.stdout;
84
113
  if (!stdout || !String(stdout).trim()) {
85
114
  errors.push(formatToolFailure(e));
115
+ failedFiles.push(...batch);
86
116
  continue;
87
117
  }
88
118
  }
89
119
  const trimmed = String(stdout).trim();
90
- if (!trimmed) continue;
120
+ if (!trimmed) {
121
+ // No output at all for a batch the tool was asked about: nothing was
122
+ // evaluated, so these files must not be recorded as clean.
123
+ failedFiles.push(...batch);
124
+ continue;
125
+ }
91
126
  try {
92
127
  const parsed = JSON.parse(trimmed);
93
128
  if (Array.isArray(parsed)) results.push(...parsed);
129
+ else failedFiles.push(...batch);
94
130
  } catch {
95
131
  errors.push(`linter returned unparseable output for ${batch.length} file(s)`);
132
+ failedFiles.push(...batch);
96
133
  }
97
134
  }
98
135
 
99
- return { results, errors };
136
+ return { results, errors, failedFiles };
100
137
  }
101
138
 
102
139
  /**
@@ -275,6 +312,23 @@ async function createBaseline() {
275
312
 
276
313
  const baseline = {};
277
314
 
315
+ // The baseline is a RATCHET: it records what was already known so a new issue
316
+ // stands out. Rebuilding it from an empty object is correct only for files that
317
+ // were actually evaluated. A batch whose linter could not run taught us nothing
318
+ // about its files, so writing them as "no entry" would silently lower the bar
319
+ // for every one of them -- and because the write is unconditional, a run in
320
+ // which every tool failed replaced a good baseline with `{}`. That is a
321
+ // measured recurrence in this repo: it presents as
322
+ // BLOCKED - 50 NEW shellcheck issue(s) (baseline: 0, current: 50)
323
+ // on a tree where nothing had changed, and it cannot be distinguished from a
324
+ // genuine regression until the old baseline is reconstructed by hand.
325
+ //
326
+ // So: read what was on disk, and after the rebuild put back the entries for
327
+ // files this run could not evaluate. Files that WERE evaluated still shrink --
328
+ // that is the ratchet working -- because `baseline[file]` is set for them.
329
+ const previous = readBaselineForMerge();
330
+ const unevaluated = new Set();
331
+
278
332
  // TypeScript/JavaScript — ESLint
279
333
  const tsFiles = findFilesByExt(['.ts', '.tsx', '.js', '.jsx']);
280
334
  if (tsFiles.length > 0) {
@@ -296,12 +350,13 @@ async function createBaseline() {
296
350
 
297
351
  if (eslintConfigExists && eslintAvailable) {
298
352
  const eslintCmd = eslintBin ? quoteBin(eslintBin) : 'npx eslint';
299
- const { results, errors } = runLintInBatches(
353
+ const { results, errors, failedFiles } = runLintInBatches(
300
354
  tsFiles,
301
355
  batch => `${eslintCmd} ${batch.map(f => `"${f}"`).join(' ')}`,
302
356
  '-f json --no-warn-ignored'
303
357
  );
304
358
  recordFailures('eslint', errors);
359
+ failedFiles.forEach(f => unevaluated.add(f));
305
360
  for (const fileResult of results) {
306
361
  const fileName = matchResultToFile(fileResult.filePath, tsFiles);
307
362
  if (!fileName) continue;
@@ -334,12 +389,13 @@ async function createBaseline() {
334
389
  }
335
390
 
336
391
  if (ruffAvailable) {
337
- const { results, errors } = runLintInBatches(
392
+ const { results, errors, failedFiles } = runLintInBatches(
338
393
  pyFiles,
339
394
  batch => `ruff check ${batch.map(f => `"${f}"`).join(' ')}`,
340
395
  '--output-format json'
341
396
  );
342
397
  recordFailures('ruff', errors);
398
+ failedFiles.forEach(f => unevaluated.add(f));
343
399
  for (const fileResult of results) {
344
400
  // A result that names no file cannot be recorded against one. Skipping it
345
401
  // is the fix for the literal "undefined" key this used to write.
@@ -413,12 +469,13 @@ async function createBaseline() {
413
469
  // Same batching as the other tools: one argv for every shell script in the
414
470
  // repo is the same platform-limit hazard, even though this repo happens to
415
471
  // sit under the threshold today.
416
- const { results, errors } = runLintInBatches(
472
+ const { results, errors, failedFiles } = runLintInBatches(
417
473
  shFiles,
418
474
  batch => `shellcheck -f json ${batch.map(f => `"${f}"`).join(' ')}`,
419
475
  ''
420
476
  );
421
477
  recordFailures('shellcheck', errors);
478
+ failedFiles.forEach(f => unevaluated.add(f));
422
479
  const warningsByFile = {};
423
480
  for (const item of results) {
424
481
  const matchedFile = matchResultToFile(item.file, shFiles);
@@ -447,6 +504,24 @@ async function createBaseline() {
447
504
  }
448
505
  }
449
506
 
507
+ // Restore what this run could not evaluate, so a broken toolchain cannot
508
+ // rewrite known-bad files as clean. `baseline[file]` being set means some tool
509
+ // did evaluate it this run, and the fresh value wins -- that is the ratchet
510
+ // shrinking, not data loss.
511
+ let carried = 0;
512
+ for (const file of unevaluated) {
513
+ if (baseline[file]) continue;
514
+ if (!Object.prototype.hasOwnProperty.call(previous, file)) continue;
515
+ baseline[file] = previous[file];
516
+ carried++;
517
+ }
518
+ if (carried > 0) {
519
+ console.log(
520
+ `Kept ${carried} baseline entry/entries for files no linter could evaluate ` +
521
+ `(${unevaluated.size} file(s) affected) -- not evaluated is not clean.`
522
+ );
523
+ }
524
+
450
525
  fs.writeFileSync(getBaselineFile(), JSON.stringify(baseline, null, 2));
451
526
  return baseline;
452
527
  }
@@ -2,6 +2,6 @@
2
2
  "verdict": "PASS",
3
3
  "license_type": "MIT",
4
4
  "sha256": "0e7ac423bf2c6e223b7c5b156f8cf72da49d748e56a1641402c31f22ad07dbb5",
5
- "checked_at": "2026-11-18T05:33:53.225Z",
5
+ "checked_at": "2026-11-18T08:33:34.319Z",
6
6
  "source": "network"
7
7
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@boyingliu01/xp-gate",
3
- "version": "0.38.12",
3
+ "version": "0.38.14",
4
4
  "description": "AI-driven development workflow: 6 quality gates + Delphi review + Sprint Flow",
5
5
  "bin": {
6
6
  "xp-gate": "bin/xp-gate.js"
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "xp-gate",
3
- "version": "0.38.12",
3
+ "version": "0.38.14",
4
4
  "displayName": "XP-Gate",
5
5
  "description": "Extreme Programming quality gates + AI workflow skills for Claude Code. Includes 12 pre-commit gates (Gate 0-11), 8 pre-push gates, Sprint Flow (6 phases), and Delphi multi-expert review (>=90% consensus).",
6
6
  "author": {
@@ -3,7 +3,7 @@
3
3
  **Generated:** 2026-11-04
4
4
  **Commit:** eb2097b0
5
5
  **Branch:** sprint/2026-11-03-02
6
- **Version:** 0.38.12.0
6
+ **Version:** 0.38.14.0
7
7
 
8
8
  ## OVERVIEW
9
9
  Delphi Consensus Review — multi-round anonymous expert review (≥90% threshold, exactly 3 experts with distinct executable model IDs). Supports design, requirements, and code-walkthrough modes.
@@ -3,7 +3,7 @@
3
3
  **Generated:** 2026-11-04
4
4
  **Commit:** eb2097b0
5
5
  **Branch:** sprint/2026-11-03-02
6
- **Version:** 0.38.12.0
6
+ **Version:** 0.38.14.0
7
7
 
8
8
  ## OVERVIEW
9
9
  **6-phase** development pipeline (v2.0 compact redesign, Issue #290): PREP → DESIGN → BUILD → VERIFY → SHIP → CLOSE. Phase 3/6 BUILD default build mode is **ralph-loop** (REQ-level iteration; each REQ starts from a clean context instead of accumulating one across REQs). HARD-GATE between DESIGN (2/6) and BUILD (3/6): design must pass Delphi review (≥90% consensus) before any coding.
@@ -3,7 +3,7 @@
3
3
  **Generated:** 2026-11-04
4
4
  **Commit:** eb2097b0
5
5
  **Branch:** sprint/2026-11-03-02
6
- **Version:** 0.38.12.0
6
+ **Version:** 0.38.14.0
7
7
 
8
8
  ## OVERVIEW
9
9
  Test-Specification Alignment Engine — two-stage validation ensuring tests accurately reflect requirements and design specs.
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@boyingliu01/dsh-plugin-xp-gate",
3
- "version": "0.38.12",
3
+ "version": "0.38.14",
4
4
  "description": "XP-Gate deterministic quality gates + AI workflow skills as a DeepSeek Harness (DSH) native plugin: gate-check / gate-principles / gate-arch tools + 12 SKILL.md skills",
5
5
  "type": "module",
6
6
  "main": "./lib/index.js",
@@ -3,7 +3,7 @@
3
3
  **Generated:** 2026-11-04
4
4
  **Commit:** eb2097b0
5
5
  **Branch:** sprint/2026-11-03-02
6
- **Version:** 0.38.12.0
6
+ **Version:** 0.38.14.0
7
7
 
8
8
  ## OVERVIEW
9
9
  Delphi Consensus Review — multi-round anonymous expert review (≥90% threshold, exactly 3 experts with distinct executable model IDs). Supports design, requirements, and code-walkthrough modes.
@@ -3,7 +3,7 @@
3
3
  **Generated:** 2026-11-04
4
4
  **Commit:** eb2097b0
5
5
  **Branch:** sprint/2026-11-03-02
6
- **Version:** 0.38.12.0
6
+ **Version:** 0.38.14.0
7
7
 
8
8
  ## OVERVIEW
9
9
  **6-phase** development pipeline (v2.0 compact redesign, Issue #290): PREP → DESIGN → BUILD → VERIFY → SHIP → CLOSE. Phase 3/6 BUILD default build mode is **ralph-loop** (REQ-level iteration; each REQ starts from a clean context instead of accumulating one across REQs). HARD-GATE between DESIGN (2/6) and BUILD (3/6): design must pass Delphi review (≥90% consensus) before any coding.
@@ -3,7 +3,7 @@
3
3
  **Generated:** 2026-11-04
4
4
  **Commit:** eb2097b0
5
5
  **Branch:** sprint/2026-11-03-02
6
- **Version:** 0.38.12.0
6
+ **Version:** 0.38.14.0
7
7
 
8
8
  ## OVERVIEW
9
9
  Test-Specification Alignment Engine — two-stage validation ensuring tests accurately reflect requirements and design specs.
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@boyingliu01/opencode-plugin",
3
- "version": "0.38.12",
3
+ "version": "0.38.14",
4
4
  "type": "module",
5
5
  "main": "index.ts",
6
6
  "description": "XP-Gate quality gates + AI workflow skills for OpenCode",
@@ -3,7 +3,7 @@
3
3
  **Generated:** 2026-11-04
4
4
  **Commit:** eb2097b0
5
5
  **Branch:** sprint/2026-11-03-02
6
- **Version:** 0.38.12.0
6
+ **Version:** 0.38.14.0
7
7
 
8
8
  ## OVERVIEW
9
9
  Delphi Consensus Review — multi-round anonymous expert review (≥90% threshold, exactly 3 experts with distinct executable model IDs). Supports design, requirements, and code-walkthrough modes.
@@ -3,7 +3,7 @@
3
3
  **Generated:** 2026-11-04
4
4
  **Commit:** eb2097b0
5
5
  **Branch:** sprint/2026-11-03-02
6
- **Version:** 0.38.12.0
6
+ **Version:** 0.38.14.0
7
7
 
8
8
  ## OVERVIEW
9
9
  **6-phase** development pipeline (v2.0 compact redesign, Issue #290): PREP → DESIGN → BUILD → VERIFY → SHIP → CLOSE. Phase 3/6 BUILD default build mode is **ralph-loop** (REQ-level iteration; each REQ starts from a clean context instead of accumulating one across REQs). HARD-GATE between DESIGN (2/6) and BUILD (3/6): design must pass Delphi review (≥90% consensus) before any coding.
@@ -3,7 +3,7 @@
3
3
  **Generated:** 2026-11-04
4
4
  **Commit:** eb2097b0
5
5
  **Branch:** sprint/2026-11-03-02
6
- **Version:** 0.38.12.0
6
+ **Version:** 0.38.14.0
7
7
 
8
8
  ## OVERVIEW
9
9
  Test-Specification Alignment Engine — two-stage validation ensuring tests accurately reflect requirements and design specs.
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "xp-gate",
3
- "version": "0.38.12",
3
+ "version": "0.38.14",
4
4
  "displayName": "XP-Gate",
5
5
  "description": "Extreme Programming quality gates + AI workflow skills for Qoder. Includes 12 pre-commit gates (Gate 0-11), 8 pre-push gates, Sprint Flow (6 phases), and Delphi multi-expert review (>=90% consensus).",
6
6
  "author": {
@@ -3,7 +3,7 @@
3
3
  **Generated:** 2026-11-04
4
4
  **Commit:** eb2097b0
5
5
  **Branch:** sprint/2026-11-03-02
6
- **Version:** 0.38.12.0
6
+ **Version:** 0.38.14.0
7
7
 
8
8
  ## OVERVIEW
9
9
  Delphi Consensus Review — multi-round anonymous expert review (≥90% threshold, exactly 3 experts with distinct executable model IDs). Supports design, requirements, and code-walkthrough modes.
@@ -3,7 +3,7 @@
3
3
  **Generated:** 2026-11-04
4
4
  **Commit:** eb2097b0
5
5
  **Branch:** sprint/2026-11-03-02
6
- **Version:** 0.38.12.0
6
+ **Version:** 0.38.14.0
7
7
 
8
8
  ## OVERVIEW
9
9
  **6-phase** development pipeline (v2.0 compact redesign, Issue #290): PREP → DESIGN → BUILD → VERIFY → SHIP → CLOSE. Phase 3/6 BUILD default build mode is **ralph-loop** (REQ-level iteration; each REQ starts from a clean context instead of accumulating one across REQs). HARD-GATE between DESIGN (2/6) and BUILD (3/6): design must pass Delphi review (≥90% consensus) before any coding.
@@ -3,7 +3,7 @@
3
3
  **Generated:** 2026-11-04
4
4
  **Commit:** eb2097b0
5
5
  **Branch:** sprint/2026-11-03-02
6
- **Version:** 0.38.12.0
6
+ **Version:** 0.38.14.0
7
7
 
8
8
  ## OVERVIEW
9
9
  Test-Specification Alignment Engine — two-stage validation ensuring tests accurately reflect requirements and design specs.
@@ -3,7 +3,7 @@
3
3
  **Generated:** 2026-11-04
4
4
  **Commit:** eb2097b0
5
5
  **Branch:** sprint/2026-11-03-02
6
- **Version:** 0.38.12.0
6
+ **Version:** 0.38.14.0
7
7
 
8
8
  ## OVERVIEW
9
9
  Delphi Consensus Review — multi-round anonymous expert review (≥90% threshold, exactly 3 experts with distinct executable model IDs). Supports design, requirements, and code-walkthrough modes.
@@ -3,7 +3,7 @@
3
3
  **Generated:** 2026-11-04
4
4
  **Commit:** eb2097b0
5
5
  **Branch:** sprint/2026-11-03-02
6
- **Version:** 0.38.12.0
6
+ **Version:** 0.38.14.0
7
7
 
8
8
  ## OVERVIEW
9
9
  **6-phase** development pipeline (v2.0 compact redesign, Issue #290): PREP → DESIGN → BUILD → VERIFY → SHIP → CLOSE. Phase 3/6 BUILD default build mode is **ralph-loop** (REQ-level iteration; each REQ starts from a clean context instead of accumulating one across REQs). HARD-GATE between DESIGN (2/6) and BUILD (3/6): design must pass Delphi review (≥90% consensus) before any coding.
@@ -3,7 +3,7 @@
3
3
  **Generated:** 2026-11-04
4
4
  **Commit:** eb2097b0
5
5
  **Branch:** sprint/2026-11-03-02
6
- **Version:** 0.38.12.0
6
+ **Version:** 0.38.14.0
7
7
 
8
8
  ## OVERVIEW
9
9
  Test-Specification Alignment Engine — two-stage validation ensuring tests accurately reflect requirements and design specs.