Repository navigation
test(NavigationStack): a push after a heavy commit never skips into its curve - #12990
Conversation
…ips into its curve A 300 ms block in the push's commit, then the pushed card's travelled share and frame time in the first six frames. The first moving frame may show no more of the spring than the time since the frame before it (or since the block ended) allows, plus one frame, and moves by the second frame. Same check in every engine; a guard for the WebKit first-frame question, which did not reproduce on a physical iPhone.
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
|
AI review status for this pull request.
|
|
/approve-spec 4266168 |
PR Analysis Report🔎 Preview ·
|
| Component | Size | LoC |
|---|---|---|
| lab/NavigationScreen | 86.0 kB (0) · 1.5 kB CSS (0) | — |
| lab/NavigationStack | 86.0 kB (0) · 1.5 kB CSS (0) | — |
Package size: no published package changed; no new dependencies.
Not run on this PR: add ci:run-visual for Visual, ci:run-a11y for Accessibility, ci:run-rtl for RTL.
Generated by PR Enrichment workflow | View full report
There was a problem hiding this comment.
Changes requested: the new first-frame guard bounds the push the right way, but it also passes when no push happens at all.
NavigationStack.interaction.browser.spec.ts:1264-1267records a missing pushed card as fully travelled andblockEndfalls back to 0 (:1275-1276), so with no push every assertion passes; record whether each frame found the card, then assertblockEnd > 0and that every frame read it.
Optional: starting the frame reader in the observer callback right after the block would make "moves by the second frame" count from the task rather than from a second page.evaluate round trip, and a small helper would keep the 300 ms mount block in step with the sibling test's copy. The interaction lanes have not run this test yet, because CI skips while the pull request is a draft.
Claims and files checked
Review mode: same-head; reason: none
- Claim: a Playwright interaction test that a push after a heavy commit never skips into its curve: verified (lines 1221-1302).
- Claim: a 300 ms synchronous block in the push's commit, then the card's travelled share and frame time in six frames: verified (lines 1234-1284).
- Claim: the first moving frame shows no more of the spring than the elapsed time allows, plus one frame: verified, with an extra 0.02 tolerance the description does not mention (lines 1292-1301).
- Claim: the card moves by the second frame: false when the card never mounts, since a missing card counts as moved; otherwise counted from the reader's first frame, not from the task.
- Claim: the same check runs in Chromium and WebKit with no engine branch: verified (no engine test in the body; the interaction config has exactly those two projects).
- Claim: it guards the behaviour the closed WebKit workaround proposed, which did not reproduce on a physical iPhone, so no workaround ships: verified against that pull request's test and closing comment; this is its test without the engine branch, and no source file changes here.
- Claim: current code passes the check: verified in Chromium (3 of 3 runs); the Linux WebKit figures fit a spring started at the block's end but were not re-run; the Firefox figures were not re-run, and the config has no Firefox project, as stated.
- Claim: the CI interaction lanes run it on this head: not yet, since they were skipped while the pull request is a draft.
- Claim: test only, with no changeset, source or record change, and no internal context: verified.
- Claim: overlap with the closed WebKit change and the separate Heavy Commit story: verified.
- File
packages/lab/src/NavigationStack/__tests__/NavigationStack.interaction.browser.spec.ts: the blocking finding above and the optional notes.
The frames are read from the task that blocks, and each records whether it found the pushed card. The test asserts that the block ran and every frame found the card. The heavy commit's length is one constant shared with the sibling test.
|
/approve-spec acb400a |
There was a problem hiding this comment.
Changes requested: the new first-frame guard fails in Chromium on main's NavigationStack, and the description's evidence comes from the earlier version of the test.
NavigationStack.interaction.browser.spec.ts:1296fails in the Chromium interaction project onmain's code (5 of 6 runs,Expected: <= 1,Received: 2), because with the reader started inside the blocking task Chromium's first two reads carry frame times from before the block ended and still show the card at rest, so please allow read 2 with its reason (for exampletoBeLessThanOrEqual(2), which passed 8 of 8 runs) or keep only the time-normalized share bound, and re-run both engines.- The description's Chromium and WebKit pass numbers, and its note that this is #12737's test without the engine branch, describe the earlier reader that started after the click, so please re-measure after the fix and update the Evidence and Overlap lines.
The share bound held in every Chromium run, so the guard's main claim looks right. The CI interaction lanes have not run on this head yet because the pull request is a draft.
Claims and files checked
Review mode: same-head; reason: none
- Changed rules (0).
- Adds a Playwright interaction test for a NavigationStack push from rest after a heavy commit: verified (the new test).
- Setup is a 300 ms synchronous block in the push's task, then the card's travelled share and frame time in six frames: verified (the observer, block and reader, and
HEAVY_COMMIT_MS). - The first moving frame shows no more of the spring than the elapsed time allows, plus one frame: verified (the share bound, which also allows 0.02 of slack).
- The card moves by the second frame: false in Chromium at this head (it first moves on the third read).
- The same check runs in Chromium and WebKit with no engine branch: verified (no engine branch or skip; the interaction config has both projects).
- It guards what a closed WebKit-only workaround proposed, which did not reproduce on a physical iPhone, so no workaround ships: verified (that pull request is closed unmerged, and its closing comment says so).
mainpasses in Linux WebKit with the stated numbers: not verified (WebKit could not run in this review), and measured with the earlier reader.mainpasses in Chromium 149 with the stated numbers: false at this head (5 of 6 runs fail).- Firefox numbers from a run outside the repository config: the config has no Firefox project (verified); the numbers were not reproduced.
- The CI interaction lanes run it on this head: not yet (they were skipped while the pull request is a draft).
- Test only, with no changeset, source or record change: verified (one file under
__tests__). - Public text has no internal context: verified.
- Overlap with the closed workaround's test without its engine branch: no longer exact (this head reads frames inside the task and adds the found-card checks); the heavy-commit story is a separate evidence fixture: verified (a story-only draft pull request).
- File
packages/lab/src/NavigationStack/__tests__/NavigationStack.interaction.browser.spec.ts: the two blocking findings above.
…by the third frame The reader starts in the task that commits the push, so its first frame paints the new screen at rest and an input task's push starts a frame later.
|
/approve-spec 182dd05 |
There was a problem hiding this comment.
Changes requested: the first-frame guard passes in Chromium, but the reason it gives for letting the card first move on the third read describes NavigationStack's clock wrongly.
- The comment at
NavigationStack.interaction.browser.spec.ts:1295-1297and the description's Pass-condition bullet say an input task's push starts one frame after the reader's first frame, but the push starts in that first frame (its animation's start time is set about 2 ms after the block ends, astransitionClockand the animator's'next-frame'start document), and the card reads at rest on the second read only because Chromium runs the first two reads after the long task on one frame time, so please keeptoBeLessThanOrEqual(2)and reword the reason in the comment and the description to match.
WebKit still has no result for this head, so please fill in both engines' numbers before you mark it ready.
Claims and files checked
Review mode: same-head; reason: none
- Changed rules (0).
- Adds a Playwright interaction test for a NavigationStack push from rest after a heavy commit: verified (the new test).
- Setup is a 300 ms synchronous block in the push's commit, then the card's travelled share and frame time in each of the first six frames, read from inside that task: verified (the observer, block and in-task reader, and
HEAVY_COMMIT_MS). - The push really happened, because the block ran and every frame found the card: verified (the
blockEndand found-card checks). - The first moving frame shows no more of the spring than the elapsed time allows, plus one frame: verified (the share bound, which also allows 0.02 of slack).
- The card moves by the third frame: verified (the index check; every Chromium run first moved on the third read).
- The first frame paints the new screen at rest and an input task's push starts at the next one: false (the push starts in the first frame after the task; Chromium's first two reads share one frame time).
- The same check runs in Chromium and WebKit with no engine branch: verified (no engine branch or skip; the interaction config has both projects).
- It guards what a closed WebKit-only proposal targeted, which did not reproduce on a physical iPhone, so no engine branch ships: verified (that pull request is closed unmerged, and its closing comment says so).
- Chromium and WebKit runs at this head are pending: verified (CI skipped the interaction lanes while the pull request is a draft).
- Test only, with no changeset, source or record change: verified (one file under
__tests__). - Public text has no internal context: verified.
- Overlap, where this guard replaces the closed proposal's engine-specific test and the heavy-commit story is a separate evidence fixture: verified (the story pull request is an open, story-only draft).
- File
packages/lab/src/NavigationStack/__tests__/NavigationStack.interaction.browser.spec.ts: the blocking finding above.
…ead move The push starts on the first frame after the task. Chromium can run the first two frames after a long task on one frame time, so the card can still read at rest on the second read. Comment only.
|
/approve-spec 21e4d9a |
There was a problem hiding this comment.
Approved pending CI: the first-frame guard now gives the right reason for letting the card first move on the third read, and nothing else needs to change. CI has not run on this head because the pull request is a draft; it runs once the pull request is marked ready for review.
Claims and files checked
Review mode: incremental; reason: none
- Changed rules (0).
- Adds a Playwright interaction test that a NavigationStack push from rest after a heavy commit never skips into its curve: verified (the new test at
NavigationStack.interaction.browser.spec.ts:1223-1312). - Setup is a 300 ms synchronous block in the push's commit, then the card's travelled share and frame time in each of the first six frames, read from inside that task: verified (
HEAVY_COMMIT_MS, the block at:1249-1253, the reader started in the observer callback at:1272). - The push really happened, because the block ran and every frame found the card: verified (
:1290-1291). - The first moving frame shows no more of the spring than the elapsed time allows, plus one frame: verified (
:1306-1311, which also allows 0.02 of slack). - The card moves by the third read; the push starts on the first frame after the task, and Chromium can run the first two frames after a long task on one frame time: verified (
:1295-1298, NavigationStack's clock, and a Chromium probe of the same setup). - The same check runs in Chromium and WebKit with no engine branch: verified (no skip or engine branch in the test; the interaction config has both projects).
- It guards what a closed WebKit-only proposal targeted, which did not reproduce on a physical iPhone, so no engine branch ships: verified (that pull request is closed unmerged, and its closing comment says so).
- All six runs pass, with Chromium first moving on the third read at a share of about 0.08 to 0.10 under a bound of about 0.32: verified (consistent with 16 of 16 Chromium runs of the same code; each Bound value matches the test's formula).
- WebKit first moves on the first or second read, within bounds of about 0.19 to 0.62: the author's runs, consistent with the formula; not reproduced here, and CI has not run.
- Without the click the test fails in both engines, because the frame trace never completes and the wait times out: verified from the code (no card means no reader, so the wait at
:1278-1281runs into the 60 s test timeout). - Test only, with no changeset, source or record change: verified (one file under
__tests__). - Public text has no internal context: verified.
- Overlap, where this guard replaces the closed proposal's engine-specific test and the heavy-commit story is a separate evidence fixture: verified (the story pull request is an open, story-only draft).
- File
packages/lab/src/NavigationStack/__tests__/NavigationStack.interaction.browser.spec.ts: clear.
|
/approve-spec 86c09b9 |
There was a problem hiding this comment.
Approved: the first-frame guard has no open findings, and CI passes on this head, including the new test in both the Chromium and WebKit interaction lanes.
Claims and files checked
Review mode: same-head; reason: none
- Changed rules (0).
- Adds a Playwright interaction test that a NavigationStack push from rest after a heavy commit never skips into its curve: verified (
NavigationStack.interaction.browser.spec.ts:1223-1312). - Setup is a 300 ms synchronous block in the push's commit, with the card's travelled share and frame time read in each of the first six frames from inside that task: verified (
HEAVY_COMMIT_MSat:77, the block at:1249-1253, the reader started inside the observer callback at:1272). - The push really happened, because the block ran and every frame found the card: verified (
:1290-1291). - The first moving frame shows no more of the spring than the elapsed time allows, plus one frame: verified (
:1306-1311, which also allows 0.02 of slack). - The card moves by the third read; the push starts on the first frame after the task, and Chromium can run the first two frames after a long task on one frame time: verified (
:1293-1298and NavigationStack's transition clock,NavigationStack.tsx:772-788). - The same check runs in Chromium and WebKit with no engine branch: verified (no engine branch in the test; it passes in both CI interaction lanes on this head).
- It guards what a closed WebKit-only proposal targeted, which did not reproduce on a physical iPhone, so no engine branch ships: verified (that pull request is closed unmerged, and its closing comment says so).
- Chromium's three runs first move on the third read at a share of about 0.08 to 0.10 under a bound of about 0.32: consistent (each bound matches the test's formula, and the test passes in CI's Chromium lane); the per-run numbers are the author's.
- WebKit's three runs first move on the first or second read, within bounds of about 0.19 to 0.62: consistent (each bound matches the formula, and the test passes in CI's WebKit lane); the per-run numbers are the author's.
- All six runs pass, Chromium's first two reads are at rest, and WebKit's frames after the block are 16 to 58 ms apart: the author's runs, consistent with both CI passes and an earlier Chromium probe of the same setup.
- Without the click the test fails in both engines, because the frame trace never completes and the wait times out: verified from the code (no card means no block and no reader, so the wait at
:1278-1281runs into the 60 s test timeout). - Test only, with no changeset, source or record change: verified (one file under
__tests__). - Public text has no internal context: verified.
- Overlap, where this guard replaces the closed proposal's engine-specific test and the heavy-commit story is a separate evidence fixture: verified (the story pull request is an open, story-only draft).
- File
packages/lab/src/NavigationStack/__tests__/NavigationStack.interaction.browser.spec.ts: clear.
What this adds
A Playwright interaction test for NavigationStack: a push from rest after a heavy commit never skips into its curve.
It guards the first-frame behavior behind a closed WebKit-only proposal (#12737). That skip did not reproduce on a physical iPhone 14 with iOS 26.2, so no engine branch ships, and this test catches a future regression in every engine instead.
Evidence
At this head, 3 runs per engine, workers 1, no retries, stack 370 px:
Scope
NavigationStack.interaction.browser.spec.ts): no Changeset, no source or record change.Overlap checked: #12737 (closed unmerged; this guard replaces its engine-specific test), #12981 (the Heavy Commit story, a separate evidence fixture)