Skip to content

refactor(pr-verify): simplify probe replay.mjs - #14276

Merged
melodic-automation-lanes[bot] merged 1 commit into
mainfrom
work-resolve-issue/issue-14141-42530419235-1
Nov 8, 2026
Merged

melodic-automation-lanes[bot] merged 1 commit into
mainfrom
work-resolve-issue/issue-14141-42530419235-1

Conversation

@melodic-automation-lanes

@melodic-automation-lanes melodic-automation-lanes Bot commented Nov 8, 2026 •

Copy link
Copy Markdown
Contributor

Closes #14141

Summary

Opened by the work-resolve-issue lane. The run's own summary:

Simplified .github/scripts/pr-verify/probe/replay.mjs and kept its behavior the same. scenario reads the issue's comment list once. linesToMessages is a filter/flatMap instead of a push loop. judgeLeg calls transient() once per result. summarize drops its one-line wrapper and uses an ofClass helper for the three class filters. main loads the fixture cases once, finds each case's index once rather than once per run, and turns its two opposite live checks into one if/else. A missing space in MANAGED_PATHS is fixed. Exports, CLI flags, printed text and written files are unchanged.

Not verified

  • node --test for .github/scripts/pr-verify/probe/replay.test.mjs and parity.test.mjs was not run: this lane cannot run node, so the PR's CI (test-node) runs them
  • tidy skipped: the change is under .github/, a shared path the tidy cutoffs exclude
  • ci-status green on the PR is left to the PR's CI

Fix

  • .github/scripts/pr-verify/probe/replay.mjs: hoisted the issue comment list in scenario; rewrote linesToMessages as filter/flatMap; judgeLeg works out the transient status once; summarize uses scored.filter directly plus an ofClass helper; main loads cases once, computes each case index outside the…

Verification

The runner ran each check from the base copy against 279b7a1:

  • scripts/check-changelog-fragments.sh --check: passed
  • scripts/check-changed-skills.sh --merge-base: passed

The run reports:

Left out: the items under Not verified.

Related

#14141

Merge-Risk: max=LOW demote=false head=279b7a1032726f547e3932cdf75a7f812b74f90a rubric=8.1.2 rater=claude-opus-5-5 checker=claude-opus-5-5

Lane-Activity: work-resolve-issue/resolve-issue
@github-actions

github-actions Bot commented Nov 8, 2026

Copy link
Copy Markdown
Contributor

claude-security-review reviewed 279b7a1032726f547e3932cdf75a7f812b74f90a: read 1 of 1 changed file(s); 0 finding(s), 0 as inline comments.

Security review: PR #14276 (refactor(pr-verify): simplify probe replay.mjs)

No security issues found.

critical-findings: 0

I read every hunk of the one changed file, .github/scripts/pr-verify/probe/replay.mjs. It matches none of the listed trusted-path globs. The listed pr-verify entries are only resolve-pr.mjs and write-verdict.mjs, and this probe script is neither of them.

The change is a refactor of the offline probe or replay harness. It does not change what the script does:

  • scenario: the issue comment list (issue.comments ?? []) is read once instead of twice. The mapped values are the same.
  • linesToMessages: the push loop becomes filter/flatMap. Blank lines are still skipped and non-JSON lines are still dropped.
  • judgeLeg: transient() is called once and its result reused. The outcome and reason are the same for a transient status, an error_during_execution subtype, and anything else.
  • summarize: the inline of wrapper is replaced by direct scored.filter calls plus an ofClass helper. The same filters run.
  • main: loadCases() runs once and each case's index is computed once outside the run loop. The two opposite values.live checks become one if/else, which behaves the same.
  • MANAGED_PATHS: whitespace fix only. The paths are unchanged.

Nothing here touches a token, a secret, a trust-control file, a merge hold, a workflow trigger, a permission, or a plugin manifest. No new input reaches a shell or a file path: the quote(opts.workRoot) call in the printed cleanup hint is unchanged. No instruction surface is deleted or softened.

