@boyingliu01/xp-gate 0.39.1 → 0.39.3

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 (104) hide show
  1. package/adapters/gate-10.sh +0 -0
  2. package/adapters/gate-12-file-hygiene.sh +0 -0
  3. package/adapters/gate-13-compiler-strictness.sh +0 -0
  4. package/adapters/gate-3.sh +12 -5
  5. package/adapters/gate-4.sh +0 -0
  6. package/adapters/gate-6-layers.sh +0 -0
  7. package/adapters/gate-7.sh +0 -0
  8. package/adapters/gate-8.sh +0 -0
  9. package/gate-12-file-hygiene.sh +0 -0
  10. package/gate-13-compiler-strictness.sh +0 -0
  11. package/gate-3.sh +12 -5
  12. package/gate-6-layers.sh +0 -0
  13. package/gate-registry.sh +0 -0
  14. package/hooks/gate-12-file-hygiene.sh +0 -0
  15. package/hooks/gate-13-compiler-strictness.sh +0 -0
  16. package/hooks/gate-3.sh +12 -5
  17. package/hooks/gate-6-layers.sh +0 -0
  18. package/hooks/gate-driver.sh +0 -0
  19. package/hooks/gate-registry.sh +0 -0
  20. package/package.json +1 -1
  21. package/plugins/claude-code/.claude-plugin/plugin.json +1 -1
  22. package/plugins/claude-code/skills/delphi-review/AGENTS.md +1 -1
  23. package/plugins/claude-code/skills/sprint-flow/AGENTS.md +1 -1
  24. package/plugins/claude-code/skills/test-specification-alignment/AGENTS.md +1 -1
  25. package/plugins/dsh/package.json +1 -1
  26. package/plugins/dsh/skills/delphi-review/AGENTS.md +1 -1
  27. package/plugins/dsh/skills/reinstall-xp-gate/.architecture-skip +8 -0
  28. package/plugins/dsh/skills/reinstall-xp-gate/.github/workflows/test.yml +106 -0
  29. package/plugins/dsh/skills/reinstall-xp-gate/CHANGELOG.md +379 -0
  30. package/plugins/dsh/skills/reinstall-xp-gate/LICENSE +21 -0
  31. package/plugins/dsh/skills/reinstall-xp-gate/QUALITY-OVERVIEW.md +173 -0
  32. package/plugins/dsh/skills/reinstall-xp-gate/README.md +167 -0
  33. package/plugins/dsh/skills/reinstall-xp-gate/SKILL.md +271 -0
  34. package/plugins/dsh/skills/reinstall-xp-gate/TODO.md +253 -0
  35. package/plugins/dsh/skills/reinstall-xp-gate/VERSION +1 -0
  36. package/plugins/dsh/skills/reinstall-xp-gate/package.json +28 -0
  37. package/plugins/dsh/skills/reinstall-xp-gate/scripts/audit.mjs +193 -0
  38. package/plugins/dsh/skills/reinstall-xp-gate/scripts/coverage.mjs +140 -0
  39. package/plugins/dsh/skills/reinstall-xp-gate/scripts/hp-gate.mjs +175 -0
  40. package/plugins/dsh/skills/reinstall-xp-gate/scripts/install.mjs +64 -0
  41. package/plugins/dsh/skills/reinstall-xp-gate/scripts/lib/agent-paths.mjs +67 -0
  42. package/plugins/dsh/skills/reinstall-xp-gate/scripts/lib/agents.mjs +247 -0
  43. package/plugins/dsh/skills/reinstall-xp-gate/scripts/lib/backups.mjs +96 -0
  44. package/plugins/dsh/skills/reinstall-xp-gate/scripts/lib/baseline.mjs +101 -0
  45. package/plugins/dsh/skills/reinstall-xp-gate/scripts/lib/ccn.mjs +124 -0
  46. package/plugins/dsh/skills/reinstall-xp-gate/scripts/lib/delphi.mjs +61 -0
  47. package/plugins/dsh/skills/reinstall-xp-gate/scripts/lib/fs-tree.mjs +108 -0
  48. package/plugins/dsh/skills/reinstall-xp-gate/scripts/lib/gatecheck.mjs +290 -0
  49. package/plugins/dsh/skills/reinstall-xp-gate/scripts/lib/json-file.mjs +37 -0
  50. package/plugins/dsh/skills/reinstall-xp-gate/scripts/lib/mutations.mjs +154 -0
  51. package/plugins/dsh/skills/reinstall-xp-gate/scripts/lib/platform.mjs +92 -0
  52. package/plugins/dsh/skills/reinstall-xp-gate/scripts/lib/probes.mjs +128 -0
  53. package/plugins/dsh/skills/reinstall-xp-gate/scripts/lib/proc.mjs +33 -0
  54. package/plugins/dsh/skills/reinstall-xp-gate/scripts/lib/report.mjs +29 -0
  55. package/plugins/dsh/skills/reinstall-xp-gate/scripts/lib/residue.mjs +188 -0
  56. package/plugins/dsh/skills/reinstall-xp-gate/scripts/lib/selfsync.mjs +75 -0
  57. package/plugins/dsh/skills/reinstall-xp-gate/scripts/lib/skills.mjs +121 -0
  58. package/plugins/dsh/skills/reinstall-xp-gate/scripts/lib/spawn.mjs +181 -0
  59. package/plugins/dsh/skills/reinstall-xp-gate/scripts/lib/testreport.mjs +26 -0
  60. package/plugins/dsh/skills/reinstall-xp-gate/scripts/lib/tools.mjs +238 -0
  61. package/plugins/dsh/skills/reinstall-xp-gate/scripts/lib/util.mjs +33 -0
  62. package/plugins/dsh/skills/reinstall-xp-gate/scripts/lib/verdict.mjs +45 -0
  63. package/plugins/dsh/skills/reinstall-xp-gate/scripts/lib/version.mjs +29 -0
  64. package/plugins/dsh/skills/reinstall-xp-gate/scripts/lib/xp-cli.mjs +66 -0
  65. package/plugins/dsh/skills/reinstall-xp-gate/scripts/mutation.mjs +132 -0
  66. package/plugins/dsh/skills/reinstall-xp-gate/scripts/preflight.mjs +75 -0
  67. package/plugins/dsh/skills/reinstall-xp-gate/scripts/reinstall.mjs +305 -0
  68. package/plugins/dsh/skills/reinstall-xp-gate/scripts/setup-wsl.sh +633 -0
  69. package/plugins/dsh/skills/reinstall-xp-gate/scripts/verify.mjs +239 -0
  70. package/plugins/dsh/skills/reinstall-xp-gate/tests/agents.test.mjs +168 -0
  71. package/plugins/dsh/skills/reinstall-xp-gate/tests/baseline.test.mjs +104 -0
  72. package/plugins/dsh/skills/reinstall-xp-gate/tests/ccn.test.mjs +87 -0
  73. package/plugins/dsh/skills/reinstall-xp-gate/tests/cleanup.test.mjs +128 -0
  74. package/plugins/dsh/skills/reinstall-xp-gate/tests/coverage.test.mjs +69 -0
  75. package/plugins/dsh/skills/reinstall-xp-gate/tests/delphi.test.mjs +78 -0
  76. package/plugins/dsh/skills/reinstall-xp-gate/tests/fixtures.mjs +61 -0
  77. package/plugins/dsh/skills/reinstall-xp-gate/tests/gatecheck-audit.test.mjs +157 -0
  78. package/plugins/dsh/skills/reinstall-xp-gate/tests/gatecheck.test.mjs +57 -0
  79. package/plugins/dsh/skills/reinstall-xp-gate/tests/mutation-anchors.test.mjs +49 -0
  80. package/plugins/dsh/skills/reinstall-xp-gate/tests/proc-contract.test.mjs +58 -0
  81. package/plugins/dsh/skills/reinstall-xp-gate/tests/proc.test.mjs +255 -0
  82. package/plugins/dsh/skills/reinstall-xp-gate/tests/report.test.mjs +66 -0
  83. package/plugins/dsh/skills/reinstall-xp-gate/tests/residue.test.mjs +278 -0
  84. package/plugins/dsh/skills/reinstall-xp-gate/tests/selfsync.test.mjs +70 -0
  85. package/plugins/dsh/skills/reinstall-xp-gate/tests/skills.test.mjs +171 -0
  86. package/plugins/dsh/skills/reinstall-xp-gate/tests/testreport.test.mjs +40 -0
  87. package/plugins/dsh/skills/reinstall-xp-gate/tests/timeout-budgets.test.mjs +38 -0
  88. package/plugins/dsh/skills/reinstall-xp-gate/tests/tools-leaf.test.mjs +323 -0
  89. package/plugins/dsh/skills/reinstall-xp-gate/tests/tools-probe.test.mjs +350 -0
  90. package/plugins/dsh/skills/reinstall-xp-gate/tests/tools.test.mjs +131 -0
  91. package/plugins/dsh/skills/reinstall-xp-gate/tests/util.test.mjs +154 -0
  92. package/plugins/dsh/skills/sprint-flow/AGENTS.md +1 -1
  93. package/plugins/dsh/skills/test-specification-alignment/AGENTS.md +1 -1
  94. package/plugins/opencode/package.json +1 -1
  95. package/plugins/opencode/skills/delphi-review/AGENTS.md +1 -1
  96. package/plugins/opencode/skills/sprint-flow/AGENTS.md +1 -1
  97. package/plugins/opencode/skills/test-specification-alignment/AGENTS.md +1 -1
  98. package/plugins/qoder/plugin.json +1 -1
  99. package/plugins/qoder/skills/delphi-review/AGENTS.md +1 -1
  100. package/plugins/qoder/skills/sprint-flow/AGENTS.md +1 -1
  101. package/plugins/qoder/skills/test-specification-alignment/AGENTS.md +1 -1
  102. package/skills/delphi-review/AGENTS.md +1 -1
  103. package/skills/sprint-flow/AGENTS.md +1 -1
  104. package/skills/test-specification-alignment/AGENTS.md +1 -1
