@juangcarmona/lighthouse-sdlc 0.8.0 → 0.10.0
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/README.md +13 -1
- package/capabilities.json +5 -1
- package/commands/stage-result.md +1 -1
- package/host-contract.md +52 -0
- package/package.json +4 -2
- package/schemas/capability-catalog.schema.json +2 -2
- package/skills/refine/SKILL.md +3 -3
- package/skills/triage/SKILL.md +2 -0
- package/src/contracts.mjs +27 -0
- package/src/event-router.mjs +10 -0
- package/src/host-contract.mjs +105 -0
- package/src/installation.mjs +11 -0
- package/src/routes.mjs +4 -1
- package/src/sdlc.mjs +11 -5
- package/src/triage.mjs +2 -2
- package/workflows/lighthouse-host.yml +43 -0
- package/workflows/lighthouse-sdlc-implement.lock.yml +14 -19
- package/workflows/lighthouse-sdlc-implement.md +1 -1
- package/workflows/lighthouse-sdlc-integrate.lock.yml +14 -19
- package/workflows/lighthouse-sdlc-integrate.md +1 -1
- package/workflows/lighthouse-sdlc-propose.lock.yml +14 -19
- package/workflows/lighthouse-sdlc-propose.md +1 -1
- package/workflows/lighthouse-sdlc-refine.lock.yml +14 -19
- package/workflows/lighthouse-sdlc-refine.md +1 -1
- package/workflows/lighthouse-sdlc-review.lock.yml +14 -19
- package/workflows/lighthouse-sdlc-review.md +1 -1
- package/workflows/lighthouse-sdlc-router.yml +8 -3
- package/workflows/lighthouse-sdlc-triage.lock.yml +14 -19
- package/workflows/lighthouse-sdlc-triage.md +2 -2
- package/workflows/shared/lighthouse-sdlc-stage.md +11 -15
|
@@ -17,6 +17,10 @@ safe-outputs:
|
|
|
17
17
|
max: 1
|
|
18
18
|
report-as-issue: false
|
|
19
19
|
steps:
|
|
20
|
+
- name: Install the locked consumer packages
|
|
21
|
+
run: npm ci --ignore-scripts
|
|
22
|
+
- name: Check the installed SDLC version
|
|
23
|
+
run: node node_modules/@juangcarmona/lighthouse-sdlc/src/installation.mjs
|
|
20
24
|
- name: Materialize the host input
|
|
21
25
|
shell: bash
|
|
22
26
|
env:
|
|
@@ -24,7 +28,7 @@ steps:
|
|
|
24
28
|
run: |
|
|
25
29
|
set -euo pipefail
|
|
26
30
|
mkdir -p /tmp/gh-aw/agent
|
|
27
|
-
printf '%s\n' "${STAGE_INPUT:-{}}" > /tmp/gh-aw/agent/input.json
|
|
31
|
+
printf '%s\n' "${STAGE_INPUT:-"{}"}" > /tmp/gh-aw/agent/input.json
|
|
28
32
|
- name: Load the previous stage result
|
|
29
33
|
if: inputs.previous-stage != ''
|
|
30
34
|
uses: actions/download-artifact@v8
|
|
@@ -45,27 +49,17 @@ post-steps:
|
|
|
45
49
|
echo "::error::The worker did not produce /tmp/gh-aw/agent/stage-result.json"
|
|
46
50
|
exit 1
|
|
47
51
|
fi
|
|
48
|
-
- name:
|
|
52
|
+
- name: Require completion of the dispatched stage
|
|
49
53
|
if: always()
|
|
50
54
|
shell: bash
|
|
51
55
|
env:
|
|
52
56
|
EXPECTED_STAGE: ${{ env.LIGHTHOUSE_STAGE }}
|
|
57
|
+
EXPECTED_RUN_ID: ${{ inputs.run-id }}
|
|
53
58
|
RESULT_FILE: /tmp/gh-aw/agent/stage-result.json
|
|
54
59
|
run: |
|
|
55
60
|
set -euo pipefail
|
|
56
|
-
node
|
|
57
|
-
|
|
58
|
-
import { readFileSync } from 'node:fs';
|
|
59
|
-
|
|
60
|
-
const stage = process.env.EXPECTED_STAGE;
|
|
61
|
-
const result = JSON.parse(readFileSync(process.env.RESULT_FILE, 'utf8'));
|
|
62
|
-
const contract = JSON.parse(readFileSync('src/packages/sdlc/stages.json', 'utf8'));
|
|
63
|
-
const expected = contract.stages.find((item) => item.id === stage);
|
|
64
|
-
if (!expected || result.stage !== stage || result.gate !== expected.gate) {
|
|
65
|
-
console.error(`stage-result does not match stages.json for ${stage}`);
|
|
66
|
-
process.exit(1);
|
|
67
|
-
}
|
|
68
|
-
NODE
|
|
61
|
+
node node_modules/@juangcarmona/lighthouse-sdlc/src/sdlc.mjs stage-result --input "$RESULT_FILE" \
|
|
62
|
+
--require-complete --stage "$EXPECTED_STAGE" --run-id "$EXPECTED_RUN_ID" --format json
|
|
69
63
|
- name: Upload stage evidence
|
|
70
64
|
if: always()
|
|
71
65
|
uses: actions/upload-artifact@v7
|
|
@@ -79,3 +73,5 @@ post-steps:
|
|
|
79
73
|
# Lighthouse SDLC worker mechanics
|
|
80
74
|
|
|
81
75
|
The host input is in `/tmp/gh-aw/agent/input.json`. If this worker has a previous stage, its validated result is in `/tmp/gh-aw/agent/previous/stage-result.json`.
|
|
76
|
+
|
|
77
|
+
Set `runId` to `${{ inputs.run-id }}`. A worker completes only with `status: passed`, the declared stage and gate, empty `missingEvidence`, `unavailableChecks` and `pendingReview` arrays, and evidence whose status is `passed` or `not-applicable`. Preserve unresolved work in a `ready`, `blocked` or `failed` result; it is uploaded for inspection and fails the worker. Worker completion does not approve a human gate.
|