@codyswann/lisa 4.23.3 → 4.23.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/lib/process-tree-runner.mjs +1 -1
- package/all/copy-overwrite/scripts/lisa-hooks/block-no-verify.sh +75 -2
- package/all/copy-overwrite/scripts/lisa-reconcile-policy.mjs +22 -8
- package/dist/cli/doctor-nightly-e2e-guard-graph.d.ts.map +1 -1
- package/dist/cli/doctor-nightly-e2e-guard-graph.js +35 -6
- package/dist/cli/doctor-nightly-e2e-guard-graph.js.map +1 -1
- package/dist/codex/scripts/block-no-verify.sh +63 -0
- package/dist/core/lisa-owned-hash-ledger.d.ts.map +1 -1
- package/dist/core/lisa-owned-hash-ledger.js +18 -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 +11 -10
- package/dist/core/upstream-evidence-manifest.js.map +1 -1
- package/dist/opencode/plugin-templates/block-no-verify.sh +75 -2
- package/dist/opencode/plugin-templates/lisa-block-direct-issue-create.ts +17 -7
- package/package.json +3 -3
- package/plugins/lisa/.claude-plugin/plugin.json +1 -1
- package/plugins/lisa/.codex-plugin/plugin.json +1 -1
- package/plugins/lisa/.codex-plugin/skills/lisa-github-sync/SKILL.md +4 -3
- package/plugins/lisa/.codex-plugin/skills/lisa-jira-journey/scripts/parse-plan.py +3 -1
- package/plugins/lisa/.codex-plugin/skills/lisa-setup-remote-env/scripts/setup-remote-env.mjs +34 -6
- package/plugins/lisa/hooks/block-no-verify.agy.sh +63 -0
- package/plugins/lisa/hooks/block-no-verify.sh +75 -2
- package/plugins/lisa/skills/lisa-github-sync/SKILL.md +4 -3
- package/plugins/lisa/skills/lisa-jira-journey/scripts/parse-plan.py +3 -1
- package/plugins/lisa/skills/lisa-setup-remote-env/scripts/setup-remote-env.mjs +34 -6
- package/plugins/lisa-agy/hooks/block-no-verify.agy.sh +63 -0
- package/plugins/lisa-agy/plugin.json +1 -1
- package/plugins/lisa-agy/skills/lisa-github-sync/SKILL.md +4 -3
- package/plugins/lisa-agy/skills/lisa-jira-journey/scripts/parse-plan.py +3 -1
- package/plugins/lisa-agy/skills/lisa-setup-remote-env/scripts/setup-remote-env.mjs +34 -6
- 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/hooks/block-no-verify.sh +75 -2
- package/plugins/lisa-copilot/skills/lisa-github-sync/SKILL.md +4 -3
- package/plugins/lisa-copilot/skills/lisa-jira-journey/scripts/parse-plan.py +3 -1
- package/plugins/lisa-copilot/skills/lisa-setup-remote-env/scripts/setup-remote-env.mjs +34 -6
- package/plugins/lisa-cursor/.claude-plugin/plugin.json +1 -1
- package/plugins/lisa-cursor/hooks/block-no-verify.sh +75 -2
- package/plugins/lisa-cursor/skills/lisa-github-sync/SKILL.md +4 -3
- package/plugins/lisa-cursor/skills/lisa-jira-journey/scripts/parse-plan.py +3 -1
- package/plugins/lisa-cursor/skills/lisa-setup-remote-env/scripts/setup-remote-env.mjs +34 -6
- 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/hooks/block-no-verify.agy.sh +63 -0
- package/plugins/src/base/hooks/block-no-verify.sh +75 -2
- package/plugins/src/base/skills/lisa-github-sync/SKILL.md +4 -3
- package/plugins/src/base/skills/lisa-jira-journey/scripts/parse-plan.py +3 -1
- package/plugins/src/base/skills/lisa-setup-remote-env/scripts/setup-remote-env.mjs +34 -6
- package/typescript/copy-overwrite/scripts/check-skipped-required-checks.mjs +2 -2
- package/typescript/copy-overwrite/scripts/lisa-mutation.mjs +91 -13
|
@@ -161,6 +161,14 @@ COMMAND_SEPARATORS = {
|
|
|
161
161
|
";", "|", "||", "&", "&&", "(", ")", "<", ">", ">>", "<<", "&|",
|
|
162
162
|
}
|
|
163
163
|
|
|
164
|
+
ENV_OPTIONS_NO_VALUE = {
|
|
165
|
+
"-i", "--ignore-environment", "-0", "--null", "-v", "--debug",
|
|
166
|
+
}
|
|
167
|
+
ENV_OPTIONS_SEPARATE_VALUE = {
|
|
168
|
+
"-u", "--unset", "-C", "--chdir", "-a", "--argv0",
|
|
169
|
+
}
|
|
170
|
+
ENV_OPTIONS_INLINE_VALUE = ("--unset=", "--chdir=", "--argv0=")
|
|
171
|
+
|
|
164
172
|
# git's own options taking a SEPARATE value token, skipped when looking for the
|
|
165
173
|
# subcommand so `git -c core.hooksPath=x commit` still reaches `commit`.
|
|
166
174
|
GIT_GLOBAL_SEPARATE_VALUE = {
|
|
@@ -302,6 +310,56 @@ def subcommand_after_git(tokens, start):
|
|
|
302
310
|
return None
|
|
303
311
|
|
|
304
312
|
|
|
313
|
+
def env_short_option_uses_split_string(token):
|
|
314
|
+
"""Whether one GNU env short-option cluster enables split-string."""
|
|
315
|
+
if not token.startswith("-") or token.startswith("--") or token == "-":
|
|
316
|
+
return False
|
|
317
|
+
for letter in token[1:]:
|
|
318
|
+
if letter == "S":
|
|
319
|
+
return True
|
|
320
|
+
if letter in {"u", "C", "a"}:
|
|
321
|
+
# The rest of this token is the option's value, not more options.
|
|
322
|
+
return False
|
|
323
|
+
if letter not in {"i", "0", "v"}:
|
|
324
|
+
return False
|
|
325
|
+
return False
|
|
326
|
+
|
|
327
|
+
|
|
328
|
+
def env_uses_split_string(tokens, index):
|
|
329
|
+
"""Whether a command-position env invocation reparses an opaque payload."""
|
|
330
|
+
start = index - 1
|
|
331
|
+
while start >= 0 and tokens[start] not in COMMAND_SEPARATORS:
|
|
332
|
+
start -= 1
|
|
333
|
+
prefix = tokens[start + 1:index]
|
|
334
|
+
if not all("=" in token and not token.startswith("=") for token in prefix):
|
|
335
|
+
return False
|
|
336
|
+
|
|
337
|
+
cursor = index + 1
|
|
338
|
+
while cursor < len(tokens):
|
|
339
|
+
token = tokens[cursor]
|
|
340
|
+
if token in COMMAND_SEPARATORS or token == "--":
|
|
341
|
+
return False
|
|
342
|
+
if (
|
|
343
|
+
token in {"-S", "--split-string"}
|
|
344
|
+
or token.startswith("--split-string=")
|
|
345
|
+
or env_short_option_uses_split_string(token)
|
|
346
|
+
):
|
|
347
|
+
return True
|
|
348
|
+
if "=" in token and not token.startswith(("=", "-")):
|
|
349
|
+
cursor += 1
|
|
350
|
+
continue
|
|
351
|
+
if token in ENV_OPTIONS_NO_VALUE or token.startswith(
|
|
352
|
+
ENV_OPTIONS_INLINE_VALUE
|
|
353
|
+
):
|
|
354
|
+
cursor += 1
|
|
355
|
+
continue
|
|
356
|
+
if token in ENV_OPTIONS_SEPARATE_VALUE:
|
|
357
|
+
cursor += 2
|
|
358
|
+
continue
|
|
359
|
+
return False
|
|
360
|
+
return False
|
|
361
|
+
|
|
362
|
+
|
|
305
363
|
def git_commit_skips_verification(text):
|
|
306
364
|
"""Whether the command runs `git commit` with the short `-n` bypass.
|
|
307
365
|
|
|
@@ -315,6 +373,11 @@ def git_commit_skips_verification(text):
|
|
|
315
373
|
scoped_tokens = shell_tokens(text)
|
|
316
374
|
except ValueError:
|
|
317
375
|
return False
|
|
376
|
+
for index, token in enumerate(scoped_tokens):
|
|
377
|
+
if token.rsplit("/", 1)[-1] == "env" and env_uses_split_string(
|
|
378
|
+
scoped_tokens, index
|
|
379
|
+
):
|
|
380
|
+
return True
|
|
318
381
|
for index, token in enumerate(scoped_tokens):
|
|
319
382
|
# `/usr/bin/git` and a bare `git` are the same program; an env prefix
|
|
320
383
|
# (`HUSKY=1 git commit -n`) simply sits in an earlier token.
|
|
@@ -110,7 +110,8 @@ If the `subIssues` field is unavailable (older GHES), fall back to body parentag
|
|
|
110
110
|
| else any child has **started** (`status:in-progress`, or shipped to an env while a sibling has not) | `claimed` | `status:in-progress` |
|
|
111
111
|
| else (children exist, none started) | — | unchanged — parent keeps its non-ready container label |
|
|
112
112
|
|
|
113
|
-
- **Blocked dominates — and the rollup must say which child and which kind** — a single blocked child surfaces `status:blocked` on the parent even while siblings progress, so a human sees the parent needs attention. `status:blocked` alone is a single bit and cannot tell a child waiting on an external event from one whose acceptance criteria are unbuildable; the second never clears on its own.
|
|
113
|
+
- **Blocked dominates — and the rollup must say which child and which kind** — a single blocked child surfaces `status:blocked` on the parent even while siblings progress, so a human sees the parent needs attention. `status:blocked` alone is a single bit and cannot tell a child waiting on an external event from one whose acceptance criteria are unbuildable; the second never clears on its own.
|
|
114
|
+
- **Run the shared classifier for every derived rollup state before writing the label or comment**, not only for `status:blocked`. Include the exact rendered state and child tally in the classifier input alongside the resolved child graph, so its fingerprint and `change.summary` deduplicate the complete rollup note for `status:in-progress`, every env-keyed `done`, and `status:blocked` alike:
|
|
114
115
|
|
|
115
116
|
```bash
|
|
116
117
|
CLASSIFIER_ROOT="${CLAUDE_PLUGIN_ROOT:-${PLUGIN_ROOT:-plugins/lisa}}"
|
|
@@ -121,7 +122,7 @@ The current-directory `plugins/lisa` fallback is for a Lisa checkout where no
|
|
|
121
122
|
plugin-root variable is injected; it must be tried before declaring the shared
|
|
122
123
|
classifier absent.
|
|
123
124
|
|
|
124
|
-
|
|
125
|
+
When the derived state is blocked, its report names, per class, the blocking leaf, the path to it (`#1495 -> #1515 -> #1547`) and **who must act** — that text goes in the rollup comment verbatim. It exits non-zero when it classified nothing (unreadable graph, no children, no readable child): that is a strict **no-write** result. Do not change a label and do not post/update a rollup comment; report the classifier failure to the caller. Never fall through to "no blocked children", infer a class from prose, or apply the `spec_defect` marker from a flow — see `leaf-only-lifecycle` → **Classifying a hold**.
|
|
125
126
|
- **Least-advanced env wins** — the parent reaches an env only when every required child has reached at least that env; it never sits ahead of its laggard child. Native closure (`gh issue close --reason completed`) fires only when the resolved env is the production `status:done`, never at `status:on-dev`/`status:on-stg`.
|
|
126
127
|
- **"Required" children only** — a child labelled won't-do / optional does not hold the parent open; only leaves that must ship count toward the env-rollup check.
|
|
127
128
|
- **Recursive** — a parent reaches an env only when its children have all reached at least that env; an Epic reaches it only when its Stories have themselves rolled up to it. Evaluate bottom-up.
|
|
@@ -129,7 +130,7 @@ classifier absent.
|
|
|
129
130
|
|
|
130
131
|
**Single-environment collapse (this repo).** `.lisa.config.json` `deploy.branches` declares only `production: main`, so the env-keyed `done` resolves to the single label `status:done` — there is no `status:on-dev` / `status:on-stg` and **no dev → staging → prod promotion chain**. Resolve the env rungs via the env-keyed `done` logic in `config-resolution`, but in the single-environment case the only rung is production and it collapses to the one `status:done` value; the rollup never attempts to resolve a dev or staging `done`. Projects that DO have multiple environments keep the env-keyed map and roll the parent up to whichever `done` (including intermediate `status:on-dev`/`status:on-stg`) its leaves have collectively reached.
|
|
131
132
|
|
|
132
|
-
**Apply the derived label** (only when it differs from the parent's current `status:*`): remove the parent's existing `status:*` label and add the derived one, keeping exactly one `status:*` label so the build-queue invariant holds. Re-read the labels immediately after the edit and require exactly one `status:*`; if the count differs, surface an error and stop without trying to normalize the ambiguous set automatically. Post an idempotent `[claude-sync] rollup` comment naming the derived state and the child tally (e.g. `3/4 leaves terminal, 1 blocked → status:blocked`); when the derived state is `status:blocked` the comment also carries the classifier's per-class section, so the blocking child and its actor are one read rather than a descent.
|
|
133
|
+
**Apply the derived label** (only when it differs from the parent's current `status:*`): remove the parent's existing `status:*` label and add the derived one, keeping exactly one `status:*` label so the build-queue invariant holds. Re-read the labels immediately after the edit and require exactly one `status:*`; if the count differs, surface an error and stop without trying to normalize the ambiguous set automatically. Post an idempotent `[claude-sync] rollup` comment naming the derived state and the child tally (e.g. `3/4 leaves terminal, 1 blocked → status:blocked`); when the derived state is `status:blocked` the comment also carries the classifier's per-class section, so the blocking child and its actor are one read rather than a descent. Persist the classifier's `change.fingerprint` with the rollup comment and use `change.changed` as the dedupe decision for every rollup. Use `change.summary` only as display text; it describes the transition and is not a stable key.
|
|
133
134
|
|
|
134
135
|
```bash
|
|
135
136
|
gh issue edit <parent-number> --repo <org>/<repo> \
|
|
@@ -89,9 +89,11 @@ def server_origin(server):
|
|
|
89
89
|
return ""
|
|
90
90
|
if parsed.scheme.lower() != "https" or not parsed.hostname:
|
|
91
91
|
return ""
|
|
92
|
+
if port == 0:
|
|
93
|
+
return ""
|
|
92
94
|
hostname = parsed.hostname.lower()
|
|
93
95
|
authority = f"[{hostname}]" if ":" in hostname else hostname
|
|
94
|
-
if port and port != 443:
|
|
96
|
+
if port is not None and port != 443:
|
|
95
97
|
authority = f"{authority}:{port}"
|
|
96
98
|
return f"https://{authority}"
|
|
97
99
|
|
|
@@ -812,6 +812,7 @@ export function installUserSessionHook(repoRoot, options = {}) {
|
|
|
812
812
|
// Single quotes suppress parameter expansion and command substitution. An
|
|
813
813
|
// embedded quote closes, escapes, and reopens the quoted shell word.
|
|
814
814
|
const command = `bash '${script.replaceAll("'", `'\\''`)}'`;
|
|
815
|
+
const legacyCommand = `bash ${JSON.stringify(script)}`;
|
|
815
816
|
|
|
816
817
|
let settings = {};
|
|
817
818
|
if (exists(settingsPath)) {
|
|
@@ -833,11 +834,38 @@ export function installUserSessionHook(repoRoot, options = {}) {
|
|
|
833
834
|
const sessionStart = Array.isArray(hooks.SessionStart)
|
|
834
835
|
? hooks.SessionStart
|
|
835
836
|
: [];
|
|
836
|
-
|
|
837
|
-
|
|
838
|
-
|
|
839
|
-
|
|
840
|
-
|
|
837
|
+
let installed = false;
|
|
838
|
+
let migrated = false;
|
|
839
|
+
const normalizedSessionStart = sessionStart.flatMap(entry => {
|
|
840
|
+
if (!Array.isArray(entry?.hooks)) return [entry];
|
|
841
|
+
const normalizedHooks = entry.hooks.flatMap(hook => {
|
|
842
|
+
if (hook?.command !== command && hook?.command !== legacyCommand) {
|
|
843
|
+
return [hook];
|
|
844
|
+
}
|
|
845
|
+
if (installed) {
|
|
846
|
+
migrated = true;
|
|
847
|
+
return [];
|
|
848
|
+
}
|
|
849
|
+
installed = true;
|
|
850
|
+
if (hook.command === command) return [hook];
|
|
851
|
+
migrated = true;
|
|
852
|
+
return [{ ...hook, command }];
|
|
853
|
+
});
|
|
854
|
+
return normalizedHooks.length > 0
|
|
855
|
+
? [{ ...entry, hooks: normalizedHooks }]
|
|
856
|
+
: [];
|
|
857
|
+
});
|
|
858
|
+
|
|
859
|
+
if (installed) {
|
|
860
|
+
if (!migrated) return { action: "present", path: settingsPath };
|
|
861
|
+
if (dryRun) return { action: "would-migrate", path: settingsPath };
|
|
862
|
+
const updated = {
|
|
863
|
+
...settings,
|
|
864
|
+
hooks: { ...hooks, SessionStart: normalizedSessionStart },
|
|
865
|
+
};
|
|
866
|
+
mkdir(dir, { recursive: true });
|
|
867
|
+
write(settingsPath, `${JSON.stringify(updated, null, 2)}\n`);
|
|
868
|
+
return { action: "migrated", path: settingsPath };
|
|
841
869
|
}
|
|
842
870
|
|
|
843
871
|
const updated = {
|
|
@@ -845,7 +873,7 @@ export function installUserSessionHook(repoRoot, options = {}) {
|
|
|
845
873
|
hooks: {
|
|
846
874
|
...hooks,
|
|
847
875
|
SessionStart: [
|
|
848
|
-
...
|
|
876
|
+
...normalizedSessionStart,
|
|
849
877
|
{
|
|
850
878
|
matcher: "startup|resume",
|
|
851
879
|
hooks: [{ type: "command", command }],
|
|
@@ -23,7 +23,7 @@
|
|
|
23
23
|
# Add a name here in the same commit that closes a vector. A hardening that
|
|
24
24
|
# forgets to is invisible to refresh, and shows up as an unexplained diff at
|
|
25
25
|
# review time instead of a named capability.
|
|
26
|
-
# lisa-guard-capabilities: no-verify-abbrev, husky-env, hookspath-allowlist, config-env, git-config-key, git-config-parameters, git-config-parameters-append, git-config-parameters-expansion, heredoc-shell-word, herestring-aware, no-verify-short, nested-shell-no-verify
|
|
26
|
+
# lisa-guard-capabilities: no-verify-abbrev, husky-env, hookspath-allowlist, config-env, env-split-string, git-config-key, git-config-parameters, git-config-parameters-append, git-config-parameters-expansion, heredoc-shell-word, herestring-aware, no-verify-short, nested-shell-no-verify
|
|
27
27
|
#
|
|
28
28
|
# Shell-token matching avoids false positives from issue bodies, heredocs, and
|
|
29
29
|
# commit-message prose while still catching quoted real argv values such as
|
|
@@ -222,7 +222,9 @@ MAX_SHELL_NESTING = 8
|
|
|
222
222
|
# Prefix options accepted by `env` before the command name. Value-taking
|
|
223
223
|
# options are separate because their operand must never be mistaken for the
|
|
224
224
|
# command (`env -u bash -c ...` consumes `bash` as the variable name).
|
|
225
|
-
ENV_OPTIONS_NO_VALUE = {
|
|
225
|
+
ENV_OPTIONS_NO_VALUE = {
|
|
226
|
+
"-i", "--ignore-environment", "-0", "--null", "-v", "--debug",
|
|
227
|
+
}
|
|
226
228
|
ENV_OPTIONS_SEPARATE_VALUE = {
|
|
227
229
|
"-u", "--unset", "-C", "--chdir", "-S", "--split-string",
|
|
228
230
|
"-a", "--argv0",
|
|
@@ -427,6 +429,72 @@ def shell_starts_command(tokens, index):
|
|
|
427
429
|
return True
|
|
428
430
|
|
|
429
431
|
|
|
432
|
+
def env_short_option_uses_split_string(token):
|
|
433
|
+
"""Whether one GNU env short-option cluster enables split-string."""
|
|
434
|
+
if not token.startswith("-") or token.startswith("--") or token == "-":
|
|
435
|
+
return False
|
|
436
|
+
for letter in token[1:]:
|
|
437
|
+
if letter == "S":
|
|
438
|
+
return True
|
|
439
|
+
if letter in {"u", "C", "a"}:
|
|
440
|
+
# The rest of this token is the option's value, not more options.
|
|
441
|
+
return False
|
|
442
|
+
if letter not in {"i", "0", "v"}:
|
|
443
|
+
return False
|
|
444
|
+
return False
|
|
445
|
+
|
|
446
|
+
|
|
447
|
+
def env_uses_split_string(tokens, index):
|
|
448
|
+
"""Whether a command-position env invocation uses split-string parsing.
|
|
449
|
+
|
|
450
|
+
`env -S` reparses one opaque argv value as shell-like words. Inspecting the
|
|
451
|
+
outer command cannot prove what executable or nested shell that second
|
|
452
|
+
parse will produce, so the verification guard refuses the ambiguous form.
|
|
453
|
+
|
|
454
|
+
Args:
|
|
455
|
+
tokens: The full operator-aware token list.
|
|
456
|
+
index: Index of the candidate env executable.
|
|
457
|
+
|
|
458
|
+
Returns:
|
|
459
|
+
True when env will reparse a split-string payload.
|
|
460
|
+
"""
|
|
461
|
+
start = index - 1
|
|
462
|
+
while start >= 0 and tokens[start] not in COMMAND_SEPARATORS:
|
|
463
|
+
start -= 1
|
|
464
|
+
prefix = tokens[start + 1:index]
|
|
465
|
+
if not all("=" in token and not token.startswith("=") for token in prefix):
|
|
466
|
+
return False
|
|
467
|
+
|
|
468
|
+
cursor = index + 1
|
|
469
|
+
while cursor < len(tokens):
|
|
470
|
+
token = tokens[cursor]
|
|
471
|
+
if token in COMMAND_SEPARATORS or token == "--":
|
|
472
|
+
return False
|
|
473
|
+
if (
|
|
474
|
+
token in {"-S", "--split-string"}
|
|
475
|
+
or token.startswith("--split-string=")
|
|
476
|
+
or env_short_option_uses_split_string(token)
|
|
477
|
+
):
|
|
478
|
+
return True
|
|
479
|
+
if "=" in token and not token.startswith(("=", "-")):
|
|
480
|
+
cursor += 1
|
|
481
|
+
continue
|
|
482
|
+
if token in ENV_OPTIONS_NO_VALUE or token.startswith(
|
|
483
|
+
tuple(
|
|
484
|
+
option
|
|
485
|
+
for option in ENV_OPTIONS_INLINE_VALUE
|
|
486
|
+
if option != "--split-string="
|
|
487
|
+
)
|
|
488
|
+
):
|
|
489
|
+
cursor += 1
|
|
490
|
+
continue
|
|
491
|
+
if token in ENV_OPTIONS_SEPARATE_VALUE:
|
|
492
|
+
cursor += 2
|
|
493
|
+
continue
|
|
494
|
+
return False
|
|
495
|
+
return False
|
|
496
|
+
|
|
497
|
+
|
|
430
498
|
def nested_shell_payload(tokens, index):
|
|
431
499
|
"""Return a shell `-c` payload, or True when option parsing is ambiguous."""
|
|
432
500
|
cursor = index + 1
|
|
@@ -467,6 +535,11 @@ def git_commit_skips_verification(text, depth=0):
|
|
|
467
535
|
scoped_tokens = shell_tokens(text)
|
|
468
536
|
except ValueError:
|
|
469
537
|
return False
|
|
538
|
+
for index, token in enumerate(scoped_tokens):
|
|
539
|
+
if token.rsplit("/", 1)[-1] == "env" and env_uses_split_string(
|
|
540
|
+
scoped_tokens, index
|
|
541
|
+
):
|
|
542
|
+
return True
|
|
470
543
|
for index, token in enumerate(scoped_tokens):
|
|
471
544
|
# `/usr/bin/git` and a bare `git` are the same program; an env prefix
|
|
472
545
|
# (`HUSKY=1 git commit -n`) simply sits in an earlier token.
|
|
@@ -110,7 +110,8 @@ If the `subIssues` field is unavailable (older GHES), fall back to body parentag
|
|
|
110
110
|
| else any child has **started** (`status:in-progress`, or shipped to an env while a sibling has not) | `claimed` | `status:in-progress` |
|
|
111
111
|
| else (children exist, none started) | — | unchanged — parent keeps its non-ready container label |
|
|
112
112
|
|
|
113
|
-
- **Blocked dominates — and the rollup must say which child and which kind** — a single blocked child surfaces `status:blocked` on the parent even while siblings progress, so a human sees the parent needs attention. `status:blocked` alone is a single bit and cannot tell a child waiting on an external event from one whose acceptance criteria are unbuildable; the second never clears on its own.
|
|
113
|
+
- **Blocked dominates — and the rollup must say which child and which kind** — a single blocked child surfaces `status:blocked` on the parent even while siblings progress, so a human sees the parent needs attention. `status:blocked` alone is a single bit and cannot tell a child waiting on an external event from one whose acceptance criteria are unbuildable; the second never clears on its own.
|
|
114
|
+
- **Run the shared classifier for every derived rollup state before writing the label or comment**, not only for `status:blocked`. Include the exact rendered state and child tally in the classifier input alongside the resolved child graph, so its fingerprint and `change.summary` deduplicate the complete rollup note for `status:in-progress`, every env-keyed `done`, and `status:blocked` alike:
|
|
114
115
|
|
|
115
116
|
```bash
|
|
116
117
|
CLASSIFIER_ROOT="${CLAUDE_PLUGIN_ROOT:-${PLUGIN_ROOT:-plugins/lisa}}"
|
|
@@ -121,7 +122,7 @@ The current-directory `plugins/lisa` fallback is for a Lisa checkout where no
|
|
|
121
122
|
plugin-root variable is injected; it must be tried before declaring the shared
|
|
122
123
|
classifier absent.
|
|
123
124
|
|
|
124
|
-
|
|
125
|
+
When the derived state is blocked, its report names, per class, the blocking leaf, the path to it (`#1495 -> #1515 -> #1547`) and **who must act** — that text goes in the rollup comment verbatim. It exits non-zero when it classified nothing (unreadable graph, no children, no readable child): that is a strict **no-write** result. Do not change a label and do not post/update a rollup comment; report the classifier failure to the caller. Never fall through to "no blocked children", infer a class from prose, or apply the `spec_defect` marker from a flow — see `leaf-only-lifecycle` → **Classifying a hold**.
|
|
125
126
|
- **Least-advanced env wins** — the parent reaches an env only when every required child has reached at least that env; it never sits ahead of its laggard child. Native closure (`gh issue close --reason completed`) fires only when the resolved env is the production `status:done`, never at `status:on-dev`/`status:on-stg`.
|
|
126
127
|
- **"Required" children only** — a child labelled won't-do / optional does not hold the parent open; only leaves that must ship count toward the env-rollup check.
|
|
127
128
|
- **Recursive** — a parent reaches an env only when its children have all reached at least that env; an Epic reaches it only when its Stories have themselves rolled up to it. Evaluate bottom-up.
|
|
@@ -129,7 +130,7 @@ classifier absent.
|
|
|
129
130
|
|
|
130
131
|
**Single-environment collapse (this repo).** `.lisa.config.json` `deploy.branches` declares only `production: main`, so the env-keyed `done` resolves to the single label `status:done` — there is no `status:on-dev` / `status:on-stg` and **no dev → staging → prod promotion chain**. Resolve the env rungs via the env-keyed `done` logic in `config-resolution`, but in the single-environment case the only rung is production and it collapses to the one `status:done` value; the rollup never attempts to resolve a dev or staging `done`. Projects that DO have multiple environments keep the env-keyed map and roll the parent up to whichever `done` (including intermediate `status:on-dev`/`status:on-stg`) its leaves have collectively reached.
|
|
131
132
|
|
|
132
|
-
**Apply the derived label** (only when it differs from the parent's current `status:*`): remove the parent's existing `status:*` label and add the derived one, keeping exactly one `status:*` label so the build-queue invariant holds. Re-read the labels immediately after the edit and require exactly one `status:*`; if the count differs, surface an error and stop without trying to normalize the ambiguous set automatically. Post an idempotent `[claude-sync] rollup` comment naming the derived state and the child tally (e.g. `3/4 leaves terminal, 1 blocked → status:blocked`); when the derived state is `status:blocked` the comment also carries the classifier's per-class section, so the blocking child and its actor are one read rather than a descent.
|
|
133
|
+
**Apply the derived label** (only when it differs from the parent's current `status:*`): remove the parent's existing `status:*` label and add the derived one, keeping exactly one `status:*` label so the build-queue invariant holds. Re-read the labels immediately after the edit and require exactly one `status:*`; if the count differs, surface an error and stop without trying to normalize the ambiguous set automatically. Post an idempotent `[claude-sync] rollup` comment naming the derived state and the child tally (e.g. `3/4 leaves terminal, 1 blocked → status:blocked`); when the derived state is `status:blocked` the comment also carries the classifier's per-class section, so the blocking child and its actor are one read rather than a descent. Persist the classifier's `change.fingerprint` with the rollup comment and use `change.changed` as the dedupe decision for every rollup. Use `change.summary` only as display text; it describes the transition and is not a stable key.
|
|
133
134
|
|
|
134
135
|
```bash
|
|
135
136
|
gh issue edit <parent-number> --repo <org>/<repo> \
|
|
@@ -89,9 +89,11 @@ def server_origin(server):
|
|
|
89
89
|
return ""
|
|
90
90
|
if parsed.scheme.lower() != "https" or not parsed.hostname:
|
|
91
91
|
return ""
|
|
92
|
+
if port == 0:
|
|
93
|
+
return ""
|
|
92
94
|
hostname = parsed.hostname.lower()
|
|
93
95
|
authority = f"[{hostname}]" if ":" in hostname else hostname
|
|
94
|
-
if port and port != 443:
|
|
96
|
+
if port is not None and port != 443:
|
|
95
97
|
authority = f"{authority}:{port}"
|
|
96
98
|
return f"https://{authority}"
|
|
97
99
|
|
|
@@ -812,6 +812,7 @@ export function installUserSessionHook(repoRoot, options = {}) {
|
|
|
812
812
|
// Single quotes suppress parameter expansion and command substitution. An
|
|
813
813
|
// embedded quote closes, escapes, and reopens the quoted shell word.
|
|
814
814
|
const command = `bash '${script.replaceAll("'", `'\\''`)}'`;
|
|
815
|
+
const legacyCommand = `bash ${JSON.stringify(script)}`;
|
|
815
816
|
|
|
816
817
|
let settings = {};
|
|
817
818
|
if (exists(settingsPath)) {
|
|
@@ -833,11 +834,38 @@ export function installUserSessionHook(repoRoot, options = {}) {
|
|
|
833
834
|
const sessionStart = Array.isArray(hooks.SessionStart)
|
|
834
835
|
? hooks.SessionStart
|
|
835
836
|
: [];
|
|
836
|
-
|
|
837
|
-
|
|
838
|
-
|
|
839
|
-
|
|
840
|
-
|
|
837
|
+
let installed = false;
|
|
838
|
+
let migrated = false;
|
|
839
|
+
const normalizedSessionStart = sessionStart.flatMap(entry => {
|
|
840
|
+
if (!Array.isArray(entry?.hooks)) return [entry];
|
|
841
|
+
const normalizedHooks = entry.hooks.flatMap(hook => {
|
|
842
|
+
if (hook?.command !== command && hook?.command !== legacyCommand) {
|
|
843
|
+
return [hook];
|
|
844
|
+
}
|
|
845
|
+
if (installed) {
|
|
846
|
+
migrated = true;
|
|
847
|
+
return [];
|
|
848
|
+
}
|
|
849
|
+
installed = true;
|
|
850
|
+
if (hook.command === command) return [hook];
|
|
851
|
+
migrated = true;
|
|
852
|
+
return [{ ...hook, command }];
|
|
853
|
+
});
|
|
854
|
+
return normalizedHooks.length > 0
|
|
855
|
+
? [{ ...entry, hooks: normalizedHooks }]
|
|
856
|
+
: [];
|
|
857
|
+
});
|
|
858
|
+
|
|
859
|
+
if (installed) {
|
|
860
|
+
if (!migrated) return { action: "present", path: settingsPath };
|
|
861
|
+
if (dryRun) return { action: "would-migrate", path: settingsPath };
|
|
862
|
+
const updated = {
|
|
863
|
+
...settings,
|
|
864
|
+
hooks: { ...hooks, SessionStart: normalizedSessionStart },
|
|
865
|
+
};
|
|
866
|
+
mkdir(dir, { recursive: true });
|
|
867
|
+
write(settingsPath, `${JSON.stringify(updated, null, 2)}\n`);
|
|
868
|
+
return { action: "migrated", path: settingsPath };
|
|
841
869
|
}
|
|
842
870
|
|
|
843
871
|
const updated = {
|
|
@@ -845,7 +873,7 @@ export function installUserSessionHook(repoRoot, options = {}) {
|
|
|
845
873
|
hooks: {
|
|
846
874
|
...hooks,
|
|
847
875
|
SessionStart: [
|
|
848
|
-
...
|
|
876
|
+
...normalizedSessionStart,
|
|
849
877
|
{
|
|
850
878
|
matcher: "startup|resume",
|
|
851
879
|
hooks: [{ type: "command", command }],
|
|
@@ -23,7 +23,7 @@
|
|
|
23
23
|
# Add a name here in the same commit that closes a vector. A hardening that
|
|
24
24
|
# forgets to is invisible to refresh, and shows up as an unexplained diff at
|
|
25
25
|
# review time instead of a named capability.
|
|
26
|
-
# lisa-guard-capabilities: no-verify-abbrev, husky-env, hookspath-allowlist, config-env, git-config-key, git-config-parameters, git-config-parameters-append, git-config-parameters-expansion, heredoc-shell-word, herestring-aware, no-verify-short, nested-shell-no-verify
|
|
26
|
+
# lisa-guard-capabilities: no-verify-abbrev, husky-env, hookspath-allowlist, config-env, env-split-string, git-config-key, git-config-parameters, git-config-parameters-append, git-config-parameters-expansion, heredoc-shell-word, herestring-aware, no-verify-short, nested-shell-no-verify
|
|
27
27
|
#
|
|
28
28
|
# Shell-token matching avoids false positives from issue bodies, heredocs, and
|
|
29
29
|
# commit-message prose while still catching quoted real argv values such as
|
|
@@ -222,7 +222,9 @@ MAX_SHELL_NESTING = 8
|
|
|
222
222
|
# Prefix options accepted by `env` before the command name. Value-taking
|
|
223
223
|
# options are separate because their operand must never be mistaken for the
|
|
224
224
|
# command (`env -u bash -c ...` consumes `bash` as the variable name).
|
|
225
|
-
ENV_OPTIONS_NO_VALUE = {
|
|
225
|
+
ENV_OPTIONS_NO_VALUE = {
|
|
226
|
+
"-i", "--ignore-environment", "-0", "--null", "-v", "--debug",
|
|
227
|
+
}
|
|
226
228
|
ENV_OPTIONS_SEPARATE_VALUE = {
|
|
227
229
|
"-u", "--unset", "-C", "--chdir", "-S", "--split-string",
|
|
228
230
|
"-a", "--argv0",
|
|
@@ -427,6 +429,72 @@ def shell_starts_command(tokens, index):
|
|
|
427
429
|
return True
|
|
428
430
|
|
|
429
431
|
|
|
432
|
+
def env_short_option_uses_split_string(token):
|
|
433
|
+
"""Whether one GNU env short-option cluster enables split-string."""
|
|
434
|
+
if not token.startswith("-") or token.startswith("--") or token == "-":
|
|
435
|
+
return False
|
|
436
|
+
for letter in token[1:]:
|
|
437
|
+
if letter == "S":
|
|
438
|
+
return True
|
|
439
|
+
if letter in {"u", "C", "a"}:
|
|
440
|
+
# The rest of this token is the option's value, not more options.
|
|
441
|
+
return False
|
|
442
|
+
if letter not in {"i", "0", "v"}:
|
|
443
|
+
return False
|
|
444
|
+
return False
|
|
445
|
+
|
|
446
|
+
|
|
447
|
+
def env_uses_split_string(tokens, index):
|
|
448
|
+
"""Whether a command-position env invocation uses split-string parsing.
|
|
449
|
+
|
|
450
|
+
`env -S` reparses one opaque argv value as shell-like words. Inspecting the
|
|
451
|
+
outer command cannot prove what executable or nested shell that second
|
|
452
|
+
parse will produce, so the verification guard refuses the ambiguous form.
|
|
453
|
+
|
|
454
|
+
Args:
|
|
455
|
+
tokens: The full operator-aware token list.
|
|
456
|
+
index: Index of the candidate env executable.
|
|
457
|
+
|
|
458
|
+
Returns:
|
|
459
|
+
True when env will reparse a split-string payload.
|
|
460
|
+
"""
|
|
461
|
+
start = index - 1
|
|
462
|
+
while start >= 0 and tokens[start] not in COMMAND_SEPARATORS:
|
|
463
|
+
start -= 1
|
|
464
|
+
prefix = tokens[start + 1:index]
|
|
465
|
+
if not all("=" in token and not token.startswith("=") for token in prefix):
|
|
466
|
+
return False
|
|
467
|
+
|
|
468
|
+
cursor = index + 1
|
|
469
|
+
while cursor < len(tokens):
|
|
470
|
+
token = tokens[cursor]
|
|
471
|
+
if token in COMMAND_SEPARATORS or token == "--":
|
|
472
|
+
return False
|
|
473
|
+
if (
|
|
474
|
+
token in {"-S", "--split-string"}
|
|
475
|
+
or token.startswith("--split-string=")
|
|
476
|
+
or env_short_option_uses_split_string(token)
|
|
477
|
+
):
|
|
478
|
+
return True
|
|
479
|
+
if "=" in token and not token.startswith(("=", "-")):
|
|
480
|
+
cursor += 1
|
|
481
|
+
continue
|
|
482
|
+
if token in ENV_OPTIONS_NO_VALUE or token.startswith(
|
|
483
|
+
tuple(
|
|
484
|
+
option
|
|
485
|
+
for option in ENV_OPTIONS_INLINE_VALUE
|
|
486
|
+
if option != "--split-string="
|
|
487
|
+
)
|
|
488
|
+
):
|
|
489
|
+
cursor += 1
|
|
490
|
+
continue
|
|
491
|
+
if token in ENV_OPTIONS_SEPARATE_VALUE:
|
|
492
|
+
cursor += 2
|
|
493
|
+
continue
|
|
494
|
+
return False
|
|
495
|
+
return False
|
|
496
|
+
|
|
497
|
+
|
|
430
498
|
def nested_shell_payload(tokens, index):
|
|
431
499
|
"""Return a shell `-c` payload, or True when option parsing is ambiguous."""
|
|
432
500
|
cursor = index + 1
|
|
@@ -467,6 +535,11 @@ def git_commit_skips_verification(text, depth=0):
|
|
|
467
535
|
scoped_tokens = shell_tokens(text)
|
|
468
536
|
except ValueError:
|
|
469
537
|
return False
|
|
538
|
+
for index, token in enumerate(scoped_tokens):
|
|
539
|
+
if token.rsplit("/", 1)[-1] == "env" and env_uses_split_string(
|
|
540
|
+
scoped_tokens, index
|
|
541
|
+
):
|
|
542
|
+
return True
|
|
470
543
|
for index, token in enumerate(scoped_tokens):
|
|
471
544
|
# `/usr/bin/git` and a bare `git` are the same program; an env prefix
|
|
472
545
|
# (`HUSKY=1 git commit -n`) simply sits in an earlier token.
|
|
@@ -110,7 +110,8 @@ If the `subIssues` field is unavailable (older GHES), fall back to body parentag
|
|
|
110
110
|
| else any child has **started** (`status:in-progress`, or shipped to an env while a sibling has not) | `claimed` | `status:in-progress` |
|
|
111
111
|
| else (children exist, none started) | — | unchanged — parent keeps its non-ready container label |
|
|
112
112
|
|
|
113
|
-
- **Blocked dominates — and the rollup must say which child and which kind** — a single blocked child surfaces `status:blocked` on the parent even while siblings progress, so a human sees the parent needs attention. `status:blocked` alone is a single bit and cannot tell a child waiting on an external event from one whose acceptance criteria are unbuildable; the second never clears on its own.
|
|
113
|
+
- **Blocked dominates — and the rollup must say which child and which kind** — a single blocked child surfaces `status:blocked` on the parent even while siblings progress, so a human sees the parent needs attention. `status:blocked` alone is a single bit and cannot tell a child waiting on an external event from one whose acceptance criteria are unbuildable; the second never clears on its own.
|
|
114
|
+
- **Run the shared classifier for every derived rollup state before writing the label or comment**, not only for `status:blocked`. Include the exact rendered state and child tally in the classifier input alongside the resolved child graph, so its fingerprint and `change.summary` deduplicate the complete rollup note for `status:in-progress`, every env-keyed `done`, and `status:blocked` alike:
|
|
114
115
|
|
|
115
116
|
```bash
|
|
116
117
|
CLASSIFIER_ROOT="${CLAUDE_PLUGIN_ROOT:-${PLUGIN_ROOT:-plugins/lisa}}"
|
|
@@ -121,7 +122,7 @@ The current-directory `plugins/lisa` fallback is for a Lisa checkout where no
|
|
|
121
122
|
plugin-root variable is injected; it must be tried before declaring the shared
|
|
122
123
|
classifier absent.
|
|
123
124
|
|
|
124
|
-
|
|
125
|
+
When the derived state is blocked, its report names, per class, the blocking leaf, the path to it (`#1495 -> #1515 -> #1547`) and **who must act** — that text goes in the rollup comment verbatim. It exits non-zero when it classified nothing (unreadable graph, no children, no readable child): that is a strict **no-write** result. Do not change a label and do not post/update a rollup comment; report the classifier failure to the caller. Never fall through to "no blocked children", infer a class from prose, or apply the `spec_defect` marker from a flow — see `leaf-only-lifecycle` → **Classifying a hold**.
|
|
125
126
|
- **Least-advanced env wins** — the parent reaches an env only when every required child has reached at least that env; it never sits ahead of its laggard child. Native closure (`gh issue close --reason completed`) fires only when the resolved env is the production `status:done`, never at `status:on-dev`/`status:on-stg`.
|
|
126
127
|
- **"Required" children only** — a child labelled won't-do / optional does not hold the parent open; only leaves that must ship count toward the env-rollup check.
|
|
127
128
|
- **Recursive** — a parent reaches an env only when its children have all reached at least that env; an Epic reaches it only when its Stories have themselves rolled up to it. Evaluate bottom-up.
|
|
@@ -129,7 +130,7 @@ classifier absent.
|
|
|
129
130
|
|
|
130
131
|
**Single-environment collapse (this repo).** `.lisa.config.json` `deploy.branches` declares only `production: main`, so the env-keyed `done` resolves to the single label `status:done` — there is no `status:on-dev` / `status:on-stg` and **no dev → staging → prod promotion chain**. Resolve the env rungs via the env-keyed `done` logic in `config-resolution`, but in the single-environment case the only rung is production and it collapses to the one `status:done` value; the rollup never attempts to resolve a dev or staging `done`. Projects that DO have multiple environments keep the env-keyed map and roll the parent up to whichever `done` (including intermediate `status:on-dev`/`status:on-stg`) its leaves have collectively reached.
|
|
131
132
|
|
|
132
|
-
**Apply the derived label** (only when it differs from the parent's current `status:*`): remove the parent's existing `status:*` label and add the derived one, keeping exactly one `status:*` label so the build-queue invariant holds. Re-read the labels immediately after the edit and require exactly one `status:*`; if the count differs, surface an error and stop without trying to normalize the ambiguous set automatically. Post an idempotent `[claude-sync] rollup` comment naming the derived state and the child tally (e.g. `3/4 leaves terminal, 1 blocked → status:blocked`); when the derived state is `status:blocked` the comment also carries the classifier's per-class section, so the blocking child and its actor are one read rather than a descent.
|
|
133
|
+
**Apply the derived label** (only when it differs from the parent's current `status:*`): remove the parent's existing `status:*` label and add the derived one, keeping exactly one `status:*` label so the build-queue invariant holds. Re-read the labels immediately after the edit and require exactly one `status:*`; if the count differs, surface an error and stop without trying to normalize the ambiguous set automatically. Post an idempotent `[claude-sync] rollup` comment naming the derived state and the child tally (e.g. `3/4 leaves terminal, 1 blocked → status:blocked`); when the derived state is `status:blocked` the comment also carries the classifier's per-class section, so the blocking child and its actor are one read rather than a descent. Persist the classifier's `change.fingerprint` with the rollup comment and use `change.changed` as the dedupe decision for every rollup. Use `change.summary` only as display text; it describes the transition and is not a stable key.
|
|
133
134
|
|
|
134
135
|
```bash
|
|
135
136
|
gh issue edit <parent-number> --repo <org>/<repo> \
|
|
@@ -89,9 +89,11 @@ def server_origin(server):
|
|
|
89
89
|
return ""
|
|
90
90
|
if parsed.scheme.lower() != "https" or not parsed.hostname:
|
|
91
91
|
return ""
|
|
92
|
+
if port == 0:
|
|
93
|
+
return ""
|
|
92
94
|
hostname = parsed.hostname.lower()
|
|
93
95
|
authority = f"[{hostname}]" if ":" in hostname else hostname
|
|
94
|
-
if port and port != 443:
|
|
96
|
+
if port is not None and port != 443:
|
|
95
97
|
authority = f"{authority}:{port}"
|
|
96
98
|
return f"https://{authority}"
|
|
97
99
|
|