File without changes
File without changes
File without changes
@@ -830,11 +830,18 @@ CC_ISSUES="${CC_VIOLATIONS:-${CC_WARNINGS:-0}}"
830
830
  # the test fails, and `_GATE_STATUS_LIB` becomes the bare `/gate-status.sh` -- not readable,
831
831
  # so `xp_gate_detail_append` is never defined and every caller of it dies with
832
832
  # "command not found". Measured: 70 BATS failures from this one line.
833
- _GATE_STATUS_DIR="$(dirname "${BASH_SOURCE[0]}")"
834
- _GATE_STATUS_LIB="$(cd "$_GATE_STATUS_DIR/../lib" 2>/dev/null && pwd)/gate-status.sh"
835
- if [ ! -r "$_GATE_STATUS_LIB" ]; then
836
- _GATE_STATUS_LIB="$(cd "$_GATE_STATUS_DIR" 2>/dev/null && pwd)/lib/gate-status.sh"
837
- fi
833
+ # Resolve the SOURCE DIRECTORY first, then look for lib/ next to it and above it.
834
+ #
835
+ # `dirname` alone is not enough: bats sources `.../githooks/./gate-3.sh`, whose dirname
836
+ # is `.../githooks/.`, and `cd .../githooks/./../lib` then climbs to `.../lib` -- one
837
+ # level too high. Normalising with `pwd` before joining fixes that, and the `../lib`
838
+ # fallback covers a gate script that lives in adapters/.
839
+ _GATE_STATUS_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" 2>/dev/null && pwd)"
840
+ _GATE_STATUS_LIB=""
841
+ for _gsc_try in "$_GATE_STATUS_DIR/lib/gate-status.sh" "$_GATE_STATUS_DIR/../lib/gate-status.sh"; do
842
+ if [ -r "$_gsc_try" ]; then _GATE_STATUS_LIB="$_gsc_try"; break; fi
843
+ done
844
+ unset _gsc_try
838
845
  if [ -r "$_GATE_STATUS_LIB" ]; then
