@mutmutco/cli 4.3.34 → 4.3.36
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/dist/main.cjs +29 -16
- package/package.json +1 -1
package/dist/main.cjs
CHANGED
|
@@ -15617,10 +15617,10 @@ var rollout_plan_default = {
|
|
|
15617
15617
|
note: "The v4.0.0 stamp happens at cut time (D6e #4463); until then the candidate is the origin/development head artifacts (built cli/dist + npm pack), identity proven by dist content hash (D6a)."
|
|
15618
15618
|
},
|
|
15619
15619
|
baseline: {
|
|
15620
|
-
version: "4.3.
|
|
15621
|
-
tag: "v4.3.
|
|
15622
|
-
commit: "
|
|
15623
|
-
npm: "@mutmutco/cli@4.3.
|
|
15620
|
+
version: "4.3.36",
|
|
15621
|
+
tag: "v4.3.36",
|
|
15622
|
+
commit: "6309473a245d",
|
|
15623
|
+
npm: "@mutmutco/cli@4.3.36"
|
|
15624
15624
|
},
|
|
15625
15625
|
exitCriterion: "fleet-n-of-n",
|
|
15626
15626
|
hubOnlyShortcut: "forbidden",
|
|
@@ -15637,14 +15637,14 @@ var rollout_plan_default = {
|
|
|
15637
15637
|
repo: "mutmutco/mmi-hub",
|
|
15638
15638
|
role: "canary",
|
|
15639
15639
|
schedule: "train",
|
|
15640
|
-
v3Target: "v4.3.
|
|
15640
|
+
v3Target: "v4.3.36"
|
|
15641
15641
|
}
|
|
15642
15642
|
],
|
|
15643
15643
|
rollbackTrigger: "Any red inside the post-contract soak window: `devops train gate` FAIL attributable to the v4 doors, Hub endpoint health probe failure, a pre-v4 client admitted instead of receiving actionable HTTP 426, or npm consumer install/doctor failure on the v4-only dist.",
|
|
15644
15644
|
rollback: {
|
|
15645
15645
|
independent: true,
|
|
15646
|
-
mechanism: "npm dist-tag latest -> 4.3.
|
|
15647
|
-
v3Target: "v4.3.
|
|
15646
|
+
mechanism: "npm dist-tag latest -> 4.3.36 and redeploy the Hub Lambda from tag v4.3.36 (6309473a245d); installed clients repair via `mmi-cli doctor`. No other cohort is touched.",
|
|
15647
|
+
v3Target: "v4.3.36 (@mutmutco/cli@4.3.36, tag commit 6309473a245d \u2014 last known-good release carrying the repo-index v4-only contract)"
|
|
15648
15648
|
}
|
|
15649
15649
|
},
|
|
15650
15650
|
{
|
|
@@ -21625,6 +21625,17 @@ async function runTrainDoctor(input) {
|
|
|
21625
21625
|
} catch (e) {
|
|
21626
21626
|
add({ code: "contexts-not-tag-addressable", severity: "blocker", source: "local", title: `required ${stage} check(s) cannot materialize on a tag push (#5428)`, remedy: message(e) });
|
|
21627
21627
|
}
|
|
21628
|
+
if (startBranch) {
|
|
21629
|
+
const tip = await git3(["rev-parse", "--verify", "--quiet", `refs/remotes/origin/${startBranch}`]);
|
|
21630
|
+
const checkRuns = JSON.parse(await train.run("gh", ["api", `repos/${repo}/commits/${tip}/check-runs`, "--jq", TRAIN_CHECK_RUNS_JQ]));
|
|
21631
|
+
const statuses = JSON.parse(await train.run("gh", ["api", `repos/${repo}/commits/${tip}/status`, "--jq", TRAIN_COMMIT_STATUS_JQ]));
|
|
21632
|
+
const observed = required.filter((c) => checkRuns.some((r) => r.name === c) || statuses.some((s) => s.context === c));
|
|
21633
|
+
const red = observed.filter((c) => resolveContextState(c, checkRuns, statuses) === "failed");
|
|
21634
|
+
const inFlight = observed.filter((c) => resolveContextState(c, checkRuns, statuses) === "pending");
|
|
21635
|
+
const at = `${startBranch}@${tip.slice(0, 12)}`;
|
|
21636
|
+
if (red.length) add({ code: "required-check-red", severity: "blocker", source: "origin", title: `required ${stage} check(s) failed on the lane's start branch tip: ${red.join(", ")} at ${at}`, remedy: `--heal never clears this one \u2014 a red trunk needs a fix, not a heal: land the failure's fix on ${startBranch} through a CI-gated PR, then rerun once its run is green (#6461)` });
|
|
21637
|
+
else if (inFlight.length) add({ code: "required-check-red", severity: "warning", source: "origin", title: `required ${stage} check(s) still in flight on the lane's start branch tip: ${inFlight.join(", ")} at ${at}`, remedy: `wait for the run to conclude and rerun \u2014 the tip's verdict is not known yet, and the train would tag before it is` });
|
|
21638
|
+
}
|
|
21628
21639
|
}
|
|
21629
21640
|
} catch (e) {
|
|
21630
21641
|
unverified(`required status checks on ${stage}`, e);
|
|
@@ -25684,13 +25695,13 @@ function invalidateStatuslineBoardCache() {
|
|
|
25684
25695
|
function refuseRateLimited(e, json) {
|
|
25685
25696
|
if (!isRateLimitedError(e)) return false;
|
|
25686
25697
|
if (json) console.log(JSON.stringify(e.receipt));
|
|
25687
|
-
else console.error(`mmi-cli board claim failed: ${e.receipt.message} \u2014 retry: ${e.receipt.retryCommand}`);
|
|
25698
|
+
else console.error(`mmi-cli oracle board claim failed: ${e.receipt.message} \u2014 retry: ${e.receipt.retryCommand}`);
|
|
25688
25699
|
process.exitCode = 1;
|
|
25689
25700
|
return true;
|
|
25690
25701
|
}
|
|
25691
25702
|
function refuseNotClaimable(e, json) {
|
|
25692
25703
|
if (!isNotClaimable(e)) return false;
|
|
25693
|
-
const message2 = `board claim failed: ${e.message}`;
|
|
25704
|
+
const message2 = `oracle board claim failed: ${e.message}`;
|
|
25694
25705
|
if (json) {
|
|
25695
25706
|
console.log(formatErrorEnvelope(message2, {
|
|
25696
25707
|
code: ERROR_CODES.ERR_STATE_CONFLICT,
|
|
@@ -25765,7 +25776,7 @@ function registerBoardCommands(program3) {
|
|
|
25765
25776
|
board.command("read", { isDefault: true }).alias("list").description("read the board and print user-owned, claimable, and taken items").option("--json", "machine-readable output").option("--repo <owner/repo>", "current repo (defaults to git origin)").option("--direct", "bypass the Hub snapshot and read the live board through direct GitHub GraphQL").option("--bundle-details", "fetch body/comments only for user-owned and claimable issues").option("--bodies", "fetch body/comments for EVERY scoped row, including taken and unowned in-flight ones \u2014 for consumers that scope by Status rather than ownership (#4861); implies --bundle-details and costs one extra read per row").option("--allow-partial", "return partial board results when later page/detail reads fail").option("--out <path>", "write the output to this file as UTF-8 (no BOM) instead of stdout \u2014 the shell-free receipt path (#5802)").addHelpText("after", "\nread is always the authoritative live GitHub Project v2 board (#4926).\n--direct skips the Hub snapshot and uses the existing direct GitHub GraphQL read immediately.\n--allow-partial applies to the paginated path and detail reads.\n\nNever capture the JSON with a shell redirect on Windows: PowerShell 5.1's `> file.json` is Out-File,\nwhich writes UTF-16LE with a BOM, and Node reading it as 'utf8' then fails JSON.parse at position 1\n(#5802). Use --out instead \u2014 the CLI writes the file itself as UTF-8:\n mmi-cli oracle board read --json --out .jerv/tmp/board.json\n").action((o) => runBoardRead(o));
|
|
25766
25777
|
withExamples(mutating(
|
|
25767
25778
|
board.command("claim <issues...>").description("claim issues: assign them and move their Project v2 Status to In Progress \u2014 idempotent, so an item already yours and In Progress succeeds unchanged (one or more refs); the board scan rides the Hub snapshot, same as board read").addHelpText("after", "\nclaim reads the board through the same Hub snapshot leg as `board read` (the App-installation\ncredential, never your personal GraphQL pool); the direct user-auth read is an emergency fallback\nand is named in a Warning line after the verdict (#6162).\n\nevery claim stamps a lane-identity marker comment on the issue (`<!-- mmi-claim: \u2026 -->`,\nsurface/session@host) so other agents can attribute the hold (#3727). The session is the\nhost-exported id when the surface provides one, otherwise a per-process `synth-` fallback \u2014\na claim is never anonymous (#5245). `board show`, doctor and unclaim read the latest marker.\n\nsame-owner resume (#6035): when the prior marker was posted by YOUR login on THIS host and its\nlocal session is verifiably dead (transcript probe), the claim proceeds as a resume without\n--force and names the evidence. A live, foreign-host, or unprobeable prior lane still refuses.\n\nreclaim from In Review (#6339): an In Review item with no holder, or one held by the claiming\nlogin, is claimable \u2014 it moves back to In Progress and the receipt names the status it came from.\nAn In Review item another login holds is refused (ask the holder, or wait for the review to land),\nand Done stays refused. The board status is the authority; no PR state is consulted.\n").option("--json", "machine-readable output").option("--repo <owner/repo>", "current repo for local issue numbers (defaults to git origin)").option("--for <login>", "assign to this login instead of @me \u2014 agent claims on behalf of the master").option("--force", "take an item already claimed by another lane that shows live evidence of active work (#3727)").option("--check", "read-only: run every claim gate and report the verdict, writing nothing \u2014 exits 1 with the same refusal a real claim would raise (#4511)").option("--allow-partial", "return success JSON if assignment succeeds but the status move fails"),
|
|
25768
|
-
(_opts, args) => ({ command: "board claim", issues: args[0] ?? [] })
|
|
25779
|
+
(_opts, args) => ({ command: "oracle board claim", issues: args[0] ?? [] })
|
|
25769
25780
|
).action(async (issueRefs, o) => {
|
|
25770
25781
|
if (issueRefs.length === 1) {
|
|
25771
25782
|
const issueRef = issueRefs[0];
|
|
@@ -25787,7 +25798,7 @@ function registerBoardCommands(program3) {
|
|
|
25787
25798
|
} catch (e) {
|
|
25788
25799
|
if (refuseRateLimited(e, o.json)) return;
|
|
25789
25800
|
if (refuseNotClaimable(e, o.json)) return;
|
|
25790
|
-
return failGraceful(`board claim failed: ${e.message}`);
|
|
25801
|
+
return failGraceful(`oracle board claim failed: ${e.message}`);
|
|
25791
25802
|
}
|
|
25792
25803
|
return;
|
|
25793
25804
|
}
|
|
@@ -25815,7 +25826,7 @@ function registerBoardCommands(program3) {
|
|
|
25815
25826
|
if (bulk.failed > 0) process.exitCode = 1;
|
|
25816
25827
|
} catch (e) {
|
|
25817
25828
|
if (refuseRateLimited(e, o.json)) return;
|
|
25818
|
-
return failGraceful(`board claim failed: ${e.message}`);
|
|
25829
|
+
return failGraceful(`oracle board claim failed: ${e.message}`);
|
|
25819
25830
|
}
|
|
25820
25831
|
}), [
|
|
25821
25832
|
"mmi-cli oracle board claim 2680",
|
|
@@ -25827,7 +25838,9 @@ function registerBoardCommands(program3) {
|
|
|
25827
25838
|
"Multiple refs are handled as a batch and return per-item results.",
|
|
25828
25839
|
"--check is the live gate read (it calls GitHub); --dry-run only echoes the parsed argv plan.",
|
|
25829
25840
|
// #5552: agents guess `oracle issue claim`; that route does not exist — board claim is the only write.
|
|
25830
|
-
"Never run `oracle issue claim` \u2014 claims are board mutations; only `oracle board claim <ref>` is valid."
|
|
25841
|
+
"Never run `oracle issue claim` \u2014 claims are board mutations; only `oracle board claim <ref>` is valid.",
|
|
25842
|
+
// Flat Wave 0 alias: agents still type `mmi-cli board claim` and treat the refusal as a tool fault.
|
|
25843
|
+
"Never run the flat `board claim` \u2014 that Wave 0 alias was removed; only `mmi-cli oracle board claim <ref>` parses."
|
|
25831
25844
|
]);
|
|
25832
25845
|
board.command("show <issue>").description("print one board item (status, assignees, type, url) with its body and comments").option("--json", "machine-readable output").option("--repo <owner/repo>", "current repo for local issue numbers (defaults to git origin)").option("--allow-partial", "return the item even if its body/comments fetch fails").option("--out <path>", "write the output to this file as UTF-8 (no BOM) instead of stdout \u2014 the shell-free receipt path (#5802)").action(async (issueRef, o) => {
|
|
25833
25846
|
try {
|
|
@@ -32468,7 +32481,7 @@ var LOOP_PLAYBOOKS = {
|
|
|
32468
32481
|
{ label: "Read the next board item", command: "mmi-cli oracle board read" },
|
|
32469
32482
|
// #5552: claim is a board mutation only — never guess `oracle issue claim`. Ground unknown write
|
|
32470
32483
|
// routes with `mmi-cli commands` / `mmi-cli explain` before invoking them.
|
|
32471
|
-
{ label: "Claim board work (board mutation only \u2014 never `oracle issue claim`; ground unknown write routes via `commands` / `explain` first)", command: "mmi-cli oracle board claim <ref>" },
|
|
32484
|
+
{ label: "Claim board work (board mutation only \u2014 never `oracle issue claim` or the flat `board claim`; ground unknown write routes via `commands` / `explain` first)", command: "mmi-cli oracle board claim <ref>" },
|
|
32472
32485
|
{ label: "Prepare the local workspace through the host surface" },
|
|
32473
32486
|
{ label: "Before broad docs rewrites, follow docs/Guides/doc-ceremony-cut.md" },
|
|
32474
32487
|
{ label: "Apply the repository test policy, then build the touched package", command: "mmi-cli tests policy --base origin/development && npm run build" },
|
|
@@ -32485,7 +32498,7 @@ var LOOP_PLAYBOOKS = {
|
|
|
32485
32498
|
steps: [
|
|
32486
32499
|
{ label: "Orient in the current repository", command: "mmi-cli onboard" },
|
|
32487
32500
|
{ label: "Read the board item", command: "mmi-cli oracle board show <issue-number>" },
|
|
32488
|
-
{ label: "Claim the item (board mutation only \u2014 never `oracle issue claim`)", command: "mmi-cli oracle board claim <issue-number>" },
|
|
32501
|
+
{ label: "Claim the item (board mutation only \u2014 never `oracle issue claim` or the flat `board claim`)", command: "mmi-cli oracle board claim <issue-number>" },
|
|
32489
32502
|
{ label: "Prepare the local workspace through the host surface" },
|
|
32490
32503
|
{ label: "Start a local stage (deployable repos)", command: "mmi-cli stage run --apply" }
|
|
32491
32504
|
]
|
|
@@ -39707,7 +39720,7 @@ function registerCollaborationCommands(program3) {
|
|
|
39707
39720
|
function surfaceWaived() {
|
|
39708
39721
|
return rawFlag("--no-surface");
|
|
39709
39722
|
}
|
|
39710
|
-
const issue = program3.command("issue").description("issues \u2014 create and view with structured JSON (view; show, get and read alias view for board-verb/gh-shaped callers). Claims are board mutations: use `oracle board claim`, never `oracle issue claim`");
|
|
39723
|
+
const issue = program3.command("issue").description("issues \u2014 create and view with structured JSON (view; show, get and read alias view for board-verb/gh-shaped callers). Claims are board mutations: use `oracle board claim`, never `oracle issue claim` or the flat `board claim`");
|
|
39711
39724
|
withExamples(mutating(
|
|
39712
39725
|
issue.command("create").description("create an issue (type \u2014 label) and print {number,url,label} JSON").addOption(new Option("--type <type>", "bug | feature | task (sets the matching label; required unless --batch)").choices([...ISSUE_TYPES])).option("--title <title>", "issue title").option("--title-file <path|->", "read the issue title from a UTF-8 file, or from stdin with -").option("--body <body>", "issue body (markdown)").option("--body-file <path|->", "read issue body from a UTF-8 file. `-` (stdin) needs a heredoc, which the agent inline-body guard denies (#1473/#2125) \u2014 prefer a real path; a title with backticks needs --title-file for the same reason (#3381)").option("--priority <priority>", "urgent | high | medium | low (defaults to medium; sets the board Priority field only \u2014 never a priority:* label, #416)").option("--repo <owner/repo>", "target repo (defaults to the current repo)").option("--label <label...>", "extra label(s) to attach (repeatable; auto-created if missing)").option("--surface <surface>", "issue surface, with or without the surface: prefix (#3789). Required when the target repo runs the one-surface-label board rule; any value satisfies it, so this is not a closed enum").option("--no-surface", "file without a surface label on a repo that requires one \u2014 for a genuinely exempt filing (e.g. a coop proof issue that spans every surface)").option("--parent <ref>", "file as a native sub-issue of this parent (#123, owner/repo#123, or URL)").option("--no-related", "skip the auto related-issues comment"),
|
|
39713
39726
|
// --dry-run/--validate-only plan: resolve the same title source and validate the same type, priority,
|
package/package.json
CHANGED