PR context: the closing issue's body was left out by the wrapper because its author is not on the allow list. The PR description contains no embedded directives aimed at this lane.

This is the first review of this pull request (no earlier heads reviewed, not blocking only).

@github-actions

github-actions Bot commented Nov 8, 2026

Copy link
Copy Markdown
Contributor

claude-review reviewed 279b7a1032726f547e3932cdf75a7f812b74f90a: read 1 of 1 changed file(s); 0 finding(s), 0 as inline comments.

Code review: PR #14276, refactor(pr-verify): simplify probe replay.mjs

No findings. I read every hunk of the one changed file, .github/scripts/pr-verify/probe/replay.mjs, and checked each one against the code at head. Every hunk keeps the old behaviour.

  • scenario: the code now reads issue.comments ?? [] once and reuses it. The new comments name doesn't shadow anything else in the function, since prComments still reads testCase.spec.pr.comments directly.
  • linesToMessages: the new filter/flatMap produces the same array as the old push loop. It skips blank lines and drops lines that aren't JSON, as before.
  • judgeLeg: transient() (replay.mjs:499) only returns true for an integer status of 429 or 500–599. So transientStatus is never null or undefined when the check passes, which means transientStatus !== null matches the old transient(...) test and transientStatus ?? result.subtype gives the same reason text.
  • summarize: the five sets are built by the same filters over scored, now written inline or through ofClass. The returned shape is unchanged.
  • main: loadCases() now runs once. cases and all now hold the same objects, and the code only reads them: findIndex matches by id. Hoisting the index out of the per-run loop gives the same value. Errors are raised in the same order as before, because the first loadCases() call already ran before the yq and git calls. Replacing the two opposite values.live checks with one if/else is equivalent.
  • MANAGED_PATHS: the only change is the added space.

Closing issue #14141 acceptance criteria

  • Behavior unchanged; same exports, CLI flags, files and printed text: met, based on reading the code. I did not run replay.test.mjs or parity.test.mjs. The author says the work-resolve-issue lane couldn't run node either; CI's test-node job is left to confirm it.
  • The diff edits only the listed files: met. Only replay.mjs changes.
  • Within 400 lines and 15 files: met. One file, about 57 changed lines.
  • ci-status green: I can't see CI from this lane. That is left to the PR's checks.

No changelog fragment is needed, since the change is under .github/ and not in a plugin. No plugin manifests changed. No .claude/rules/ path rules were applied. The PR context contains no embedded instructions aimed at this lane.

@melodic-automation-lanes

Copy link
Copy Markdown
Contributor Author

The unattended merge path armed native auto-merge at head 279b7a1032726f547e3932cdf75a7f812b74f90a, the head its arming checks judged.

@melodic-automation-lanes

Copy link
Copy Markdown
Contributor Author

Verification evidence for 279b7a1

The verifier passed this head. The capture artifact holds the capture summary, which says whether the capture ran, and any screenshot or video that passed the mask check; this comment uploads no file.

Capture artifact: pr-capture-14276-279b7a1032726f547e3932cdf75a7f812b74f90a, expires on 2026-12-08.

One comment per pull request, updated in place for each new head.

@melodic-automation-lanes
melodic-automation-lanes Bot added this pull request to the merge queue Nov 8, 2026
Merged via the queue into main with commit ad2ee4c Nov 8, 2026
63 checks passed
@melodic-automation-lanes
melodic-automation-lanes Bot deleted the work-resolve-issue/issue-14141-42530419235-1 branch November 8, 2026 23:36
@melodic-automation-lanes

Copy link
Copy Markdown
Contributor Author

The post-merge check verified merge commit ad2ee4ced5b97c5c61444b67b5e0ef8846b7c622; later checks count it verified from this comment.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Simplify .github: replay.mjs

0 participants