839
846
  # shellcheck source=/dev/null
840
847
  . "$_GATE_STATUS_LIB"
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
package/gate-3.sh CHANGED
@@ -830,11 +830,18 @@ CC_ISSUES="${CC_VIOLATIONS:-${CC_WARNINGS:-0}}"
830
830
  # the test fails, and `_GATE_STATUS_LIB` becomes the bare `/gate-status.sh` -- not readable,
831
831
  # so `xp_gate_detail_append` is never defined and every caller of it dies with
832
832
  # "command not found". Measured: 70 BATS failures from this one line.
833
- _GATE_STATUS_DIR="$(dirname "${BASH_SOURCE[0]}")"
834
- _GATE_STATUS_LIB="$(cd "$_GATE_STATUS_DIR/../lib" 2>/dev/null && pwd)/gate-status.sh"
835
- if [ ! -r "$_GATE_STATUS_LIB" ]; then
836
- _GATE_STATUS_LIB="$(cd "$_GATE_STATUS_DIR" 2>/dev/null && pwd)/lib/gate-status.sh"
837
- fi
833
+ # Resolve the SOURCE DIRECTORY first, then look for lib/ next to it and above it.
834
+ #
835
+ # `dirname` alone is not enough: bats sources `.../githooks/./gate-3.sh`, whose dirname
836
+ # is `.../githooks/.`, and `cd .../githooks/./../lib` then climbs to `.../lib` -- one
837
+ # level too high. Normalising with `pwd` before joining fixes that, and the `../lib`
838
+ # fallback covers a gate script that lives in adapters/.
839
+ _GATE_STATUS_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" 2>/dev/null && pwd)"
840
+ _GATE_STATUS_LIB=""
841
+ for _gsc_try in "$_GATE_STATUS_DIR/lib/gate-status.sh" "$_GATE_STATUS_DIR/../lib/gate-status.sh"; do
842
+ if [ -r "$_gsc_try" ]; then _GATE_STATUS_LIB="$_gsc_try"; break; fi
843
+ done
844
+ unset _gsc_try
838
845
  if [ -r "$_GATE_STATUS_LIB" ]; then
