@muggleai/works 5.26.0-staging.195 → 5.26.0-staging.197
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/.claude-plugin/marketplace.json +1 -1
- package/dist/{chunk-OOSMKH2M.js → chunk-Y6JJ2SN7.js} +41 -0
- package/dist/cli.js +1 -1
- package/dist/index.js +1 -1
- package/dist/plugin/.claude-plugin/plugin.json +1 -1
- package/dist/plugin/.codex-mcp.json +1 -1
- package/dist/plugin/.codex-plugin/plugin.json +1 -1
- package/dist/plugin/.cursor-plugin/plugin.json +1 -1
- package/dist/plugin/.mcp.json +1 -1
- package/dist/plugin/scripts/guardrails.mjs +25 -4
- package/dist/plugin/skills/do/e2e-acceptance.md +3 -1
- package/dist/release-manifest.json +3 -3
- package/package.json +1 -1
- package/plugin/.claude-plugin/plugin.json +1 -1
- package/plugin/.codex-mcp.json +1 -1
- package/plugin/.codex-plugin/plugin.json +1 -1
- package/plugin/.cursor-plugin/plugin.json +1 -1
- package/plugin/.mcp.json +1 -1
- package/plugin/scripts/guardrails.mjs +25 -4
- package/plugin/skills/do/e2e-acceptance.md +3 -1
|
@@ -9,7 +9,7 @@
|
|
|
9
9
|
"name": "muggleai",
|
|
10
10
|
"source": "./plugin",
|
|
11
11
|
"description": "Real-browser E2E acceptance for your coding agent: test the flows you changed and open the PR with screenshots. Built for flows other tools can't reach: managed test identities with live inboxes (magic links, email OTP and 2FA, verification mail, password resets), an encrypted secret store for login and test credentials, and a test graph that runs prerequisite flows first. Plain-English tests become replayable scripts on localhost or preview URLs.",
|
|
12
|
-
"version": "5.26.0-staging.
|
|
12
|
+
"version": "5.26.0-staging.197"
|
|
13
13
|
}
|
|
14
14
|
]
|
|
15
15
|
}
|
|
@@ -2480,6 +2480,7 @@ var E2eSkipCode = /* @__PURE__ */ ((E2eSkipCode2) => {
|
|
|
2480
2480
|
E2eSkipCode2["NoPr"] = "NO_PR";
|
|
2481
2481
|
E2eSkipCode2["UserWaived"] = "USER_WAIVED";
|
|
2482
2482
|
E2eSkipCode2["NoAppLogicChange"] = "NO_APP_LOGIC_CHANGE";
|
|
2483
|
+
E2eSkipCode2["NotApplicable"] = "NOT_APPLICABLE";
|
|
2483
2484
|
return E2eSkipCode2;
|
|
2484
2485
|
})(E2eSkipCode || {});
|
|
2485
2486
|
|
|
@@ -2492,6 +2493,7 @@ var WALKTHROUGH_SLOT_MARKER = "<!-- muggle-pr-walkthrough:v1 -->";
|
|
|
2492
2493
|
var WALKTHROUGH_SKIPPED_MARKER = "<!-- muggle-pr-walkthrough-status:skipped -->";
|
|
2493
2494
|
var WALKTHROUGH_COMMENT_HEADING = "### Muggle AI \u2014 PR visual walkthrough";
|
|
2494
2495
|
var GH_COMMENT_TIMEOUT_MS = 1e4;
|
|
2496
|
+
var DEPENDENCY_BOT_LOGINS = ["dependabot[bot]", "renovate[bot]"];
|
|
2495
2497
|
|
|
2496
2498
|
// src/pr-walkthrough/comment.ts
|
|
2497
2499
|
function renderReservedComment() {
|
|
@@ -2500,6 +2502,13 @@ ${WALKTHROUGH_COMMENT_HEADING}
|
|
|
2500
2502
|
|
|
2501
2503
|
_Awaiting the E2E acceptance run. Muggle edits this comment in place when the run finishes \u2014 or records why E2E does not apply to this change._`;
|
|
2502
2504
|
}
|
|
2505
|
+
function renderDependencyBotComment(login) {
|
|
2506
|
+
return `${WALKTHROUGH_SLOT_MARKER}
|
|
2507
|
+
${WALKTHROUGH_SKIPPED_MARKER}
|
|
2508
|
+
${WALKTHROUGH_COMMENT_HEADING}
|
|
2509
|
+
|
|
2510
|
+
**No E2E run \u2014 not applicable.** A dependency update opened by \`${login}\`; no coding session ran on it.`;
|
|
2511
|
+
}
|
|
2503
2512
|
function classifyComment(body) {
|
|
2504
2513
|
if (body.includes(REPORT_SENTINEL)) return "reported" /* Reported */;
|
|
2505
2514
|
if (!body.includes(WALKTHROUGH_SLOT_MARKER)) return "not-designated" /* NotDesignated */;
|
|
@@ -2558,6 +2567,13 @@ function readPrHeadSha(pr, run) {
|
|
|
2558
2567
|
return null;
|
|
2559
2568
|
}
|
|
2560
2569
|
}
|
|
2570
|
+
function readPrAuthorLogin(pr, run) {
|
|
2571
|
+
try {
|
|
2572
|
+
return run(["api", `repos/${pr.repo}/pulls/${pr.prNumber}`, "--jq", ".user.login"])?.trim() || null;
|
|
2573
|
+
} catch {
|
|
2574
|
+
return null;
|
|
2575
|
+
}
|
|
2576
|
+
}
|
|
2561
2577
|
function writeJson(args, payload, run) {
|
|
2562
2578
|
try {
|
|
2563
2579
|
return run(args, JSON.stringify(payload)) !== null;
|
|
@@ -2572,6 +2588,13 @@ function postPrComment(pr, body, run) {
|
|
|
2572
2588
|
run
|
|
2573
2589
|
);
|
|
2574
2590
|
}
|
|
2591
|
+
function patchPrComment(pr, commentId, body, run) {
|
|
2592
|
+
return writeJson(
|
|
2593
|
+
["api", "--method", "PATCH", `repos/${pr.repo}/issues/comments/${commentId}`, "--input", "-"],
|
|
2594
|
+
{ body },
|
|
2595
|
+
run
|
|
2596
|
+
);
|
|
2597
|
+
}
|
|
2575
2598
|
function createCheckRun(repo, checkRun, run) {
|
|
2576
2599
|
return writeJson(["api", "--method", "POST", `repos/${repo}/check-runs`, "--input", "-"], {
|
|
2577
2600
|
name: checkRun.name,
|
|
@@ -2583,6 +2606,9 @@ function createCheckRun(repo, checkRun, run) {
|
|
|
2583
2606
|
}
|
|
2584
2607
|
|
|
2585
2608
|
// src/pr-walkthrough/reserve.ts
|
|
2609
|
+
function commentWithStatus(comments, status) {
|
|
2610
|
+
return comments.find((comment) => classifyComment(comment.body) === status);
|
|
2611
|
+
}
|
|
2586
2612
|
function reserveComment(pr, comments, run) {
|
|
2587
2613
|
const claimed = comments.some(
|
|
2588
2614
|
(comment) => classifyComment(comment.body) !== "not-designated" /* NotDesignated */
|
|
@@ -2590,6 +2616,11 @@ function reserveComment(pr, comments, run) {
|
|
|
2590
2616
|
if (claimed) return false;
|
|
2591
2617
|
return postPrComment(pr, renderReservedComment(), run);
|
|
2592
2618
|
}
|
|
2619
|
+
function settleDependencyBotComment(pr, comments, login, run) {
|
|
2620
|
+
const body = renderDependencyBotComment(login);
|
|
2621
|
+
const reserved = commentWithStatus(comments, "pending" /* Pending */);
|
|
2622
|
+
return reserved ? patchPrComment(pr, reserved.id, body, run) : postPrComment(pr, body, run);
|
|
2623
|
+
}
|
|
2593
2624
|
|
|
2594
2625
|
// src/cli/pr-walkthrough/constants.ts
|
|
2595
2626
|
var CHECK_RUN_NAME = "muggle-walkthrough";
|
|
@@ -2634,6 +2665,16 @@ function judgeComments(pr, comments, run) {
|
|
|
2634
2665
|
}
|
|
2635
2666
|
const bodies = comments.map((comment) => comment.body);
|
|
2636
2667
|
const verdict = walkthroughVerdict(bodies);
|
|
2668
|
+
if (verdict !== "satisfied" /* Satisfied */) {
|
|
2669
|
+
const author = readPrAuthorLogin(pr, run);
|
|
2670
|
+
if (author && DEPENDENCY_BOT_LOGINS.includes(author)) {
|
|
2671
|
+
settleDependencyBotComment(pr, comments, author, run);
|
|
2672
|
+
return {
|
|
2673
|
+
outcome: "settled" /* Settled */,
|
|
2674
|
+
summary: FIXED_SUMMARIES["settled" /* Settled */]
|
|
2675
|
+
};
|
|
2676
|
+
}
|
|
2677
|
+
}
|
|
2637
2678
|
if (verdict === "missing" /* Missing */) reserveComment(pr, comments, run);
|
|
2638
2679
|
const record = latestE2eResult(bodies);
|
|
2639
2680
|
if (record && record.unpassed.length > 0) {
|
package/dist/cli.js
CHANGED
package/dist/index.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export { src_exports as commands, createUnifiedMcpServer, server_exports as server } from './chunk-
|
|
1
|
+
export { src_exports as commands, createUnifiedMcpServer, server_exports as server } from './chunk-Y6JJ2SN7.js';
|
|
2
2
|
export { createChildLogger, e2e_exports as e2e, getConfig, getLocalQaTools, getLogger, getQaTools, local_exports as localQa, mcp_exports as mcp, e2e_exports as qa, src_exports as shared } from './chunk-SLU7LHVJ.js';
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "muggle",
|
|
3
3
|
"description": "Real-browser E2E acceptance for your coding agent: test the flows you changed and open the PR with screenshots. Built for flows other tools can't reach: managed test identities with live inboxes (magic links, email OTP and 2FA, verification mail, password resets), an encrypted secret store for login and test credentials, and a test graph that runs prerequisite flows first. Plain-English tests become replayable scripts on localhost or preview URLs.",
|
|
4
|
-
"version": "5.26.0-staging.
|
|
4
|
+
"version": "5.26.0-staging.197",
|
|
5
5
|
"author": {
|
|
6
6
|
"name": "Muggle AI",
|
|
7
7
|
"email": "support@muggle-ai.com"
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "muggle",
|
|
3
|
-
"version": "5.26.0-staging.
|
|
3
|
+
"version": "5.26.0-staging.197",
|
|
4
4
|
"description": "Real-browser E2E acceptance for your coding agent: test the flows you changed and open the PR with screenshots. Built for flows other tools can't reach: managed test identities with live inboxes (magic links, email OTP and 2FA, verification mail, password resets), an encrypted secret store for login and test credentials, and a test graph that runs prerequisite flows first. Plain-English tests become replayable scripts on localhost or preview URLs.",
|
|
5
5
|
"author": {
|
|
6
6
|
"name": "Muggle AI",
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
"name": "muggle",
|
|
3
3
|
"displayName": "Muggle AI",
|
|
4
4
|
"description": "Real-browser E2E acceptance for your coding agent: test the flows you changed and open the PR with screenshots. Built for flows other tools can't reach: managed test identities with live inboxes (magic links, email OTP and 2FA, verification mail, password resets), an encrypted secret store for login and test credentials, and a test graph that runs prerequisite flows first. Plain-English tests become replayable scripts on localhost or preview URLs.",
|
|
5
|
-
"version": "5.26.0-staging.
|
|
5
|
+
"version": "5.26.0-staging.197",
|
|
6
6
|
"author": {
|
|
7
7
|
"name": "Muggle AI",
|
|
8
8
|
"email": "support@muggle-ai.com"
|
package/dist/plugin/.mcp.json
CHANGED
|
@@ -1092,6 +1092,7 @@ var E2eSkipCode = /* @__PURE__ */ ((E2eSkipCode3) => {
|
|
|
1092
1092
|
E2eSkipCode3["NoPr"] = "NO_PR";
|
|
1093
1093
|
E2eSkipCode3["UserWaived"] = "USER_WAIVED";
|
|
1094
1094
|
E2eSkipCode3["NoAppLogicChange"] = "NO_APP_LOGIC_CHANGE";
|
|
1095
|
+
E2eSkipCode3["NotApplicable"] = "NOT_APPLICABLE";
|
|
1095
1096
|
return E2eSkipCode3;
|
|
1096
1097
|
})(E2eSkipCode || {});
|
|
1097
1098
|
|
|
@@ -1107,7 +1108,8 @@ var E2E_SKIP_CODE_CLAIMS = {
|
|
|
1107
1108
|
["MUGGLE_AUTH_DOWN" /* MuggleAuthDown */]: "the stored Muggle session is missing or expired",
|
|
1108
1109
|
["NO_PR" /* NoPr */]: "no pull request was handled this session",
|
|
1109
1110
|
["USER_WAIVED" /* UserWaived */]: "the user waived E2E in their own words",
|
|
1110
|
-
["NO_APP_LOGIC_CHANGE" /* NoAppLogicChange */]: `every path changed since the named commit is ${NON_APP_PATH_SUMMARY}
|
|
1111
|
+
["NO_APP_LOGIC_CHANGE" /* NoAppLogicChange */]: `every path changed since the named commit is ${NON_APP_PATH_SUMMARY}`,
|
|
1112
|
+
["NOT_APPLICABLE" /* NotApplicable */]: "a browser run cannot exercise this change, for the reason stated"
|
|
1111
1113
|
};
|
|
1112
1114
|
var CYCLE_SCOPED_SKIP_CODES = ["NO_APP_LOGIC_CHANGE" /* NoAppLogicChange */];
|
|
1113
1115
|
var PRE_CYCLE_SHA_TOKEN = /^([0-9a-f]{7,40})(?![0-9a-z_])/i;
|
|
@@ -1128,6 +1130,7 @@ var NON_APP_PATH_PATTERNS = [
|
|
|
1128
1130
|
];
|
|
1129
1131
|
var MAX_NAMED_APP_LOGIC_PATHS = 5;
|
|
1130
1132
|
var USER_WAIVE_PHRASE = "SKIP E2E";
|
|
1133
|
+
var MIN_NOT_APPLICABLE_REASON_WORDS = 4;
|
|
1131
1134
|
var DEV_SERVER_PROBE_TIMEOUT_MS = 2e3;
|
|
1132
1135
|
var GIT_PROBE_TIMEOUT_MS = 5e3;
|
|
1133
1136
|
var WEB_SERVER_COMMAND = /\b(vite|next\s+(dev|start)|react-scripts|ng\s+serve|nuxt|astro\s+dev|remix\s+dev|webpack(-dev)?-server|http-server|serve\s+-s|gatsby\s+develop|vue-cli-service\s+serve)\b/;
|
|
@@ -1176,6 +1179,7 @@ _Awaiting the E2E acceptance run. Muggle edits this comment in place when the ru
|
|
|
1176
1179
|
}
|
|
1177
1180
|
function renderSkippedComment(code, detail) {
|
|
1178
1181
|
const stated = detail.trim();
|
|
1182
|
+
if (code === "NOT_APPLICABLE" /* NotApplicable */) return renderNotApplicableComment(stated);
|
|
1179
1183
|
const qualifier = stated ? ` \u2014 ${stated}` : "";
|
|
1180
1184
|
return `${WALKTHROUGH_SLOT_MARKER}
|
|
1181
1185
|
${WALKTHROUGH_SKIPPED_MARKER}
|
|
@@ -1183,6 +1187,15 @@ ${WALKTHROUGH_COMMENT_HEADING}
|
|
|
1183
1187
|
|
|
1184
1188
|
**No E2E run.** Muggle verified \`${code}\` \u2014 ${E2E_SKIP_CODE_CLAIMS[code]}${qualifier}.`;
|
|
1185
1189
|
}
|
|
1190
|
+
function renderNotApplicableComment(reason) {
|
|
1191
|
+
return `${WALKTHROUGH_SLOT_MARKER}
|
|
1192
|
+
${WALKTHROUGH_SKIPPED_MARKER}
|
|
1193
|
+
${WALKTHROUGH_COMMENT_HEADING}
|
|
1194
|
+
|
|
1195
|
+
**No E2E run \u2014 not applicable.** ${reason.replace(/\.$/, "")}.
|
|
1196
|
+
|
|
1197
|
+
_The coding agent judged that a browser run cannot exercise this change (\`${"NOT_APPLICABLE" /* NotApplicable */}\`). Muggle did not verify this reason._`;
|
|
1198
|
+
}
|
|
1186
1199
|
function renderUnreasonedSkipComment() {
|
|
1187
1200
|
return `${WALKTHROUGH_SLOT_MARKER}
|
|
1188
1201
|
${WALKTHROUGH_SKIPPED_MARKER}
|
|
@@ -1401,6 +1414,13 @@ var verifyNoAppLogicChange = (context, detail) => {
|
|
|
1401
1414
|
if (appLogicPaths.length > 0) return refuted(`app-logic paths changed since ${sha}: ${namePaths(appLogicPaths)}`);
|
|
1402
1415
|
return verified;
|
|
1403
1416
|
};
|
|
1417
|
+
var verifyNotApplicable = (_context, detail) => {
|
|
1418
|
+
const words = detail.trim().split(/\s+/).filter(Boolean).length;
|
|
1419
|
+
if (words >= MIN_NOT_APPLICABLE_REASON_WORDS) return verified;
|
|
1420
|
+
return refuted(
|
|
1421
|
+
`the reason is ${words === 0 ? "missing" : "too short to weigh"} \u2014 cite it as NOT_APPLICABLE: <why a browser run cannot exercise this change>, in at least ${MIN_NOT_APPLICABLE_REASON_WORDS} words`
|
|
1422
|
+
);
|
|
1423
|
+
};
|
|
1404
1424
|
var VERIFIERS = {
|
|
1405
1425
|
["NO_WEB_SURFACE" /* NoWebSurface */]: verifyNoWebSurface,
|
|
1406
1426
|
["DEV_SERVER_UNREACHABLE" /* DevServerUnreachable */]: verifyDevServerUnreachable,
|
|
@@ -1408,7 +1428,8 @@ var VERIFIERS = {
|
|
|
1408
1428
|
["MUGGLE_AUTH_DOWN" /* MuggleAuthDown */]: verifyMuggleAuthDown,
|
|
1409
1429
|
["NO_PR" /* NoPr */]: verifyNoPr,
|
|
1410
1430
|
["USER_WAIVED" /* UserWaived */]: verifyUserWaived,
|
|
1411
|
-
["NO_APP_LOGIC_CHANGE" /* NoAppLogicChange */]: verifyNoAppLogicChange
|
|
1431
|
+
["NO_APP_LOGIC_CHANGE" /* NoAppLogicChange */]: verifyNoAppLogicChange,
|
|
1432
|
+
["NOT_APPLICABLE" /* NotApplicable */]: verifyNotApplicable
|
|
1412
1433
|
};
|
|
1413
1434
|
function verifyDeclaredSkip(skip, context) {
|
|
1414
1435
|
return VERIFIERS[skip.code](context, skip.detail);
|
|
@@ -1433,7 +1454,7 @@ function explainRejection(judged) {
|
|
|
1433
1454
|
return `That skip declaration states no code. E2E is skipped only by citing one of: ${codeMenu()}.`;
|
|
1434
1455
|
}
|
|
1435
1456
|
if (judged.rejection === "unknown-code" /* UnknownCode */) {
|
|
1436
|
-
return `"${judged.claimedCode}" is not a skip code, so E2E is still owed.
|
|
1457
|
+
return `"${judged.claimedCode}" is not a skip code, so E2E is still owed. Cite one of: ${codeMenu()}. If none of them is true, the run has to happen.`;
|
|
1437
1458
|
}
|
|
1438
1459
|
return `The skip cited ${judged.claimedCode}, but that could not be verified: ${judged.failure}. E2E is still owed \u2014 cite a code that holds, or run it.`;
|
|
1439
1460
|
}
|
|
@@ -2085,7 +2106,7 @@ function e2eGate() {
|
|
|
2085
2106
|
if (decision.action === "none" /* None */) return "{}";
|
|
2086
2107
|
state.e2eBlockCount = decision.blockCount;
|
|
2087
2108
|
writeState(state);
|
|
2088
|
-
const reason = decision.blockCount === 1 ? `Do not end the turn yet. This session went unit-green or opened a PR, but no E2E acceptance run has happened. Per the autoE2ETest preference (default: always), run change-driven E2E now via ${muggleSkill("/muggle:muggle-test")}, then finish.
|
|
2109
|
+
const reason = decision.blockCount === 1 ? `Do not end the turn yet. This session went unit-green or opened a PR, but no E2E acceptance run has happened. Per the autoE2ETest preference (default: always), run change-driven E2E now via ${muggleSkill("/muggle:muggle-test")}, then finish. To skip, run \`echo "MUGGLE_E2E_SKIP: <CODE>: <detail>"\` citing one of ${E2E_SKIP_CODES.join(", ")}. Muggle verifies each code itself, so one that does not hold leaves this gate blocked. Only when no verifiable code fits and a browser run genuinely cannot exercise the change, cite ${"NOT_APPLICABLE" /* NotApplicable */} with the reason \u2014 the PR shows it as your unverified judgment.` : `E2E acceptance run still owed (reminder ${decision.blockCount}/${MAX_E2E_BLOCKS}): run ${muggleSkill("/muggle:muggle-test")}, or cite a verifiable code via \`echo "MUGGLE_E2E_SKIP: <CODE>: <detail>"\`.`;
|
|
2089
2110
|
return blockStop(reason, host);
|
|
2090
2111
|
}
|
|
2091
2112
|
function watchGate() {
|
|
@@ -23,7 +23,9 @@ This stage is **mode-driven by pre-flight**:
|
|
|
23
23
|
|
|
24
24
|
**Every SKIPPED exit from this stage** (Step 0 poll-only, Step 1 `unit-only`/`skip`, Step 1.5 placeholder branch) also runs `echo "MUGGLE_E2E_SKIP: <CODE>: <detail>"` as a single Bash call before exiting — it records the skip in guardrail session state so the Stop-hook E2E gate releases instead of blocking the turn.
|
|
25
25
|
|
|
26
|
-
`<CODE>` is one of `NO_WEB_SURFACE`, `DEV_SERVER_UNREACHABLE`, `EMPTY_DIFF`, `MUGGLE_AUTH_DOWN`, `NO_PR`, `USER_WAIVED`, `NO_APP_LOGIC_CHANGE` — the one list of
|
|
26
|
+
`<CODE>` is one of `NO_WEB_SURFACE`, `DEV_SERVER_UNREACHABLE`, `EMPTY_DIFF`, `MUGGLE_AUTH_DOWN`, `NO_PR`, `USER_WAIVED`, `NO_APP_LOGIC_CHANGE`, `NOT_APPLICABLE` — the one list of skip codes, which other files reference rather than restate — and the guardrail checks it before the gate releases. Every code but `NOT_APPLICABLE` names a fact the guardrail checks for itself, about the environment or about which paths a commit range touched. "Static page", "layout only", "unit tests cover it" and "verified with another tool" are not reasons E2E cannot apply — cite a code that holds, or run the tests. `USER_WAIVED` needs the user's own literal `SKIP E2E` in the transcript, never an inferred go-ahead. A rejected declaration is answered with the check that failed, and the turn stays blocked.
|
|
27
|
+
|
|
28
|
+
`NOT_APPLICABLE` is the last resort, for a change no browser run can exercise and no verifiable code covers — an email template, a backend path the UI never reaches, a scheduled job. Its detail is the reason, in at least four words, and the PR's walkthrough comment shows that reason as the agent's own judgment, marked unverified, for the reviewer to accept or push back on. Never cite it to avoid a run that could happen.
|
|
27
29
|
|
|
28
30
|
`NO_APP_LOGIC_CHANGE` belongs to a watcher cycle's minor tail ([`cycle-size.md`](cycle-size.md)), never to a Stage 6 exit. Its detail opens with the cycle's starting commit. Muggle diffs that commit against HEAD and accepts only when every changed path is docs (`*.md`, `*.markdown`, `*.rst`), tests (`*.test.*`, `*.spec.*`, `__tests__/`, `__snapshots__/`, `__mocks__/`, `test_*.py`, `*_test.py`, `*_test.go`, a root-level `test/` or `tests/`), lint/format config (ESLint, Prettier, Stylelint and markdownlint config or ignore files, `biome.json`, `.editorconfig`), or CI config (`.github/workflows/`, `.gitlab-ci.yml`). A commit it cannot resolve, an empty diff, or any other path — a comment-only edit in a source file included — fails.
|
|
29
31
|
- `staging-replay` is not executed in this stage path and should be surfaced as `INCONCLUSIVE` unless the caller has already routed to a dedicated staging runner.
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"release": "5.18.0",
|
|
3
|
-
"buildId": "run-
|
|
4
|
-
"commitSha": "
|
|
5
|
-
"buildTime": "2026-10-
|
|
3
|
+
"buildId": "run-197-1",
|
|
4
|
+
"commitSha": "fca74cbd783c2dff3ad1a2bac30bd2f8d2ea9461",
|
|
5
|
+
"buildTime": "2026-10-25T03:31:32Z",
|
|
6
6
|
"serviceName": "muggle-ai-works-mcp"
|
|
7
7
|
}
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@muggleai/works",
|
|
3
3
|
"mcpName": "io.github.multiplex-ai/muggle",
|
|
4
|
-
"version": "5.26.0-staging.
|
|
4
|
+
"version": "5.26.0-staging.197",
|
|
5
5
|
"description": "13 years of Microsoft hyperscale engineering, packaged as a harness for your AI coding agent.",
|
|
6
6
|
"type": "module",
|
|
7
7
|
"main": "dist/index.js",
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "muggle",
|
|
3
3
|
"description": "Real-browser E2E acceptance for your coding agent: test the flows you changed and open the PR with screenshots. Built for flows other tools can't reach: managed test identities with live inboxes (magic links, email OTP and 2FA, verification mail, password resets), an encrypted secret store for login and test credentials, and a test graph that runs prerequisite flows first. Plain-English tests become replayable scripts on localhost or preview URLs.",
|
|
4
|
-
"version": "5.26.0-staging.
|
|
4
|
+
"version": "5.26.0-staging.197",
|
|
5
5
|
"author": {
|
|
6
6
|
"name": "Muggle AI",
|
|
7
7
|
"email": "support@muggle-ai.com"
|
package/plugin/.codex-mcp.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "muggle",
|
|
3
|
-
"version": "5.26.0-staging.
|
|
3
|
+
"version": "5.26.0-staging.197",
|
|
4
4
|
"description": "Real-browser E2E acceptance for your coding agent: test the flows you changed and open the PR with screenshots. Built for flows other tools can't reach: managed test identities with live inboxes (magic links, email OTP and 2FA, verification mail, password resets), an encrypted secret store for login and test credentials, and a test graph that runs prerequisite flows first. Plain-English tests become replayable scripts on localhost or preview URLs.",
|
|
5
5
|
"author": {
|
|
6
6
|
"name": "Muggle AI",
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
"name": "muggle",
|
|
3
3
|
"displayName": "Muggle AI",
|
|
4
4
|
"description": "Real-browser E2E acceptance for your coding agent: test the flows you changed and open the PR with screenshots. Built for flows other tools can't reach: managed test identities with live inboxes (magic links, email OTP and 2FA, verification mail, password resets), an encrypted secret store for login and test credentials, and a test graph that runs prerequisite flows first. Plain-English tests become replayable scripts on localhost or preview URLs.",
|
|
5
|
-
"version": "5.26.0-staging.
|
|
5
|
+
"version": "5.26.0-staging.197",
|
|
6
6
|
"author": {
|
|
7
7
|
"name": "Muggle AI",
|
|
8
8
|
"email": "support@muggle-ai.com"
|
package/plugin/.mcp.json
CHANGED
|
@@ -1092,6 +1092,7 @@ var E2eSkipCode = /* @__PURE__ */ ((E2eSkipCode3) => {
|
|
|
1092
1092
|
E2eSkipCode3["NoPr"] = "NO_PR";
|
|
1093
1093
|
E2eSkipCode3["UserWaived"] = "USER_WAIVED";
|
|
1094
1094
|
E2eSkipCode3["NoAppLogicChange"] = "NO_APP_LOGIC_CHANGE";
|
|
1095
|
+
E2eSkipCode3["NotApplicable"] = "NOT_APPLICABLE";
|
|
1095
1096
|
return E2eSkipCode3;
|
|
1096
1097
|
})(E2eSkipCode || {});
|
|
1097
1098
|
|
|
@@ -1107,7 +1108,8 @@ var E2E_SKIP_CODE_CLAIMS = {
|
|
|
1107
1108
|
["MUGGLE_AUTH_DOWN" /* MuggleAuthDown */]: "the stored Muggle session is missing or expired",
|
|
1108
1109
|
["NO_PR" /* NoPr */]: "no pull request was handled this session",
|
|
1109
1110
|
["USER_WAIVED" /* UserWaived */]: "the user waived E2E in their own words",
|
|
1110
|
-
["NO_APP_LOGIC_CHANGE" /* NoAppLogicChange */]: `every path changed since the named commit is ${NON_APP_PATH_SUMMARY}
|
|
1111
|
+
["NO_APP_LOGIC_CHANGE" /* NoAppLogicChange */]: `every path changed since the named commit is ${NON_APP_PATH_SUMMARY}`,
|
|
1112
|
+
["NOT_APPLICABLE" /* NotApplicable */]: "a browser run cannot exercise this change, for the reason stated"
|
|
1111
1113
|
};
|
|
1112
1114
|
var CYCLE_SCOPED_SKIP_CODES = ["NO_APP_LOGIC_CHANGE" /* NoAppLogicChange */];
|
|
1113
1115
|
var PRE_CYCLE_SHA_TOKEN = /^([0-9a-f]{7,40})(?![0-9a-z_])/i;
|
|
@@ -1128,6 +1130,7 @@ var NON_APP_PATH_PATTERNS = [
|
|
|
1128
1130
|
];
|
|
1129
1131
|
var MAX_NAMED_APP_LOGIC_PATHS = 5;
|
|
1130
1132
|
var USER_WAIVE_PHRASE = "SKIP E2E";
|
|
1133
|
+
var MIN_NOT_APPLICABLE_REASON_WORDS = 4;
|
|
1131
1134
|
var DEV_SERVER_PROBE_TIMEOUT_MS = 2e3;
|
|
1132
1135
|
var GIT_PROBE_TIMEOUT_MS = 5e3;
|
|
1133
1136
|
var WEB_SERVER_COMMAND = /\b(vite|next\s+(dev|start)|react-scripts|ng\s+serve|nuxt|astro\s+dev|remix\s+dev|webpack(-dev)?-server|http-server|serve\s+-s|gatsby\s+develop|vue-cli-service\s+serve)\b/;
|
|
@@ -1176,6 +1179,7 @@ _Awaiting the E2E acceptance run. Muggle edits this comment in place when the ru
|
|
|
1176
1179
|
}
|
|
1177
1180
|
function renderSkippedComment(code, detail) {
|
|
1178
1181
|
const stated = detail.trim();
|
|
1182
|
+
if (code === "NOT_APPLICABLE" /* NotApplicable */) return renderNotApplicableComment(stated);
|
|
1179
1183
|
const qualifier = stated ? ` \u2014 ${stated}` : "";
|
|
1180
1184
|
return `${WALKTHROUGH_SLOT_MARKER}
|
|
1181
1185
|
${WALKTHROUGH_SKIPPED_MARKER}
|
|
@@ -1183,6 +1187,15 @@ ${WALKTHROUGH_COMMENT_HEADING}
|
|
|
1183
1187
|
|
|
1184
1188
|
**No E2E run.** Muggle verified \`${code}\` \u2014 ${E2E_SKIP_CODE_CLAIMS[code]}${qualifier}.`;
|
|
1185
1189
|
}
|
|
1190
|
+
function renderNotApplicableComment(reason) {
|
|
1191
|
+
return `${WALKTHROUGH_SLOT_MARKER}
|
|
1192
|
+
${WALKTHROUGH_SKIPPED_MARKER}
|
|
1193
|
+
${WALKTHROUGH_COMMENT_HEADING}
|
|
1194
|
+
|
|
1195
|
+
**No E2E run \u2014 not applicable.** ${reason.replace(/\.$/, "")}.
|
|
1196
|
+
|
|
1197
|
+
_The coding agent judged that a browser run cannot exercise this change (\`${"NOT_APPLICABLE" /* NotApplicable */}\`). Muggle did not verify this reason._`;
|
|
1198
|
+
}
|
|
1186
1199
|
function renderUnreasonedSkipComment() {
|
|
1187
1200
|
return `${WALKTHROUGH_SLOT_MARKER}
|
|
1188
1201
|
${WALKTHROUGH_SKIPPED_MARKER}
|
|
@@ -1401,6 +1414,13 @@ var verifyNoAppLogicChange = (context, detail) => {
|
|
|
1401
1414
|
if (appLogicPaths.length > 0) return refuted(`app-logic paths changed since ${sha}: ${namePaths(appLogicPaths)}`);
|
|
1402
1415
|
return verified;
|
|
1403
1416
|
};
|
|
1417
|
+
var verifyNotApplicable = (_context, detail) => {
|
|
1418
|
+
const words = detail.trim().split(/\s+/).filter(Boolean).length;
|
|
1419
|
+
if (words >= MIN_NOT_APPLICABLE_REASON_WORDS) return verified;
|
|
1420
|
+
return refuted(
|
|
1421
|
+
`the reason is ${words === 0 ? "missing" : "too short to weigh"} \u2014 cite it as NOT_APPLICABLE: <why a browser run cannot exercise this change>, in at least ${MIN_NOT_APPLICABLE_REASON_WORDS} words`
|
|
1422
|
+
);
|
|
1423
|
+
};
|
|
1404
1424
|
var VERIFIERS = {
|
|
1405
1425
|
["NO_WEB_SURFACE" /* NoWebSurface */]: verifyNoWebSurface,
|
|
1406
1426
|
["DEV_SERVER_UNREACHABLE" /* DevServerUnreachable */]: verifyDevServerUnreachable,
|
|
@@ -1408,7 +1428,8 @@ var VERIFIERS = {
|
|
|
1408
1428
|
["MUGGLE_AUTH_DOWN" /* MuggleAuthDown */]: verifyMuggleAuthDown,
|
|
1409
1429
|
["NO_PR" /* NoPr */]: verifyNoPr,
|
|
1410
1430
|
["USER_WAIVED" /* UserWaived */]: verifyUserWaived,
|
|
1411
|
-
["NO_APP_LOGIC_CHANGE" /* NoAppLogicChange */]: verifyNoAppLogicChange
|
|
1431
|
+
["NO_APP_LOGIC_CHANGE" /* NoAppLogicChange */]: verifyNoAppLogicChange,
|
|
1432
|
+
["NOT_APPLICABLE" /* NotApplicable */]: verifyNotApplicable
|
|
1412
1433
|
};
|
|
1413
1434
|
function verifyDeclaredSkip(skip, context) {
|
|
1414
1435
|
return VERIFIERS[skip.code](context, skip.detail);
|
|
@@ -1433,7 +1454,7 @@ function explainRejection(judged) {
|
|
|
1433
1454
|
return `That skip declaration states no code. E2E is skipped only by citing one of: ${codeMenu()}.`;
|
|
1434
1455
|
}
|
|
1435
1456
|
if (judged.rejection === "unknown-code" /* UnknownCode */) {
|
|
1436
|
-
return `"${judged.claimedCode}" is not a skip code, so E2E is still owed.
|
|
1457
|
+
return `"${judged.claimedCode}" is not a skip code, so E2E is still owed. Cite one of: ${codeMenu()}. If none of them is true, the run has to happen.`;
|
|
1437
1458
|
}
|
|
1438
1459
|
return `The skip cited ${judged.claimedCode}, but that could not be verified: ${judged.failure}. E2E is still owed \u2014 cite a code that holds, or run it.`;
|
|
1439
1460
|
}
|
|
@@ -2085,7 +2106,7 @@ function e2eGate() {
|
|
|
2085
2106
|
if (decision.action === "none" /* None */) return "{}";
|
|
2086
2107
|
state.e2eBlockCount = decision.blockCount;
|
|
2087
2108
|
writeState(state);
|
|
2088
|
-
const reason = decision.blockCount === 1 ? `Do not end the turn yet. This session went unit-green or opened a PR, but no E2E acceptance run has happened. Per the autoE2ETest preference (default: always), run change-driven E2E now via ${muggleSkill("/muggle:muggle-test")}, then finish.
|
|
2109
|
+
const reason = decision.blockCount === 1 ? `Do not end the turn yet. This session went unit-green or opened a PR, but no E2E acceptance run has happened. Per the autoE2ETest preference (default: always), run change-driven E2E now via ${muggleSkill("/muggle:muggle-test")}, then finish. To skip, run \`echo "MUGGLE_E2E_SKIP: <CODE>: <detail>"\` citing one of ${E2E_SKIP_CODES.join(", ")}. Muggle verifies each code itself, so one that does not hold leaves this gate blocked. Only when no verifiable code fits and a browser run genuinely cannot exercise the change, cite ${"NOT_APPLICABLE" /* NotApplicable */} with the reason \u2014 the PR shows it as your unverified judgment.` : `E2E acceptance run still owed (reminder ${decision.blockCount}/${MAX_E2E_BLOCKS}): run ${muggleSkill("/muggle:muggle-test")}, or cite a verifiable code via \`echo "MUGGLE_E2E_SKIP: <CODE>: <detail>"\`.`;
|
|
2089
2110
|
return blockStop(reason, host);
|
|
2090
2111
|
}
|
|
2091
2112
|
function watchGate() {
|
|
@@ -23,7 +23,9 @@ This stage is **mode-driven by pre-flight**:
|
|
|
23
23
|
|
|
24
24
|
**Every SKIPPED exit from this stage** (Step 0 poll-only, Step 1 `unit-only`/`skip`, Step 1.5 placeholder branch) also runs `echo "MUGGLE_E2E_SKIP: <CODE>: <detail>"` as a single Bash call before exiting — it records the skip in guardrail session state so the Stop-hook E2E gate releases instead of blocking the turn.
|
|
25
25
|
|
|
26
|
-
`<CODE>` is one of `NO_WEB_SURFACE`, `DEV_SERVER_UNREACHABLE`, `EMPTY_DIFF`, `MUGGLE_AUTH_DOWN`, `NO_PR`, `USER_WAIVED`, `NO_APP_LOGIC_CHANGE` — the one list of
|
|
26
|
+
`<CODE>` is one of `NO_WEB_SURFACE`, `DEV_SERVER_UNREACHABLE`, `EMPTY_DIFF`, `MUGGLE_AUTH_DOWN`, `NO_PR`, `USER_WAIVED`, `NO_APP_LOGIC_CHANGE`, `NOT_APPLICABLE` — the one list of skip codes, which other files reference rather than restate — and the guardrail checks it before the gate releases. Every code but `NOT_APPLICABLE` names a fact the guardrail checks for itself, about the environment or about which paths a commit range touched. "Static page", "layout only", "unit tests cover it" and "verified with another tool" are not reasons E2E cannot apply — cite a code that holds, or run the tests. `USER_WAIVED` needs the user's own literal `SKIP E2E` in the transcript, never an inferred go-ahead. A rejected declaration is answered with the check that failed, and the turn stays blocked.
|
|
27
|
+
|
|
28
|
+
`NOT_APPLICABLE` is the last resort, for a change no browser run can exercise and no verifiable code covers — an email template, a backend path the UI never reaches, a scheduled job. Its detail is the reason, in at least four words, and the PR's walkthrough comment shows that reason as the agent's own judgment, marked unverified, for the reviewer to accept or push back on. Never cite it to avoid a run that could happen.
|
|
27
29
|
|
|
28
30
|
`NO_APP_LOGIC_CHANGE` belongs to a watcher cycle's minor tail ([`cycle-size.md`](cycle-size.md)), never to a Stage 6 exit. Its detail opens with the cycle's starting commit. Muggle diffs that commit against HEAD and accepts only when every changed path is docs (`*.md`, `*.markdown`, `*.rst`), tests (`*.test.*`, `*.spec.*`, `__tests__/`, `__snapshots__/`, `__mocks__/`, `test_*.py`, `*_test.py`, `*_test.go`, a root-level `test/` or `tests/`), lint/format config (ESLint, Prettier, Stylelint and markdownlint config or ignore files, `biome.json`, `.editorconfig`), or CI config (`.github/workflows/`, `.gitlab-ci.yml`). A commit it cannot resolve, an empty diff, or any other path — a comment-only edit in a source file included — fails.
|
|
29
31
|
- `staging-replay` is not executed in this stage path and should be surfaced as `INCONCLUSIVE` unless the caller has already routed to a dedicated staging runner.
|