Skip to content

test: judge a re-timed carry's step from the node's first carried reading in the shift watch - #6729

Merged
max-sixty merged 1 commit into
mainfrom
fix/issue-6609
Nov 22, 2026
Merged

max-sixty merged 1 commit into
mainfrom
fix/issue-6609

Conversation

@leaf-agent

Copy link
Copy Markdown
Collaborator

The shift watch refused box-motion's carry of the thread view's growth when the carry's first animation sample came from a read that reads no nodes. It then reported the panel's head and messages as "moved without input" by the whole step. This is the 1-in-40 failure of test_a_website_turn_posts_its_answer_when_the_move_is_settled_first[here] on CI's Mac. carriesWithin now reads where the step put the node at the node's first reading once the carry drew, instead of at the carry's first sample.

Cause. When the last reading before a carry already holds the layout step, carriesWithin steps back one reading to find where the node stood before it. It recognises that reading by comparing it with landed: the node's layout at the carry's first sample (animated[1].at), net of the carry. Some reads sample animations without reading nodes, such as the cancel that re-times a carry (Animation.prototype.cancel). When the first sample comes from one of those reads, the node's ledger at that time still holds it where it stood before the carry drew. So landed came out as the step less the carry, the held reading never matched it, and the comparison started from the grown layout.

Evidence. A macOS flake run on main plus logging (exp/6609-carries) failed 1 of 54 copies. For the Back button it logged readings 723 → 646 → 723, carry began 1890.4, first sample 1941.3, and the node's carried reading at 1942.9. That gives landed 569 = 646 − 77, which doesn't match the held 646, so the carry was refused. The same comparison with the landing read at 1942.9 gives 723 − 77 = 646, which matches.

Test. The new retimed case of test_a_carry_draws_the_way_of_a_step_news_may_take cancels the carry and begins it again in the delivery that began it. It fails on main 3 of 3 runs (button#head moved without input by (0, 40)) and passes with the change. The other carry cases, including the faulted ones that must still fail, and #6649's test_a_reply_that_lands_mid_carry_continues_it pass (61 tests). Whether the journey test is clean on the Mac is left to a 54-copy flake dispatch on this branch.

Closes #6609 — automated triage

…ding

`carriesWithin` decides whether a carry box-motion began keeps a node
within the layout step it draws. When the last reading before the carry
already holds the step, it steps back one reading to find where the node
stood before the step. It recognises such a reading by comparing it with
where the node "landed": its layout at the carry's first sample, net of the
carry. That sample can come from a read that reads no node, such as the
one cancelling a carry to re-time it takes, so the ledger at that time still
held the node before the carry drew. The landing then read as the step
less the carry, the held reading never matched it, and the watch refused
the carry and reported the node as moved without input by the whole step.

The landing is now read at the node's first reading at or after that
sample. The new `retimed` case of
`test_a_carry_draws_the_way_of_a_step_news_may_take` cancels and
re-begins the carry in the delivery that began it. It fails on the old
watch on every run (`button#head` moved without input by (0, 40)) and
passes with this change.

This is the failure `test_a_website_turn_posts_its_answer_when_the_move_is_settled_first[here]`
showed on CI's Mac: logged inputs showed `landed` 569 against a held reading
of 646 for a 77 px carry.

Closes #6609
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.

test_a_website_turn_posts_its_answer_when_the_move_is_settled_first[here]: the panel's Back button moves 77 px without input on macOS

2 participants