839
846
  # shellcheck source=/dev/null
840
847
  . "$_GATE_STATUS_LIB"
package/gate-6-layers.sh CHANGED
File without changes
package/gate-registry.sh CHANGED
File without changes
File without changes
File without changes
package/hooks/gate-3.sh CHANGED
@@ -830,11 +830,18 @@ CC_ISSUES="${CC_VIOLATIONS:-${CC_WARNINGS:-0}}"
830
830
  # the test fails, and `_GATE_STATUS_LIB` becomes the bare `/gate-status.sh` -- not readable,
831
831
  # so `xp_gate_detail_append` is never defined and every caller of it dies with
832
832
  # "command not found". Measured: 70 BATS failures from this one line.
833
- _GATE_STATUS_DIR="$(dirname "${BASH_SOURCE[0]}")"
834
- _GATE_STATUS_LIB="$(cd "$_GATE_STATUS_DIR/../lib" 2>/dev/null && pwd)/gate-status.sh"
835
- if [ ! -r "$_GATE_STATUS_LIB" ]; then
836
- _GATE_STATUS_LIB="$(cd "$_GATE_STATUS_DIR" 2>/dev/null && pwd)/lib/gate-status.sh"
837
- fi
833
+ # Resolve the SOURCE DIRECTORY first, then look for lib/ next to it and above it.
834
+ #
835
+ # `dirname` alone is not enough: bats sources `.../githooks/./gate-3.sh`, whose dirname
836
+ # is `.../githooks/.`, and `cd .../githooks/./../lib` then climbs to `.../lib` -- one
837
+ # level too high. Normalising with `pwd` before joining fixes that, and the `../lib`
838
+ # fallback covers a gate script that lives in adapters/.
839
+ _GATE_STATUS_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" 2>/dev/null && pwd)"
840
+ _GATE_STATUS_LIB=""
841
+ for _gsc_try in "$_GATE_STATUS_DIR/lib/gate-status.sh" "$_GATE_STATUS_DIR/../lib/gate-status.sh"; do
842
+ if [ -r "$_gsc_try" ]; then _GATE_STATUS_LIB="$_gsc_try"; break; fi
843
+ done
844
+ unset _gsc_try
838
845
  if [ -r "$_GATE_STATUS_LIB" ]; then
