@boyingliu01/xp-gate 0.38.5 → 0.38.7
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/adapters/gate-7.sh +7 -2
- package/build-integrity/gate-10.ts +45 -27
- package/gate-7.sh +7 -2
- package/hooks/gate-7.sh +7 -2
- package/hooks/gate-entries/gate-0-entry.sh +249 -28
- package/hooks/gate-entries/gate-1-entry.sh +81 -3
- package/hooks/gate-entries/gate-10-entry.sh +7 -0
- package/hooks/gate-entries/gate-11-entry.sh +7 -0
- package/hooks/gate-entries/gate-12-entry.sh +7 -0
- package/hooks/gate-entries/gate-12b-entry.sh +7 -0
- package/hooks/gate-entries/gate-12c-entry.sh +7 -0
- package/hooks/gate-entries/gate-13-entry.sh +7 -0
- package/hooks/gate-entries/gate-5-entry.sh +48 -2
- package/hooks/gate-entries/gate-6-entry.sh +93 -2
- package/hooks/gate-entries/gate-7-entry.sh +7 -0
- package/hooks/gate-entries/gate-8-entry.sh +7 -0
- package/hooks/gate-entries/gate-9-entry.sh +7 -0
- package/lib/mattpocock-license-verdict.json +1 -1
- package/mock-policy/AGENTS.md +1 -1
- package/mutation/AGENTS.md +1 -1
- package/package.json +1 -1
- package/plugins/claude-code/.claude-plugin/plugin.json +1 -1
- package/plugins/claude-code/skills/delphi-review/AGENTS.md +1 -1
- package/plugins/claude-code/skills/sprint-flow/AGENTS.md +1 -1
- package/plugins/claude-code/skills/test-specification-alignment/AGENTS.md +1 -1
- package/plugins/dsh/package.json +1 -1
- package/plugins/dsh/skills/delphi-review/AGENTS.md +1 -1
- package/plugins/dsh/skills/sprint-flow/AGENTS.md +1 -1
- package/plugins/dsh/skills/test-specification-alignment/AGENTS.md +1 -1
- package/plugins/opencode/package.json +1 -1
- package/plugins/opencode/skills/delphi-review/AGENTS.md +1 -1
- package/plugins/opencode/skills/sprint-flow/AGENTS.md +1 -1
- package/plugins/opencode/skills/test-specification-alignment/AGENTS.md +1 -1
- package/plugins/qoder/plugin.json +1 -1
- package/plugins/qoder/skills/delphi-review/AGENTS.md +1 -1
- package/plugins/qoder/skills/sprint-flow/AGENTS.md +1 -1
- package/plugins/qoder/skills/test-specification-alignment/AGENTS.md +1 -1
- package/principles/AGENTS.md +1 -1
- package/principles/analyzer.ts +12 -1
- package/principles/config.ts +179 -0
- package/scripts/generate-mirrors.cjs +85 -28
- package/scripts/sync-package-content.js +5 -0
- package/skills/delphi-review/AGENTS.md +1 -1
- package/skills/sprint-flow/AGENTS.md +1 -1
- package/skills/test-specification-alignment/AGENTS.md +1 -1
- package/build-integrity/__tests__/ccn-refactor-gate10.test.ts +0 -133
- package/build-integrity/__tests__/gate-10.test.ts +0 -340
- package/build-integrity/__tests__/import-resolver.test.ts +0 -747
- package/build-integrity/__tests__/orchestrator.test.ts +0 -302
- package/build-integrity/__tests__/quote-masker.test.ts +0 -177
- package/skills/sprint-flow/__tests__/sprint-flow.test.cjs +0 -457
- package/skills/sprint-flow/__tests__/verify-sprint-state.test.bats +0 -70
|
@@ -34,6 +34,13 @@
|
|
|
34
34
|
# stop: see scripts/wrap-gate-entries.cjs for why the two are equivalent
|
|
35
35
|
# here, and why sub-shell exits are deliberately left as `exit`.
|
|
36
36
|
gate_12b_run() {
|
|
37
|
+
if ! gate_enabled 12b; then
|
|
38
|
+
echo "⏭️ SKIPPED - Gate 12b: Vendor exclusion (not selected by XP_GATE_ONLY_GATE)"
|
|
39
|
+
GATE_12B_STATUS="SKIP"
|
|
40
|
+
GATE_12B_DETAIL="not_selected"
|
|
41
|
+
return 0
|
|
42
|
+
fi
|
|
43
|
+
|
|
37
44
|
MIRROR_STAGED=$(git diff --cached --name-only --diff-filter=ACMR 2>/dev/null || true)
|
|
38
45
|
# `src/npm-package/` is in this filter because a mirror-only edit is the
|
|
39
46
|
# dangerous direction, not the harmless one. Keying off the canonical paths
|
|
@@ -36,6 +36,13 @@ gate_12c_run() {
|
|
|
36
36
|
# Scoped to commits that touch hook sources: the rule can only be broken by
|
|
37
37
|
# editing one, and scanning 51 files on every docs-only commit is exactly the
|
|
38
38
|
# fixed cost the input short-circuit convention exists to avoid.
|
|
39
|
+
if ! gate_enabled 12c; then
|
|
40
|
+
echo "⏭️ SKIPPED - Gate 12c: Worktree hygiene (not selected by XP_GATE_ONLY_GATE)"
|
|
41
|
+
GATE_12C_STATUS="SKIP"
|
|
42
|
+
GATE_12C_DETAIL="not_selected"
|
|
43
|
+
return 0
|
|
44
|
+
fi
|
|
45
|
+
|
|
39
46
|
if printf '%s\n' "$STAGED_FILES" 2>/dev/null | grep -qE '^githooks/(adapters/|lib/|adapter-common\.sh|pre-commit|pre-push|post-commit|post-merge)'; then
|
|
40
47
|
_probe_root="${PROJECT_ROOT:-}"
|
|
41
48
|
if [ -n "$_probe_root" ] && [ -f "$_probe_root/scripts/check-no-npx-probe.sh" ]; then
|
|
@@ -509,6 +509,13 @@ ENDJSON
|
|
|
509
509
|
}
|
|
510
510
|
|
|
511
511
|
gate_13_run() {
|
|
512
|
+
if ! gate_enabled 13; then
|
|
513
|
+
echo "⏭️ SKIPPED - Gate 13: Compiler strictness (not selected by XP_GATE_ONLY_GATE)"
|
|
514
|
+
GATE_13_STATUS="SKIP"
|
|
515
|
+
GATE_13_DETAIL="not_selected"
|
|
516
|
+
return 0
|
|
517
|
+
fi
|
|
518
|
+
|
|
512
519
|
GATE_13_STATUS="SKIP"
|
|
513
520
|
if [ "${XP_GATE_DISABLE_13:-}" = "1" ]; then
|
|
514
521
|
echo "⏭️ SKIPPED - Gate 13: Compiler Strictness (XP_GATE_DISABLE_13=1)"
|
|
@@ -895,7 +895,25 @@ else
|
|
|
895
895
|
# staged 42% never reached the threshold. The skip now also requires that no
|
|
896
896
|
# coverage evidence is present.
|
|
897
897
|
GATE_5_COVERAGE_EVIDENCE=false
|
|
898
|
-
|
|
898
|
+
# #821: evidence must come FROM THE COMMIT, not from the working tree.
|
|
899
|
+
#
|
|
900
|
+
# This used to be a bare `-f` on the two report paths, so ANY leftover report
|
|
901
|
+
# counted -- e.g. coverage/coverage-summary.json left behind by an earlier local
|
|
902
|
+
# run over a different tree. Measured 2026-11-16 in this repo: a commit staging
|
|
903
|
+
# one test file under the bundled mirror was blocked with
|
|
904
|
+
# ❌ BLOCKED - TypeScript coverage 2% below 78% threshold
|
|
905
|
+
# and the identical commit passed once the leftover coverage/ directory was
|
|
906
|
+
# removed. The percentage described neither this commit nor this tree, and the
|
|
907
|
+
# working tree additionally carried a second workstream's uncommitted source.
|
|
908
|
+
#
|
|
909
|
+
# A report is evidence for this commit when the commit carries it. This keeps
|
|
910
|
+
# #601 intact -- that issue is about a STAGED report being ignored, and its
|
|
911
|
+
# fixtures stage the artefact with `git add -f` -- while refusing to answer
|
|
912
|
+
# "how well is this change tested" with a stale measurement of something else.
|
|
913
|
+
# `git cat-file -e :<path>` asks the INDEX (the commit being built) for the
|
|
914
|
+
# blob; a plain `-f` asks the directory.
|
|
915
|
+
if git cat-file -e ":coverage/coverage-summary.json" 2>/dev/null \
|
|
916
|
+
|| git cat-file -e ":coverage/coverage-final.json" 2>/dev/null; then
|
|
899
917
|
GATE_5_COVERAGE_EVIDENCE=true
|
|
900
918
|
fi
|
|
901
919
|
if [ "${TESTS_SKIPPED:-false}" = "true" ] && [ "${TESTS_RAN_ANY:-false}" != "true" ] \
|
|
@@ -1268,7 +1286,35 @@ else
|
|
|
1268
1286
|
# #570: the report file is absent, so nothing was measured. Warning and
|
|
1269
1287
|
# continuing made "delete coverage/coverage-summary.json" an effective way
|
|
1270
1288
|
# to switch this gate off.
|
|
1271
|
-
|
|
1289
|
+
#
|
|
1290
|
+
# #823: but "absent" has two causes and only one of them is a problem.
|
|
1291
|
+
# Measured 2026-11-16 committing a comment-only fix to a gate script --
|
|
1292
|
+
# Gate 5 printed, in this order,
|
|
1293
|
+
# ✅ PASSED - No test or source files changed, skipping test run.
|
|
1294
|
+
# ℹ️ No TypeScript tests were selected — no TS coverage to evaluate.
|
|
1295
|
+
# ❌ BLOCKED - coverage/coverage-summary.json not found.
|
|
1296
|
+
# The gate established twice that it had nothing to measure, then demanded
|
|
1297
|
+
# a measurement. PARTIAL_TEST_RUN did not cover it because that flag means
|
|
1298
|
+
# "some tests ran"; here NO test was selected, so a commit touching nothing
|
|
1299
|
+
# but shell reached the strict arm of #570 and could only land with a Gate 0
|
|
1300
|
+
# version bump or a fabricated report.
|
|
1301
|
+
#
|
|
1302
|
+
# #570 stays intact: tests SELECTED but producing no report is still the
|
|
1303
|
+
# off-switch this must block. Only "nothing was selected" is exempt.
|
|
1304
|
+
#
|
|
1305
|
+
# The exemption keys on TESTS_SKIPPED ALONE, deliberately. The obvious
|
|
1306
|
+
# pairing -- `TESTS_SKIPPED && !TESTS_RAN_ANY` -- does not work, and the
|
|
1307
|
+
# probe that proved it is worth recording: on the reproduction above the
|
|
1308
|
+
# two flags read `skipped=true ran=true` at the same moment. TESTS_RAN_ANY
|
|
1309
|
+
# is set by the IaC arm when its run_tests prints "IaC tests not configured"
|
|
1310
|
+
# and returns 0 (gate-5-entry.sh:850-853, #760), because a runner DID
|
|
1311
|
+
# execute -- it just had nothing to test. So `!TESTS_RAN_ANY` is false for
|
|
1312
|
+
# any repo declaring iac, which is every repo using this gate the way this
|
|
1313
|
+
# one does. TESTS_SKIPPED is the precise signal: it is set only where the
|
|
1314
|
+
# test section concluded there was nothing to run.
|
|
1315
|
+
if [ "${TESTS_SKIPPED:-false}" = "true" ]; then
|
|
1316
|
+
echo "ℹ️ No tests were selected, so no coverage report was expected — skipping the coverage floor."
|
|
1317
|
+
elif [ "${PARTIAL_TEST_RUN:-false}" = "true" ]; then
|
|
1272
1318
|
echo "⚠️ coverage/coverage-summary.json not found (subset test run) — not blocking."
|
|
1273
1319
|
else
|
|
1274
1320
|
echo "❌ BLOCKED - coverage/coverage-summary.json not found."
|
|
@@ -24,6 +24,13 @@
|
|
|
24
24
|
# stop: see scripts/wrap-gate-entries.cjs for why the two are equivalent
|
|
25
25
|
# here, and why sub-shell exits are deliberately left as `exit`.
|
|
26
26
|
gate_6_run() {
|
|
27
|
+
if ! gate_enabled 6; then
|
|
28
|
+
echo "⏭️ SKIPPED - Gate 6: Architecture & tech debt (not selected by XP_GATE_ONLY_GATE)"
|
|
29
|
+
GATE_6_STATUS="SKIP"
|
|
30
|
+
GATE_6_DETAIL="not_selected"
|
|
31
|
+
return 0
|
|
32
|
+
fi
|
|
33
|
+
|
|
27
34
|
2>&1 echo ""
|
|
28
35
|
2>&1 echo "→ Gate 6: Architecture & tech debt..."
|
|
29
36
|
GATE_6_START=$(gate_start_ms)
|
|
@@ -50,6 +57,50 @@ else
|
|
|
50
57
|
fi
|
|
51
58
|
)
|
|
52
59
|
|
|
60
|
+
# ---------------------------------------------------------------------------
|
|
61
|
+
# Which tree does the verdict describe? The COMMIT, not the directory.
|
|
62
|
+
#
|
|
63
|
+
# `archlint diff <baseline>` makes its CURRENT argument default to "analyze the
|
|
64
|
+
# current working tree", so the pass/fail verdict included every uncommitted
|
|
65
|
+
# file in the checkout -- including files belonging to other work in progress.
|
|
66
|
+
# Measured 2026-11-11 in this repo: a worktree carrying 7 unstaged files put 217
|
|
67
|
+
# regressions / 122 files into the verdict, none of which the commit under
|
|
68
|
+
# review had touched. Two things then went wrong at once:
|
|
69
|
+
#
|
|
70
|
+
# 1. the block was attributed to the wrong author (a commit is blocked by
|
|
71
|
+
# someone else's editor buffer), and
|
|
72
|
+
# 2. the block message advised `archlint snapshot -o .architecture-baseline.json`
|
|
73
|
+
# -- correct for a genuine regression, but here it froze ANOTHER PERSON'S
|
|
74
|
+
# UNCOMMITTED WORK into the baseline as the accepted norm. Following the
|
|
75
|
+
# tool's own advice made the repo worse.
|
|
76
|
+
#
|
|
77
|
+
# A commit contains the index, so the index is the correct input. `git
|
|
78
|
+
# write-tree` + `git commit-tree` cheaply produce a commit object holding
|
|
79
|
+
# exactly the staged content; archlint accepts a git ref and analyzes a
|
|
80
|
+
# temporary worktree of it. The object is unreachable (no ref, no reflog entry)
|
|
81
|
+
# and is reclaimed by gc -- it never appears in the history being committed.
|
|
82
|
+
#
|
|
83
|
+
# Failure handling is deliberate: if the snapshot cannot be built, the gate
|
|
84
|
+
# falls back to the old worktree scan and SAYS SO, rather than skipping. A
|
|
85
|
+
# check that quietly stops checking is the #554/#562 lie; a wider-than-intended
|
|
86
|
+
# scope at least still checks something.
|
|
87
|
+
# ---------------------------------------------------------------------------
|
|
88
|
+
GATE_6_STAGED_SNAPSHOT=""
|
|
89
|
+
GATE_6_STAGED_SNAPSHOT_AVAILABLE=0
|
|
90
|
+
|
|
91
|
+
_gate6_snapshot() {
|
|
92
|
+
local _tree _commit
|
|
93
|
+
_tree=$(git -C "$PROJECT_ROOT" write-tree 2>/dev/null) || return 1
|
|
94
|
+
[ -n "$_tree" ] || return 1
|
|
95
|
+
# No parent: the content is all archlint reads, and a parentless commit
|
|
96
|
+
# cannot be confused with a real one if the object ever surfaces.
|
|
97
|
+
_commit=$(git -C "$PROJECT_ROOT" commit-tree "$_tree" -m "xp-gate: staged snapshot for Gate 6" 2>/dev/null) || return 1
|
|
98
|
+
[ -n "$_commit" ] || return 1
|
|
99
|
+
GATE_6_STAGED_SNAPSHOT="$_commit"
|
|
100
|
+
GATE_6_STAGED_SNAPSHOT_AVAILABLE=1
|
|
101
|
+
return 0
|
|
102
|
+
}
|
|
103
|
+
|
|
53
104
|
# Check if architecture config exists (use $PROJECT_ROOT — hook may have cd'd to a subdir via ARCH-03)
|
|
54
105
|
if [ -f "$PROJECT_ROOT/architecture.yaml" ] || [ -f "$PROJECT_ROOT/.architecturerc" ] || [ -f "$PROJECT_ROOT/.archlint.yaml" ]; then
|
|
55
106
|
# #686: an `architecture.yaml` is NOT evidence that layer boundaries are
|
|
@@ -189,8 +240,48 @@ else
|
|
|
189
240
|
ARCHLINT_OUTPUT=""
|
|
190
241
|
ARCHLINT_EXIT=0
|
|
191
242
|
elif [ -f "$PROJECT_ROOT/.architecture-baseline.json" ]; then
|
|
192
|
-
|
|
193
|
-
|
|
243
|
+
# Scope the verdict to the COMMIT under review (see _gate6_snapshot).
|
|
244
|
+
if _gate6_snapshot; then
|
|
245
|
+
echo " 🔍 Scope: staged content (commit snapshot $(printf '%s' "$GATE_6_STAGED_SNAPSHOT" | cut -c1-8))"
|
|
246
|
+
ARCHLINT_OUTPUT=$(run_archlint diff .architecture-baseline.json "$GATE_6_STAGED_SNAPSHOT" --fail-on high 2>&1)
|
|
247
|
+
ARCHLINT_EXIT=$?
|
|
248
|
+
# #822: a snapshot that CANNOT BE ANALYSED is not a verdict.
|
|
249
|
+
#
|
|
250
|
+
# archlint analyzes a ref by creating a temporary worktree, and that
|
|
251
|
+
# step fails on its own: measured 2026-11-16, mid-commit, with other
|
|
252
|
+
# git processes holding the repo --
|
|
253
|
+
# error: Git command error: Failed to create worktree:
|
|
254
|
+
# fatal: Unable to create 'C:/Users/think/AppData/Local/Tem...'
|
|
255
|
+
# The exit code is non-zero for that, so the verdict branch below
|
|
256
|
+
# read it as "architecture violations detected" and printed advice to
|
|
257
|
+
# re-snapshot the baseline -- i.e. the tool never ran, and the gate
|
|
258
|
+
# blamed the author's code for it.
|
|
259
|
+
#
|
|
260
|
+
# Degrade to the worktree scan, exactly like a snapshot that could not
|
|
261
|
+
# be BUILT, and say so. Falling through to "violations" would be a
|
|
262
|
+
# false accusation; skipping silently would be a false pass.
|
|
263
|
+
#
|
|
264
|
+
# Matched on the MESSAGE, not on the exit code: measured 2026-11-16,
|
|
265
|
+
# archlint exits **1** for "Cannot resolve '<sha>'" and for
|
|
266
|
+
# "Failed to create worktree" alike, which is the same code it uses
|
|
267
|
+
# for real violations. There is no exit-code channel to tell "the
|
|
268
|
+
# analysis never ran" from "the analysis found problems", so the
|
|
269
|
+
# error text is the only usable signal. The project's exit>=2
|
|
270
|
+
# convention would be the right shape here, but archlint does not
|
|
271
|
+
# honour it and this gate cannot change that.
|
|
272
|
+
if printf '%s' "$ARCHLINT_OUTPUT" | grep -qE 'Failed to create worktree|Cannot resolve|Git command error'; then
|
|
273
|
+
echo " ⚠️ [WARN:SNAPSHOT_UNREADABLE] archlint could not materialise the snapshot worktree — retrying against the working tree."
|
|
274
|
+
ARCHLINT_OUTPUT=$(run_archlint diff .architecture-baseline.json --fail-on high 2>&1)
|
|
275
|
+
ARCHLINT_EXIT=$?
|
|
276
|
+
fi
|
|
277
|
+
else
|
|
278
|
+
# Snapshot unavailable (e.g. no git, or a read-only index). Fall back
|
|
279
|
+
# to the worktree scan rather than skipping: a wider scope still
|
|
280
|
+
# checks something, whereas a silent skip checks nothing.
|
|
281
|
+
echo " ⚠️ [WARN:SCOPED_TO_WORKTREE] could not snapshot the index — the verdict below covers the working tree, including uncommitted files that are NOT part of this commit."
|
|
282
|
+
ARCHLINT_OUTPUT=$(run_archlint diff .architecture-baseline.json --fail-on high 2>&1)
|
|
283
|
+
ARCHLINT_EXIT=$?
|
|
284
|
+
fi
|
|
194
285
|
else
|
|
195
286
|
ARCHLINT_OUTPUT=$(run_archlint scan . -f table --quiet 2>&1)
|
|
196
287
|
ARCHLINT_EXIT=$?
|
|
@@ -26,6 +26,13 @@
|
|
|
26
26
|
# stop: see scripts/wrap-gate-entries.cjs for why the two are equivalent
|
|
27
27
|
# here, and why sub-shell exits are deliberately left as `exit`.
|
|
28
28
|
gate_7_run() {
|
|
29
|
+
if ! gate_enabled 7; then
|
|
30
|
+
echo "⏭️ SKIPPED - Gate 7: IaC security (not selected by XP_GATE_ONLY_GATE)"
|
|
31
|
+
GATE_7_STATUS="SKIP"
|
|
32
|
+
GATE_7_DETAIL="not_selected"
|
|
33
|
+
return 0
|
|
34
|
+
fi
|
|
35
|
+
|
|
29
36
|
if any_changed_files_match "\.tf$" "\.tfvars$" "Dockerfile" "\.kube/" "\.ya?ml$"; then
|
|
30
37
|
source "$GATE_DIR/gate-7.sh"
|
|
31
38
|
else
|
|
@@ -24,6 +24,13 @@
|
|
|
24
24
|
# stop: see scripts/wrap-gate-entries.cjs for why the two are equivalent
|
|
25
25
|
# here, and why sub-shell exits are deliberately left as `exit`.
|
|
26
26
|
gate_8_run() {
|
|
27
|
+
if ! gate_enabled 8; then
|
|
28
|
+
echo "⏭️ SKIPPED - Gate 8: Secret scanning (not selected by XP_GATE_ONLY_GATE)"
|
|
29
|
+
GATE_8_STATUS="SKIP"
|
|
30
|
+
GATE_8_DETAIL="not_selected"
|
|
31
|
+
return 0
|
|
32
|
+
fi
|
|
33
|
+
|
|
27
34
|
source "$GATE_DIR/gate-8.sh"
|
|
28
35
|
return 0
|
|
29
36
|
}
|
|
@@ -30,6 +30,13 @@ gate_9_run() {
|
|
|
30
30
|
# project" -- which is exactly the silent-no-coverage path this sprint
|
|
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
|
+
if ! gate_enabled 9; then
|
|
34
|
+
echo "⏭️ SKIPPED - Gate 9: Build integrity (not selected by XP_GATE_ONLY_GATE)"
|
|
35
|
+
GATE_9_STATUS="SKIP"
|
|
36
|
+
GATE_9_DETAIL="not_selected"
|
|
37
|
+
return 0
|
|
38
|
+
fi
|
|
39
|
+
|
|
33
40
|
resolve_build_integrity_timeout() {
|
|
34
41
|
local file=".xp-gate/build-integrity-timeout" val=""
|
|
35
42
|
if [ -f "$file" ]; then
|
package/mock-policy/AGENTS.md
CHANGED
|
@@ -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.
|
|
6
|
+
**Version:** 0.38.7.0
|
|
7
7
|
|
|
8
8
|
## OVERVIEW
|
|
9
9
|
Mock layering policy enforcement — Gate M3 of pre-push hook. Ensures integration tests use real implementations for internal dependencies, mock external dependencies, and annotate pending mocks with removal plans. Combines project scope scanning, mock decision engine, and per-file validation into a single pipeline.
|
package/mutation/AGENTS.md
CHANGED
|
@@ -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.
|
|
6
|
+
**Version:** 0.38.7.0
|
|
7
7
|
|
|
8
8
|
## OVERVIEW
|
|
9
9
|
**Gate M** (incremental mutation testing) + **Gate M2** helpers (test-layer detection used by `src/mock-policy/`). Pre-push quality gate. TypeScript-only; uses Stryker.
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "xp-gate",
|
|
3
|
-
"version": "0.38.
|
|
3
|
+
"version": "0.38.7",
|
|
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.
|
|
6
|
+
**Version:** 0.38.7.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.
|
|
6
|
+
**Version:** 0.38.7.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, 40-67% token savings vs parallel). 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.
|
|
6
|
+
**Version:** 0.38.7.0
|
|
7
7
|
|
|
8
8
|
## OVERVIEW
|
|
9
9
|
Test-Specification Alignment Engine — two-stage validation ensuring tests accurately reflect requirements and design specs.
|
package/plugins/dsh/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@boyingliu01/dsh-plugin-xp-gate",
|
|
3
|
-
"version": "0.38.
|
|
3
|
+
"version": "0.38.7",
|
|
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.
|
|
6
|
+
**Version:** 0.38.7.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.
|
|
6
|
+
**Version:** 0.38.7.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, 40-67% token savings vs parallel). 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.
|
|
6
|
+
**Version:** 0.38.7.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.
|
|
6
|
+
**Version:** 0.38.7.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.
|
|
6
|
+
**Version:** 0.38.7.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, 40-67% token savings vs parallel). 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.
|
|
6
|
+
**Version:** 0.38.7.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.
|
|
3
|
+
"version": "0.38.7",
|
|
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.
|
|
6
|
+
**Version:** 0.38.7.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.
|
|
6
|
+
**Version:** 0.38.7.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, 40-67% token savings vs parallel). 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.
|
|
6
|
+
**Version:** 0.38.7.0
|
|
7
7
|
|
|
8
8
|
## OVERVIEW
|
|
9
9
|
Test-Specification Alignment Engine — two-stage validation ensuring tests accurately reflect requirements and design specs.
|
package/principles/AGENTS.md
CHANGED
|
@@ -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.
|
|
6
|
+
**Version:** 0.38.7.0
|
|
7
7
|
|
|
8
8
|
## OVERVIEW
|
|
9
9
|
Clean Code & SOLID principles checker — **Gate 4** of pre-commit. 14 rules × 9 language adapters, SARIF 2.1.0 output. Houses the **Boy Scout Rule** enforcement engine (Gate 6) and warning-baseline storage.
|
package/principles/analyzer.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { Rule, Violation, Adapter } from './types';
|
|
2
|
-
import { getActiveConfig } from './config';
|
|
2
|
+
import { getActiveConfig, resolveSeverityForFile } from './config';
|
|
3
3
|
import { TypeScriptAdapter } from './adapters/typescript';
|
|
4
4
|
import { PythonAdapter } from './adapters/python';
|
|
5
5
|
import { GoAdapter } from './adapters/go';
|
|
@@ -129,6 +129,17 @@ function runRuleOnFile(ctx: RunRuleContext): void {
|
|
|
129
129
|
try {
|
|
130
130
|
const ruleViolations = rule.check(file, adapter);
|
|
131
131
|
if (ruleViolations.length > 0) {
|
|
132
|
+
// Path-scoped severity overrides (#806), applied centrally so no rule has
|
|
133
|
+
// to know about them and a new rule cannot forget to honour them. Only the
|
|
134
|
+
// severity is remapped -- the violation is kept, so "reported but advisory"
|
|
135
|
+
// stays distinguishable from "nothing found".
|
|
136
|
+
for (const violation of ruleViolations) {
|
|
137
|
+
violation.severity = resolveSeverityForFile(
|
|
138
|
+
rule.id,
|
|
139
|
+
violation.file || file,
|
|
140
|
+
violation.severity
|
|
141
|
+
) as Violation['severity'];
|
|
142
|
+
}
|
|
132
143
|
violations.push(...ruleViolations);
|
|
133
144
|
fileResult.violations.push(...ruleViolations);
|
|
134
145
|
fileResult.ruleIds.push(rule.id);
|