@codyswann/lisa 4.42.3 → 4.42.5
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/all/copy-overwrite/scripts/check-conflict-markers.mjs +24 -1
- package/dist/core/lisa-owned-hash-ledger.d.ts.map +1 -1
- package/dist/core/lisa-owned-hash-ledger.js +4 -0
- package/dist/core/lisa-owned-hash-ledger.js.map +1 -1
- package/dist/core/nightly-e2e-guard-behavior-certificate.js +2 -2
- package/dist/core/upstream-evidence-manifest.d.ts.map +1 -1
- package/dist/core/upstream-evidence-manifest.js +8 -2
- package/dist/core/upstream-evidence-manifest.js.map +1 -1
- package/dist/opencode/plugin-templates/lisa-block-direct-issue-create.ts +72 -0
- package/package.json +6 -5
- package/plugins/lisa/.claude-plugin/plugin.json +1 -1
- package/plugins/lisa/.codex-plugin/plugin.json +1 -1
- package/plugins/lisa/rules/reference/falsifiable-checks.md +20 -0
- package/plugins/lisa-agy/plugin.json +1 -1
- package/plugins/lisa-cdk/.claude-plugin/plugin.json +1 -1
- package/plugins/lisa-cdk/.codex-plugin/plugin.json +1 -1
- package/plugins/lisa-cdk-agy/plugin.json +1 -1
- package/plugins/lisa-cdk-copilot/.claude-plugin/plugin.json +1 -1
- package/plugins/lisa-cdk-cursor/.claude-plugin/plugin.json +1 -1
- package/plugins/lisa-copilot/.claude-plugin/plugin.json +1 -1
- package/plugins/lisa-copilot/rules/reference/falsifiable-checks.md +20 -0
- package/plugins/lisa-cursor/.claude-plugin/plugin.json +1 -1
- package/plugins/lisa-cursor/rules/falsifiable-checks-reference.mdc +20 -0
- package/plugins/lisa-expo/.claude-plugin/plugin.json +1 -1
- package/plugins/lisa-expo/.codex-plugin/plugin.json +1 -1
- package/plugins/lisa-expo-agy/plugin.json +1 -1
- package/plugins/lisa-expo-copilot/.claude-plugin/plugin.json +1 -1
- package/plugins/lisa-expo-cursor/.claude-plugin/plugin.json +1 -1
- package/plugins/lisa-harper-fabric/.claude-plugin/plugin.json +1 -1
- package/plugins/lisa-harper-fabric/.codex-plugin/plugin.json +1 -1
- package/plugins/lisa-harper-fabric-agy/plugin.json +1 -1
- package/plugins/lisa-harper-fabric-copilot/.claude-plugin/plugin.json +1 -1
- package/plugins/lisa-harper-fabric-cursor/.claude-plugin/plugin.json +1 -1
- package/plugins/lisa-nestjs/.claude-plugin/plugin.json +1 -1
- package/plugins/lisa-nestjs/.codex-plugin/plugin.json +1 -1
- package/plugins/lisa-nestjs-agy/plugin.json +1 -1
- package/plugins/lisa-nestjs-copilot/.claude-plugin/plugin.json +1 -1
- package/plugins/lisa-nestjs-cursor/.claude-plugin/plugin.json +1 -1
- package/plugins/lisa-openclaw/.claude-plugin/plugin.json +1 -1
- package/plugins/lisa-openclaw/.codex-plugin/plugin.json +1 -1
- package/plugins/lisa-openclaw-agy/plugin.json +1 -1
- package/plugins/lisa-openclaw-copilot/.claude-plugin/plugin.json +1 -1
- package/plugins/lisa-openclaw-cursor/.claude-plugin/plugin.json +1 -1
- package/plugins/lisa-phaser/.claude-plugin/plugin.json +1 -1
- package/plugins/lisa-phaser/.codex-plugin/plugin.json +1 -1
- package/plugins/lisa-phaser-agy/plugin.json +1 -1
- package/plugins/lisa-phaser-copilot/.claude-plugin/plugin.json +1 -1
- package/plugins/lisa-phaser-cursor/.claude-plugin/plugin.json +1 -1
- package/plugins/lisa-rails/.claude-plugin/plugin.json +1 -1
- package/plugins/lisa-rails/.codex-plugin/plugin.json +1 -1
- package/plugins/lisa-rails-agy/plugin.json +1 -1
- package/plugins/lisa-rails-copilot/.claude-plugin/plugin.json +1 -1
- package/plugins/lisa-rails-cursor/.claude-plugin/plugin.json +1 -1
- package/plugins/lisa-typescript/.claude-plugin/plugin.json +1 -1
- package/plugins/lisa-typescript/.codex-plugin/plugin.json +1 -1
- package/plugins/lisa-typescript-agy/plugin.json +1 -1
- package/plugins/lisa-typescript-copilot/.claude-plugin/plugin.json +1 -1
- package/plugins/lisa-typescript-cursor/.claude-plugin/plugin.json +1 -1
- package/plugins/lisa-wiki/.claude-plugin/plugin.json +1 -1
- package/plugins/lisa-wiki/.codex-plugin/plugin.json +1 -1
- package/plugins/lisa-wiki-agy/plugin.json +1 -1
- package/plugins/lisa-wiki-copilot/.claude-plugin/plugin.json +1 -1
- package/plugins/lisa-wiki-cursor/.claude-plugin/plugin.json +1 -1
- package/plugins/src/base/rules/reference/falsifiable-checks.md +20 -0
- package/scripts/check-empty-subject-guards.mjs +366 -0
|
@@ -47,6 +47,70 @@
|
|
|
47
47
|
* `.opencode/plugin/`. It is intentionally excluded from this repo's tsconfig
|
|
48
48
|
* and eslint config — it runs under OpenCode's Bun runtime, not here.
|
|
49
49
|
*/
|
|
50
|
+
/**
|
|
51
|
+
* Where one command ends and the next begins.
|
|
52
|
+
*
|
|
53
|
+
* Only used to decide which segment a filename belongs to, never to decide the
|
|
54
|
+
* verdict — the raw command text is still matched whole, so a separator this
|
|
55
|
+
* misses cannot hide a creation.
|
|
56
|
+
*/
|
|
57
|
+
const COMMAND_SEPARATORS = /\|\||&&|[;|&\n]/u;
|
|
58
|
+
|
|
59
|
+
/**
|
|
60
|
+
* Shells whose `-n` means "parse it, execute none of it".
|
|
61
|
+
*/
|
|
62
|
+
const NOEXEC_SHELLS = new Set(["bash", "dash", "ksh", "sh", "zsh"]);
|
|
63
|
+
|
|
64
|
+
/**
|
|
65
|
+
* Whether a command segment is a shell syntax check.
|
|
66
|
+
*
|
|
67
|
+
* ## Why this exists in a guard that otherwise reads raw text
|
|
68
|
+
*
|
|
69
|
+
* CodySwannGT/lisa#3781 found `bash -n <file>` to be the one shape that puts a
|
|
70
|
+
* path in a command position while provably executing nothing, and the
|
|
71
|
+
* canonical guard got it wrong in both directions: a creation-shaped file
|
|
72
|
+
* earned a false refusal, and a file carrying a human-gate marker earned a
|
|
73
|
+
* false ALLOW — adjudicating as "declared" a command that filed nothing. The
|
|
74
|
+
* silent direction is the worse one. CodySwannGT/lisa#3885 found the arm had
|
|
75
|
+
* reached the canonical guard and not this port.
|
|
76
|
+
*
|
|
77
|
+
* The distinction is noexec, not the program: `bash <file>` still runs the file
|
|
78
|
+
* and is still refused.
|
|
79
|
+
*
|
|
80
|
+
* ## Why the LAST shell token, not the first
|
|
81
|
+
*
|
|
82
|
+
* `nice -n 5 bash -n script.sh` is in the canonical guard's own table, and it
|
|
83
|
+
* carries two `-n` flags belonging to different programs. Reading the first
|
|
84
|
+
* token would see `nice`, conclude "not a shell", and follow the file; reading
|
|
85
|
+
* any `-n` anywhere would let `nice -n 5 bash script.sh` masquerade as a syntax
|
|
86
|
+
* check, which is a real bypass. So the shell is located first and only its own
|
|
87
|
+
* options are read.
|
|
88
|
+
* @param segment One command, already split on shell separators.
|
|
89
|
+
* @returns Whether the segment parses a file instead of running it.
|
|
90
|
+
*/
|
|
91
|
+
const isSyntaxCheck = (segment: string): boolean => {
|
|
92
|
+
const tokens = segment
|
|
93
|
+
.trim()
|
|
94
|
+
.split(/[\s'"]+/u)
|
|
95
|
+
.filter(Boolean);
|
|
96
|
+
const shellAt = tokens.reduce(
|
|
97
|
+
(last, token, index) =>
|
|
98
|
+
NOEXEC_SHELLS.has(token.split("/").pop() ?? "") ? index : last,
|
|
99
|
+
-1
|
|
100
|
+
);
|
|
101
|
+
if (shellAt === -1) return false;
|
|
102
|
+
for (const token of tokens.slice(shellAt + 1)) {
|
|
103
|
+
// Options only. The first operand ends the option list, and a path is not
|
|
104
|
+
// an option however it is spelled.
|
|
105
|
+
if (!token.startsWith("-")) return false;
|
|
106
|
+
if (token === "--noexec") return true;
|
|
107
|
+
// `-c` takes a command STRING, so nothing after it is a file this guard
|
|
108
|
+
// should reason about positionally; `-en` is a cluster carrying noexec.
|
|
109
|
+
if (!token.startsWith("--") && token.slice(1).includes("n")) return true;
|
|
110
|
+
}
|
|
111
|
+
return false;
|
|
112
|
+
};
|
|
113
|
+
|
|
50
114
|
export /**
|
|
51
115
|
*
|
|
52
116
|
*/
|
|
@@ -261,6 +325,14 @@ const LisaBlockDirectIssueCreate = async () => {
|
|
|
261
325
|
const found: { path: string; text: string }[] = [];
|
|
262
326
|
const seen = new Set<string>();
|
|
263
327
|
const candidates = text
|
|
328
|
+
.split(COMMAND_SEPARATORS)
|
|
329
|
+
// A syntax check READS its operand and runs not one line of it, so the
|
|
330
|
+
// file it names is not a file this command executes. Dropped per SEGMENT
|
|
331
|
+
// rather than per command, which is what keeps `bash -n x.sh && bash x.sh`
|
|
332
|
+
// refused: the second segment names the same path and is harvested
|
|
333
|
+
// normally. See {@link isSyntaxCheck}.
|
|
334
|
+
.filter(segment => !isSyntaxCheck(segment))
|
|
335
|
+
.join(" ")
|
|
264
336
|
.split(/[\s'"]+/)
|
|
265
337
|
// `curl -d@payload.json` is one word, and the path is the half after the
|
|
266
338
|
// `@`. Both halves are offered rather than guessing which flag it was.
|
package/package.json
CHANGED
|
@@ -57,11 +57,12 @@
|
|
|
57
57
|
"generate:two-channel-couplings": "bun scripts/generate-two-channel-couplings.ts",
|
|
58
58
|
"check:two-channel-couplings": "bun scripts/generate-two-channel-couplings.ts --check",
|
|
59
59
|
"check:deletion-basis": "node scripts/check-deletion-basis.mjs",
|
|
60
|
-
"check:artifacts": "
|
|
60
|
+
"check:artifacts": "failed=''; bun run check:upstream-evidence-manifest || failed=\"$failed upstream-evidence-manifest\"; bun run check:lisa-owned-hash-ledger || failed=\"$failed lisa-owned-hash-ledger\"; bun run check:nightly-guard-certificate || failed=\"$failed nightly-guard-certificate\"; bun run check:two-channel-couplings || failed=\"$failed two-channel-couplings\"; bun run check:deletion-basis || failed=\"$failed deletion-basis\"; if [ -n \"$failed\" ]; then echo \"check:artifacts FAILED, and these are the checks that failed:$failed\"; exit 1; fi; echo \"check:artifacts OK - all 5 generated-artifact checks passed.\"",
|
|
61
61
|
"refresh:upstream-public-commits": "node scripts/generate-upstream-evidence-manifest.mjs --refresh-public-commits",
|
|
62
62
|
"check:rules-pairing": "bash scripts/check-rules-pairing.sh",
|
|
63
63
|
"check:pipeline-status-reads": "node scripts/check-pipeline-status-reads.mjs",
|
|
64
64
|
"check:whole-output-guards": "node scripts/check-whole-output-guards.mjs",
|
|
65
|
+
"check:empty-subject-guards": "node scripts/check-empty-subject-guards.mjs",
|
|
65
66
|
"check:shell-guard-refusals": "bun run build && $npm_execpath run lisa-test-run -- --adapter direct -- node scripts/check-shell-guard-refusal-coverage.mjs",
|
|
66
67
|
"check:workflow-inputs": "node scripts/detect-stale-workflow-inputs.mjs --project . --project typescript/create-only --project rails/create-only --json",
|
|
67
68
|
"check:conflict-markers": "node all/copy-overwrite/scripts/check-conflict-markers.mjs",
|
|
@@ -172,7 +173,7 @@
|
|
|
172
173
|
"zod-validation-error": "^4.0.0"
|
|
173
174
|
},
|
|
174
175
|
"name": "@codyswann/lisa",
|
|
175
|
-
"version": "4.42.
|
|
176
|
+
"version": "4.42.5",
|
|
176
177
|
"description": "Claude Code governance framework that applies guardrails, guidance, and automated enforcement to projects",
|
|
177
178
|
"main": "dist/index.js",
|
|
178
179
|
"exports": {
|
|
@@ -320,7 +321,7 @@
|
|
|
320
321
|
"test": "tests"
|
|
321
322
|
},
|
|
322
323
|
"types": "./dist/index.d.ts",
|
|
323
|
-
"lisaReleaseCommit": "
|
|
324
|
-
"gitHead": "
|
|
325
|
-
"lisaReleaseTag": "v4.42.
|
|
324
|
+
"lisaReleaseCommit": "7dcd62366b431f57ac5954534a121dc8ef8c65ab",
|
|
325
|
+
"gitHead": "7dcd62366b431f57ac5954534a121dc8ef8c65ab",
|
|
326
|
+
"lisaReleaseTag": "v4.42.5"
|
|
326
327
|
}
|
|
@@ -126,6 +126,26 @@ bash -e -o pipefail -c 'node -e "process.exit(1)" | tee /dev/null' -> 1
|
|
|
126
126
|
|
|
127
127
|
`scripts/check-pipeline-status-reads.mjs` sweeps shipped shell scripts and workflow `run:` blocks for the pattern. It reports **how many pipelines it inspected** and exits 2 — not 0 — when that count is zero, because an empty inspection and a clean tree otherwise print the same tick.
|
|
128
128
|
|
|
129
|
+
### A guard that reports OK when its comparison had no subject
|
|
130
|
+
|
|
131
|
+
Not "the guard is wrong" — the guard did not run against anything, and said OK. Six instances were catalogued in one sweep (`#3888`), and this was the one still live:
|
|
132
|
+
|
|
133
|
+
```text
|
|
134
|
+
✓ no leftover conflict markers in 0 tracked files
|
|
135
|
+
```
|
|
136
|
+
|
|
137
|
+
That is a **required push gate** reporting on bytes nobody read. `git ls-files` in a repository with nothing tracked succeeds and prints nothing, so the scan loop ran zero times and the verdict came out the same as a clean tree's. Siblings in the same family: a type gate that compiled 0 of 1375 test files and reported success; a gate runner that recorded PASSED off an exit code, never the output; a review gate that went green off a review that never started.
|
|
138
|
+
|
|
139
|
+
The distinguishing property is always the same. The guard had a **subject count** available and did not check it, or had a **reason string** available and did not read it. So:
|
|
140
|
+
|
|
141
|
+
> **A guard that can report success must be able to state what it examined, and must fail closed when that count is zero.** A subject count of zero is not a pass.
|
|
142
|
+
|
|
143
|
+
A guard with genuinely nothing to do is not the defect — it satisfies the rule by SAYING so (`not-adopted`, `nothing to register`) rather than printing a tick. The defect is a tick that cannot be told apart from a satisfied comparison.
|
|
144
|
+
|
|
145
|
+
#### The executable half
|
|
146
|
+
|
|
147
|
+
`scripts/check-empty-subject-guards.mjs` runs every root-scoped guard against an **empty git repository** and reports any that prints a success line and exits 0 anyway. It measures by executing rather than by reading, because a static heuristic that misses one reports a clean tree — the very failure being swept for. It prints how many guards it probed, how many declare no root override and so could not be, and exits 2 at zero probed.
|
|
148
|
+
|
|
129
149
|
## What a negative result is scoped to
|
|
130
150
|
|
|
131
151
|
A clean result is a statement about what the check can perceive, not about the code. State the boundary:
|
|
@@ -126,6 +126,26 @@ bash -e -o pipefail -c 'node -e "process.exit(1)" | tee /dev/null' -> 1
|
|
|
126
126
|
|
|
127
127
|
`scripts/check-pipeline-status-reads.mjs` sweeps shipped shell scripts and workflow `run:` blocks for the pattern. It reports **how many pipelines it inspected** and exits 2 — not 0 — when that count is zero, because an empty inspection and a clean tree otherwise print the same tick.
|
|
128
128
|
|
|
129
|
+
### A guard that reports OK when its comparison had no subject
|
|
130
|
+
|
|
131
|
+
Not "the guard is wrong" — the guard did not run against anything, and said OK. Six instances were catalogued in one sweep (`#3888`), and this was the one still live:
|
|
132
|
+
|
|
133
|
+
```text
|
|
134
|
+
✓ no leftover conflict markers in 0 tracked files
|
|
135
|
+
```
|
|
136
|
+
|
|
137
|
+
That is a **required push gate** reporting on bytes nobody read. `git ls-files` in a repository with nothing tracked succeeds and prints nothing, so the scan loop ran zero times and the verdict came out the same as a clean tree's. Siblings in the same family: a type gate that compiled 0 of 1375 test files and reported success; a gate runner that recorded PASSED off an exit code, never the output; a review gate that went green off a review that never started.
|
|
138
|
+
|
|
139
|
+
The distinguishing property is always the same. The guard had a **subject count** available and did not check it, or had a **reason string** available and did not read it. So:
|
|
140
|
+
|
|
141
|
+
> **A guard that can report success must be able to state what it examined, and must fail closed when that count is zero.** A subject count of zero is not a pass.
|
|
142
|
+
|
|
143
|
+
A guard with genuinely nothing to do is not the defect — it satisfies the rule by SAYING so (`not-adopted`, `nothing to register`) rather than printing a tick. The defect is a tick that cannot be told apart from a satisfied comparison.
|
|
144
|
+
|
|
145
|
+
#### The executable half
|
|
146
|
+
|
|
147
|
+
`scripts/check-empty-subject-guards.mjs` runs every root-scoped guard against an **empty git repository** and reports any that prints a success line and exits 0 anyway. It measures by executing rather than by reading, because a static heuristic that misses one reports a clean tree — the very failure being swept for. It prints how many guards it probed, how many declare no root override and so could not be, and exits 2 at zero probed.
|
|
148
|
+
|
|
129
149
|
## What a negative result is scoped to
|
|
130
150
|
|
|
131
151
|
A clean result is a statement about what the check can perceive, not about the code. State the boundary:
|
|
@@ -131,6 +131,26 @@ bash -e -o pipefail -c 'node -e "process.exit(1)" | tee /dev/null' -> 1
|
|
|
131
131
|
|
|
132
132
|
`scripts/check-pipeline-status-reads.mjs` sweeps shipped shell scripts and workflow `run:` blocks for the pattern. It reports **how many pipelines it inspected** and exits 2 — not 0 — when that count is zero, because an empty inspection and a clean tree otherwise print the same tick.
|
|
133
133
|
|
|
134
|
+
### A guard that reports OK when its comparison had no subject
|
|
135
|
+
|
|
136
|
+
Not "the guard is wrong" — the guard did not run against anything, and said OK. Six instances were catalogued in one sweep (`#3888`), and this was the one still live:
|
|
137
|
+
|
|
138
|
+
```text
|
|
139
|
+
✓ no leftover conflict markers in 0 tracked files
|
|
140
|
+
```
|
|
141
|
+
|
|
142
|
+
That is a **required push gate** reporting on bytes nobody read. `git ls-files` in a repository with nothing tracked succeeds and prints nothing, so the scan loop ran zero times and the verdict came out the same as a clean tree's. Siblings in the same family: a type gate that compiled 0 of 1375 test files and reported success; a gate runner that recorded PASSED off an exit code, never the output; a review gate that went green off a review that never started.
|
|
143
|
+
|
|
144
|
+
The distinguishing property is always the same. The guard had a **subject count** available and did not check it, or had a **reason string** available and did not read it. So:
|
|
145
|
+
|
|
146
|
+
> **A guard that can report success must be able to state what it examined, and must fail closed when that count is zero.** A subject count of zero is not a pass.
|
|
147
|
+
|
|
148
|
+
A guard with genuinely nothing to do is not the defect — it satisfies the rule by SAYING so (`not-adopted`, `nothing to register`) rather than printing a tick. The defect is a tick that cannot be told apart from a satisfied comparison.
|
|
149
|
+
|
|
150
|
+
#### The executable half
|
|
151
|
+
|
|
152
|
+
`scripts/check-empty-subject-guards.mjs` runs every root-scoped guard against an **empty git repository** and reports any that prints a success line and exits 0 anyway. It measures by executing rather than by reading, because a static heuristic that misses one reports a clean tree — the very failure being swept for. It prints how many guards it probed, how many declare no root override and so could not be, and exits 2 at zero probed.
|
|
153
|
+
|
|
134
154
|
## What a negative result is scoped to
|
|
135
155
|
|
|
136
156
|
A clean result is a statement about what the check can perceive, not about the code. State the boundary:
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "lisa-openclaw",
|
|
3
|
-
"version": "4.42.
|
|
3
|
+
"version": "4.42.5",
|
|
4
4
|
"description": "Connect staff roles to Telegram or Slack via OpenClaw — facilitator/specialist hub-and-spoke routing and repo-coding topics, for Claude Code and Codex",
|
|
5
5
|
"author": {
|
|
6
6
|
"name": "Cody Swann"
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "lisa-openclaw",
|
|
3
|
-
"version": "4.42.
|
|
3
|
+
"version": "4.42.5",
|
|
4
4
|
"description": "Connect staff roles to Telegram or Slack via OpenClaw — facilitator/specialist hub-and-spoke routing and repo-coding topics, across Claude and Codex.",
|
|
5
5
|
"author": {
|
|
6
6
|
"name": "Cody Swann"
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "lisa-openclaw",
|
|
3
|
-
"version": "4.42.
|
|
3
|
+
"version": "4.42.5",
|
|
4
4
|
"description": "Connect staff roles to Telegram or Slack via OpenClaw — facilitator/specialist hub-and-spoke routing and repo-coding topics, for Claude Code and Codex",
|
|
5
5
|
"author": {
|
|
6
6
|
"name": "Cody Swann"
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "lisa-openclaw",
|
|
3
|
-
"version": "4.42.
|
|
3
|
+
"version": "4.42.5",
|
|
4
4
|
"description": "Connect staff roles to Telegram or Slack via OpenClaw — facilitator/specialist hub-and-spoke routing and repo-coding topics, for Claude Code and Codex",
|
|
5
5
|
"author": {
|
|
6
6
|
"name": "Cody Swann"
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "lisa-openclaw",
|
|
3
|
-
"version": "4.42.
|
|
3
|
+
"version": "4.42.5",
|
|
4
4
|
"description": "Connect staff roles to Telegram or Slack via OpenClaw — facilitator/specialist hub-and-spoke routing and repo-coding topics, for Claude Code and Codex",
|
|
5
5
|
"author": {
|
|
6
6
|
"name": "Cody Swann"
|