Skip to content

chore(e2e): upgrade Midscene to 1.13.0 (verification only) - #43

Merged
quanru merged 58 commits into
mainfrom
chore/upgrade-midscene-1.13.0
Sep 26, 2026
Merged

quanru merged 58 commits into
mainfrom
chore/upgrade-midscene-1.13.0

Conversation

@quanru

@quanru quanru commented Sep 21, 2026

Copy link
Copy Markdown
Owner

Summary

Verification-only PR — do not merge yet.

  • Upgrades @midscene/test / @midscene/computer from 1.12.9 → 1.13.0 (tests/e2e/package.json, lockfile updated, tsc --noEmit passes locally).
  • 1.13.0 unifies native Test and legacy YAML execution/reporting (#3139) — since this project runs YAML cases and post-processes the native HTML reports (report-cases.mjs / capture-report-preview.mjs / Pages summary), both visual workflows need to run to confirm report parsing, screenshots and runner-step deep links still work.
  • New model backend in use: DeepSeek family on Volcengine Ark (deepseek-v4-1-flash), configured via the existing MIDSCENE_MODEL_* secrets.
  • Adds a main-only guard to the Pages deploy job: PR runs execute every shard and publish the report artifact + run summary, but do not write validation runs to the public Pages history.

Validation

  • Ubuntu 22.04 visual workflow (4 product shards + polishing)
  • Omarchy 4.0.3 visual workflow (4 product shards + shell)
  • Report bundle / CI summary renders with 1.13.0 HTML
  • Pages deploy job is skipped on this PR

This branch will not be merged into main until results are reviewed.

🤖 Generated with Claude Code

quanru and others added 6 commits September 21, 2026 11:17
Bumps @midscene/test and @midscene/computer from 1.12.9 to 1.13.0
(v1.13.0 unifies native Test and legacy YAML execution/reporting,
which is the path these YAML cases use).

Co-Authored-By: Claude Code <noreply@anthropic.com>
Pull-request runs still execute every shard and produce the report
artifact and run summary, but no longer write validation runs into
the public Pages report history.

Co-Authored-By: Claude Code <noreply@anthropic.com>
The Volcengine Ark endpoint backing MIDSCENE_MODEL_* is limited to
~25-35 RPM; ten concurrent visual jobs (two five-shard workflows) hit
429 RateLimitExceeded.EndpointRPMExceeded within minutes. Temporary,
intentionally easy-to-revert changes:

- Ubuntu workflow: drop push/pull_request triggers, keep
  workflow_dispatch so it can still be run manually; matrix, polishing
  and Pages wiring are untouched.
- Omarchy workflow: max-parallel 5 -> 1 (jobs queue one after another;
  expect ~110-120 min wall time since each job restores the 3.8 GB VM).
- Both workflows: retry model calls up to 3 extra times with a 65s
  fixed pause, spanning the 60s RPM window.
- Restore the trusted-PR Pages publish condition on both workflows,
  undoing the main-only guard from 95348ea (same-repo PRs must get a
  summary per the report-history contract).
- Docs: document the temporary scheduling and how to restore it, and
  fix stale --project ubuntu examples (the projects are sharded).

To restore: reinstate the Ubuntu on: block from git history and set
Omarchy max-parallel back to 5 (requires ~150 RPM / ~1M TPM).

Co-Authored-By: Claude Code <noreply@anthropic.com>
Midscene 1.13.0 writes durationMs on every embedded run level;
expose each case's last-attempt duration through the report pipeline:

- report-cases: carry attempt.durationMs on every extracted case.
- Pages builder: manifest v6 with optional durationMs (v1-v5 still
  accepted), shared formatDuration helper (52s / 1m23s), new Duration
  column on the run detail table.
- CI summary: pass-rate headline, per-entry counts, Failures table
  with duration and reason, failed-screenshot grid expanded by
  default, all-screenshots and passed-cases grids behind <details>.
- Contracts: anchor the max-parallel assertion to a real YAML line,
  cover durationMs in fixtures/manifest expectations, and assert the
  new summary layout for the all-passing and single-failure runs.

Co-Authored-By: Claude Code <noreply@anthropic.com>
The first serialized Omarchy shard passed its cases (2/2, with an
endpoint 429 retried successfully) but failed "Capture report
evidence": 1.13.0 stores report screenshots in a sibling screenshots/
directory (data-screenshot-mode="directory") instead of inlining them
as <script type="midscene-image"> blocks, so evidence extraction found
no embedded image for the selected steps.

- omarchy-shell-evidence: add loadReportImages() reading inline images
  first then filling gaps from screenshots/<id>.{jpeg,jpg,png,webp};
  findShellReport becomes async and preloads both sources.
- report-cases: reportCases() becomes async; pass the HTML file path
  so directory images resolve relative to the report.
- build-pages-report: filter candidate HTMLs to runner dumps (1.13.0
  renames the test report directory midscene-e2e-*, which also exposes
  standalone computer-*.html agent reports without a runner dump);
  publish screenshots/ next to native reports and list those files in
  manifest.files so history restore fetches them; await the now-async
  report entry/group builders.
- capture-report-preview: pass reportFile to reportCases.
- verify-pages-report: accept .jpeg content type.
- Contracts: await async reportCases; add directory-mode coverage for
  case evidence, shell evidence, and Pages publishing plus .jpeg content
  type; runnerScript fixture gains a screenshotMode option.

Co-Authored-By: Claude Code <noreply@anthropic.com>
reportCases became async for directory-mode screenshots, but the
capture CLI still iterated its return value synchronously:
"TypeError: reportCases is not a function or its return value is not
iterable". The contract suite covers the library but not the CLI
entrypoint, which is why local tests missed it.

Co-Authored-By: Claude Code <noreply@anthropic.com>
EOF && git push origin chore/upgrade-midscene-1.13.0 2>&1 | tail -2
Disable idle screensaver in onboarding VM sessions, use a fixed tap for the repeatedly mislocated polishing switch, and keep voice-test controls on screen before tapping Finish.
Avoid flash-model center-screen mislocations in the failing trigger case by using the fixed VM dropdown and GTK keyboard navigation. Keep the existing visual assertions on the resulting UI.
@quanru
quanru merged commit f09da52 into main Sep 26, 2026
16 checks passed

This branch was successfully deployed

1 active deployment
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.

1 participant