Repository navigation
ci: refresh the recorded interaction test times weekly from main's full runs, with an early warning under nine in ten - #12760
Conversation
…ll runs, with an early warning under nine in ten
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
|
AI review status for this pull request.
|
|
/approve-spec da73cc2 |
PR Analysis Report🔎 Preview ·
|
| Before | After | Change | |
|---|---|---|---|
| Job-minutes per PR update | 173.5 | 173.5 | 0 |
| Runner pool, runner-minutes a day | 51,781 | 51,781 | 0 (0%) |
| Average concurrent jobs | 36 | 36 | 0 |
| Time to green (median → this run) | 27.8 min | 6.3 min | −21.6 min |
| Runs a day | 298 | 298 | 0 |
Other workflows: interaction-record-refresh.yml added: runs on schedule (23 11 * * 1), workflow_dispatch; standard runners; its minutes are not measured here
Not measured (the jobs that use these keep their recent minutes above): .github/scripts/interaction-record-refresh.mjs, .github/scripts/interaction-record-refresh.test.mjs, .github/scripts/node-record-refresh.mjs.
Assumptions: before is each job's average over the last 20 pull-request runs; after keeps that for unchanged jobs and uses this run's minutes for added or changed ones, weighted by how often each changed job ran in those runs; runs a day averages the seven whole days before today; time to green compares this run with the median of those runs that ran the same jobs.
Generated by PR Enrichment workflow | View full report
…ee latest full runs, and the refresh pull request names its fixed branch
|
/approve-spec 34200c8 |
There was a problem hiding this comment.
Changes requested: the weekly interaction-times refresh has an engineering owner's approval at this head, and two fixes remain before it can be approved.
- The WebKit lane reads only one page of main's latest 100 successful
ci.ymldispatches (interaction-record-refresh.ymlline 60), which at main's current dispatch rate holds at most two weekly WebKit runs, so its times take the mean of two runs while the workflow header and the description promise a median of three; page through the runs until each lane has three, or say that WebKit uses the weekly runs in that window. openOrRefreshininteraction-record-refresh.mjs(lines 113-146) copies the one innode-record-refresh.mjsline for line; give that helper a branch option (or move it to a shared module), call it from both scripts, reuse itspercent(), and delete the copy.
Also worth fixing: each run's refreshed seconds-per-test value never reaches the record, and the workflow comment should say, as the Node refresh does, that a pull request opened with the workflow token starts no CI until someone with write access reopens it.
Claims and files checked
Review mode: full; reason: no-earlier-review
- Claims:
- Runs weekly on Monday at 11:23 UTC or on demand: verified (
interaction-record-refresh.yml:18-21, workflow test). - Finds each lane's three latest successful full runs by run name: false for WebKit (one page of 100 dispatches; the description's own run found two), the first finding.
- Records each run separately with the planner's recorder from each leg's full job log: verified (
interaction-record-refresh.yml:66-80). - Keeps each spec's median and leaves the record format unchanged: verified (
interaction-record-refresh.mjs:45-62and:177-180, median tests). - Reports coverage in the step summary, with a warning-only early warning under nine in ten: verified (
interaction-record-refresh.mjs:187-200, coverage tests). - Force-updates one fixed branch, keeps its commit when it already carries the record, opens or refreshes one pull request, and never pushes to main: verified (
interaction-record-refresh.yml:93-115, pull request and no-push tests). - Same shape as the Node record refresh: verified for the branch, pull request and permissions; its pull request helper is copied rather than shared, the second finding.
- An earlier ruling covers refresh pull requests: not verifiable from the repository.
- The refresh pull request body names the runs, coverage and fixed branch and asks for a review at each head: verified (
interaction-record-refresh.mjs:89-105, body test). - Ten tests pass: verified at this head.
- A local record run timed 127 of 130 specs on both lanes: not reproduced, since it needs main's job logs; its two-run WebKit count supports the first finding.
- WebKit times 100 of 130 specs today and trips the warning at 76.9%: verified at this head.
- Prettier and actionlint are clean: Prettier verified; actionlint not run here, and the run scripts parse as bash.
- A changed spec reaches the record once two of three sampled runs carry it: verified for Chromium; WebKit with two runs takes their mean.
- One short weekly job that reads logs and runs no tests: verified (no test step).
- Runs weekly on Monday at 11:23 UTC or on demand: verified (
- Files:
.github/workflows/interaction-record-refresh.yml: first finding; the CI-start comment (non-blocking)..github/scripts/interaction-record-refresh.mjs: second finding;seconds-per-testnot carried (non-blocking)..github/scripts/interaction-record-refresh.test.mjs: clear.
…e median time a test too, shares the Node refresh's pull request helper, and says a token-opened pull request needs a reopen for CI
|
/approve-spec 48253bf |
There was a problem hiding this comment.
Changes requested: the weekly interaction-times refresh has an engineering owner's approval at this head, and both fixes from the last review are in, but two new fixes remain.
- Miss:
coverageOfininteraction-record-refresh.mjs(lines 73-77) and itsMIN_TIMED_SHARErepeatcoverageandMIN_RECORDED_SHAREfromnode-record-refresh.mjs, the module this script already imports from, so givecoveragea minimum-share option (asopenOrRefreshgainedbranch), call it with 0.9, and delete the copy. - The description's overlap line says #11910 and #11921 touch a different record and script, but this head changes
node-record-refresh.mjs, which both of them change (they still merge cleanly), so please correct that line.
Also worth fixing, both missed by the last review: the early warning says every untimed spec is costed at the mean time a test, but the planner first uses the other browser's recorded time (Chromium times 27 of the 30 specs WebKit lacks), and the CI impact: line could add the runner class, the pull-request job-minutes and the time to green. CI has not run on this draft yet.
Claims and files checked
Review mode: incremental; reason: none
- changed rules (0): none
- Claims:
- Nothing kept the recorded interaction times current, and a stale Chromium time let a leg overrun its job until a hand re-record: verified (no refresh workflow on the base; the earlier re-record's description).
- WebKit times 100 of 130 interaction specs and trips the warning at 76.9%: verified (the coverage command at this head).
- Runs weekly on Monday at 11:23 UTC or on demand: verified (workflow lines 21-25, workflow test).
- Finds each lane's up to three latest successful full runs by run name among 600 dispatches: verified (workflow lines 66-67, the run names in
ci.yml). - Records each run on its own with the planner's recorder from each leg's full job log: verified (workflow lines 72-88).
- Keeps each spec's median and the median mean time a test, with the record format unchanged: verified (script lines 48-66 and 133-152, median tests, the median command on a scratch record).
- Reports coverage in the step summary with a warning-only early warning under nine in ten: verified (script lines 160-172, coverage tests, exit 0).
- A pull request opened with the workflow token starts no CI until someone with write access reopens it, as the workflow and the body say: verified (workflow lines 15-17, script line 109).
- Force-updates one fixed branch, keeps its commit when it already carries the record, opens or refreshes one pull request and never pushes to main: verified (workflow lines 99-121, tests).
- Same shape as the Node refresh, under an earlier ruling on refresh pull requests: the shape is verified; the ruling is not in the repository and is not relied on.
pruses the Node refresh'sopenOrRefresh, whose newbranchoption keeps the Node branch by default, and itspercent: verified (node-record-refresh.mjsline 192, script line 29).- The body names the runs, the coverage lines and the fixed branch, and asks for a review at each head: verified (script lines 93-111, body test).
- Ten tests cover the median, the warning, one open pull request, the body and the workflow contract: verified (10 pass).
- A local record run timed 127 of 130 specs on both lanes: not reproduced, since it needs main's job logs.
- Prettier is clean and this script's 10 tests plus the Node refresh's tests pass (38): verified; actionlint was not run here, and the run scripts parse as bash.
- A changed spec time reaches the record once two of three sampled runs carry it: verified for three runs; with two runs it moves halfway at once.
- One short weekly job that reads logs and runs no tests: verified (no test step); runner class, pull-request minutes and time to green are left implicit.
- The overlap check found the two Node refresh pull requests touch a different record and script: false, the second finding.
- Files:
.github/scripts/interaction-record-refresh.mjs: first finding; the early-warning wording (non-blocking)..github/scripts/node-record-refresh.mjs: the optionalbranchkeeps the Node refresh unchanged;coveragehere is the helper to extend (first finding)..github/workflows/interaction-record-refresh.yml: clear..github/scripts/interaction-record-refresh.test.mjs: clear.
…wn bar, and its warning names the other browser's time as the first fallback
|
/approve-spec 1932855 |
There was a problem hiding this comment.
Approved pending CI: CI has not run on this head yet because the pull request is a draft; marking it ready for review starts it, and the merge guard waits for the required checks.
Both fixes from the last review are in: the interaction refresh now uses the Node refresh's coverage at its own nine-in-ten bar, and the description's overlap note matches the two open Node-refresh pull requests, which still merge cleanly with this head. An engineering owner's approval at this exact head records the decision for the weekly refresh, which no current CI spec clause covers.
Claims and files checked
Review mode: incremental; reason: none
- Changed rules (0): none.
- Claim: stale Chromium times let a leg run into the 15-minute job limit, fixed by hand earlier. Verified against that fix's description.
- Claim: the WebKit record times 100 of 130 interaction specs. Verified at this head (76.9%).
- Claim: the workflow runs Mondays at 11:23 UTC or on demand. Verified in its schedule.
- Claim: each lane takes up to three latest green full runs of main from its latest 600 dispatches, by the CI workflow's run names. Verified against the workflow and the CI run names.
- Claim: each run is recorded on its own from each leg's complete job log with the existing recorder. Verified (the recorder writes in a scratch copy per run).
- Claim: the record keeps each spec's median and the median time a test, in the same one-number-per-spec format. Verified in the script and its tests.
- Claim: coverage goes to the step summary, with an early warning under nine in ten that never fails the job. Verified by running the coverage command at this head.
- Claim: a pull request opened with the workflow token starts no CI until someone with write access reopens it, as the workflow and body say. Verified (CI listens for reopened pull requests).
- Claim: a changed record force-updates one fixed branch, keeps its commit when unchanged, opens or refreshes one pull request, and never pushes to main. Verified in the push step and the tests.
- Claim: the shape matches the Node record refresh. Verified; the cited ruling on refresh pull requests is not in the repository, and the review does not rely on it.
- Claim: the script reuses the Node refresh's coverage, pull-request helper and percent formatting, and the two new options keep their defaults. Verified.
- Claim: the warning describes how the planner costs an untimed spec. Verified against the planner's fallback order.
- Claim: ten tests cover the median, the warning, one open pull request, the body and the workflow contract. Verified: ten pass.
- Claim: a local re-record from three nightly and two weekly runs times 127 of 130 specs in each lane. The runs are confirmed green on main; the counts were not reproduced.
- Claim: Prettier is clean and this script's and the Node refresh's tests pass (38). Verified; actionlint was not rechecked.
- Claim: the CI impact is one weekly job of about five minutes, with no change to pull-request job-minutes or time to green. Verified (schedule and dispatch only).
- Claim: both open Node-refresh pull requests change the same script, each merges cleanly with this one, and they conflict with each other. Verified with a merge of each.
- File
.github/workflows/interaction-record-refresh.yml: clear. - File
.github/scripts/interaction-record-refresh.mjs: clear. - File
.github/scripts/interaction-record-refresh.test.mjs: clear. - File
.github/scripts/node-record-refresh.mjs: clear.
Who this helps
Authors whose pull request runs the interaction suite. Its legs split the specs by
.github/playwright-leg-durations.json, and nothing kept those times current. The Chromium times went 10 days stale, and one leg planned at about 7.7 minutes ran its tests for 13.6 and hit the 15-minute job limit (fixed by hand in #12703). The WebKit times cover only 100 of today's 130 interaction specs.What changes
.github/workflows/interaction-record-refresh.yml(new; weekly on Monday 11:23 UTC, or on demand):interaction-full), WebKit from "WebKit weekly of …";playwright-legs.mjs record --key interaction-chromium --project chromium, and the same for WebKit), from each leg's complete job log in a file of its own;seconds-per-test, the cost of an untimed spec), viainteraction-record-refresh.mjs median, so one slow or fast run does not move a time alone. The record format is unchanged: one number per spec;ci/interaction-durations-refresh(keeping the commit when the branch already carries the record) and opens the one durations-only pull request, or refreshes the open one. It never pushes to main. This is the same shape as the Node record refresh, and the 11/15 ruling on durations-refresh pull requests covers it..github/scripts/interaction-record-refresh.mjs:median(each spec's median over the runs that timed it),coverage(the share and the warning) andpr. It calls the Node refresh's owncoverage, which gains aminShareoption (called with nine in ten here; its default stays the Node bar), itsopenOrRefresh, which gains abranchoption (default unchanged), and itspercent. The warning says an untimed spec is costed at the other browser's time first, else at its tests times the mean time a test, as the planner does. Its body names the runs, the coverage lines and the fixed branchci/interaction-durations-refresh, and says each refresh needs a review at its new head.interaction-record-refresh.test.mjs, 10): the median (odd and even counts, a spec only one run timed); the warning below nine in ten and quiet at it; one open pull request at most; the body; and the workflow contract (weekly schedule, permissions, ci.yml's run names, leg job patterns, the recorder calls, and no push to main).Evidence
Known limit: a spec whose time changes on main reaches the record once two of its lane's three sampled runs carry it. For example,
LightboxPagingchanged at 14:11Z today (#11539), after the latest nightly: 180 s in the nightlies, 403 s in #12644's run. Monday's refresh samples the weekend's nightlies.CI impact
CI impact: one job a week on
ubuntu-latest, about 5 minutes (setup plus about 30 log downloads); it runs no tests. Pull-request job-minutes and time to green are unchanged: it starts no pull-request run itself, and the refresh pull request it opens runs CI only when someone reopens it.Overlap checked: #11910, #11921 (our own Node record refresh changes). This pull request also changes
node-record-refresh.mjs, which both of them change, but only by adding two options with unchanged defaults (openOrRefresh'sbranchandcoverage'sminShare). This pull request merges cleanly with each of them (#11910 and #11921 conflict with each other, and land in turn).Owning session: noopbot (a61f66c2), under CI & Release (ca77f950). Land path: the shipper, through merge-guard, on green, CodeBunny approval and Specs' exact-head
/approve-spec.