839
846
  # shellcheck source=/dev/null
840
847
  . "$_GATE_STATUS_LIB"
File without changes
File without changes
File without changes
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@boyingliu01/xp-gate",
3
- "version": "0.39.1",
3
+ "version": "0.39.3",
4
4
  "description": "Deterministic quality gates for AI-generated code: 15 gates, Delphi review, sprint flow. Works with Claude Code, OpenCode, Qoder.",
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.39.1",
3
+ "version": "0.39.3",
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.39.1.0
6
+ **Version:** 0.39.3.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.39.1.0
6
+ **Version:** 0.39.3.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.39.1.0
6
+ **Version:** 0.39.3.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.39.1",
3
+ "version": "0.39.3",
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.39.1.0
6
+ **Version:** 0.39.3.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.
@@ -0,0 +1,8 @@
1
+ # xp-gate Gate 6 exemption (documented mechanism: "To skip with warning, create .architecture-skip")
2
+ #
3
+ # WHY: this repository is a portable agent skill, not a layered application.
4
+ # It contains SKILL.md plus flat Node ESM helper scripts under scripts/lib/.
5
+ # There is no import graph to constrain, no layering to enforce, and therefore
6
+ # no architecture.yaml that could be written honestly. Gate 6's own message
7
+ # says it needs "explicit architecture constraints"; declaring none is the
8
+ # truthful state, and the warning keeps that visible rather than hidden.
@@ -0,0 +1,106 @@
1
+ name: test
2
+
3
+ on:
4
+ push:
5
+ branches: [main]
6
+ pull_request:
7
+ schedule:
8
+ # A green suite proves the tests agree with the code on the day it was
9
+ # written. The gate audit below depends on the *installed* xp-gate release,
10
+ # which changes without this repo changing -- hence the weekly run.
11
+ - cron: '0 3 * * 1'
12
+
13
+ # Least privilege: this workflow only reads the repo and runs local commands.
14
+ # Without an explicit block GitHub defaults to write-all, which is CKV2_GHA_1.
15
+ permissions:
16
+ contents: read
17
+
18
+ jobs:
19
+ test:
20
+ name: tests (node ${{ matrix.node }})
21
+ runs-on: ubuntu-latest
22
+ strategy:
23
+ fail-fast: false
24
+ matrix:
25
+ # Node 18 EOL 2025-04-30, Node 20 EOL 2026-04-30: neither gets security
26
+ # patches any more, and setup-node keeps dropping prebuilt EOL releases,
27
+ # which would turn this matrix red for reasons unrelated to this repo.
28
+ # 22 is supported to 2027-04-30, 24 to 2028-04-30, 26 to 2029-04-30.
29
+ node: ['22', '24', '26']
30
+ steps:
31
+ - uses: actions/checkout@11d5960a326750d5838078e36cf38b85af677262 # v4
32
+ - uses: actions/setup-node@49933ea5288caeca8642d1e84afbd3f7d6820020 # v4
33
+ with:
34
+ node-version: ${{ matrix.node }}
35
+ # No `npm install`: the suite uses the built-in node:test runner and has
36
+ # no dependencies. An empty install step would only add a failure mode.
37
+ - run: node --test tests/*.test.mjs
38
+ # The coverage floor Gate 5 enforces locally. Node 22+ prints the numbers;
39
+ # scripts/coverage.mjs translates them to the istanbul artefact the gate
40
+ # reads, so this repo does not need vitest just to satisfy a file shape.
41
+ # Runs on the LTS line only: --experimental-test-coverage is still flagged
42
+ # experimental, and its exact percentages drift between majors, so
43
+ # reporting from a single version keeps the number reproducible.
44
+ - if: matrix.node == '26'
45
+ run: node scripts/coverage.mjs
46
+
47
+ mutation:
48
+ name: mutation gate
49
+ runs-on: ubuntu-latest
50
+ steps:
51
+ - uses: actions/checkout@11d5960a326750d5838078e36cf38b85af677262 # v4
52
+ - uses: actions/setup-node@49933ea5288caeca8642d1e84afbd3f7d6820020 # v4
53
+ with:
54
+ node-version: '26'
55
+ # Fails if any injected defect survives the suite, i.e. if a property this
56
+ # skill exists to guarantee has stopped being tested. See scripts/mutation.mjs.
57
+ - run: node scripts/mutation.mjs
58
+
59
+ hp-gate:
60
+ name: complexity of .mjs sources
61
+ runs-on: ubuntu-latest
62
+ steps:
63
+ - uses: actions/checkout@11d5960a326750d5838078e36cf38b85af677262 # v4
64
+ - uses: actions/setup-node@49933ea5288caeca8642d1e84afbd3f7d6820020 # v4
65
+ with:
66
+ node-version: '26'
67
+ - uses: actions/setup-python@a26af69be951a213d495a4c3e4e4022e16d87065 # v5
68
+ with:
69
+ python-version: '3.12'
70
+ - run: pip install lizard
71
+ # xp-gate's Gate 3 never looks at this repo. Its LIZARD_EXTENSIONS and
72
+ # SEMGREP_EXTENSIONS are /\.(ts|tsx|js|jsx|py|go|java|...)$/ -- neither
73
+ # lists mjs -- so a pure-ESM project reports "no source files to check"
74
+ # and passes Gate 3 on complexity without measuring a single function
75
+ # (xp-gate#732, reproduced: the same code as src/a.js is checked and the
76
+ # same code as src/a.mjs is skipped). hp-gate runs lizard over
77
+ # .mjs/.cjs with the same CCN 5 threshold Gate 3 uses, so the number that
78
+ # would have been checked is now checked here.
79
+ - run: node scripts/hp-gate.mjs
80
+
81
+ gate-audit:
82
+ name: gates actually block
83
+ runs-on: ubuntu-latest
84
+ if: github.event_name == 'schedule' || github.event_name == 'workflow_dispatch'
85
+ steps:
86
+ - uses: actions/checkout@11d5960a326750d5838078e36cf38b85af677262 # v4
87
+ - uses: actions/setup-node@49933ea5288caeca8642d1e84afbd3f7d6820020 # v4
88
+ with:
89
+ node-version: '26'
90
+ - uses: actions/setup-python@a26af69be951a213d495a4c3e4e4022e16d87065 # v5
91
+ with:
92
+ python-version: '3.12'
93
+ - name: Install xp-gate
94
+ run: npm install -g @boyingliu01/xp-gate
95
+ - name: Install gate tools
96
+ run: |
97
+ pip install semgrep lizard
98
+ npm install -g jscpd
99
+ # Gray-box: plant a defect the gate is responsible for catching and require
100
+ # the gate to say so. A gate that passes a dirty tree is broken, and no
101
+ # amount of hash comparison in verify.mjs would reveal it.
102
+ #
103
+ # Skipped on push/PR because it installs a toolchain and runs the real CLI;
104
+ # the point is to catch an upstream regression after it ships, not to gate
105
+ # this repo's own commits.
106
+ - run: node scripts/audit.mjs --gates