Repository navigation
fix(platform): keep sandbox row menus open and settle the connect audit - #4961
Merged
Merged
Conversation
useMutation returns a new object on every render, and the table's column definitions depended on those objects. TanStack renders a cell function as a component type, so a new definition remounted every cell: an open row menu closed and focus went to the page whenever the component re-rendered, for instance when the reconcile request settled just after the menu opened. The columns now depend on the stable async triggers. The stop-task suite hit it on loaded runners: it failed about half the runs of UI shard 3/4 in CI, and 12 of 12 when twelve copies ran at once locally (the trigger was gone from the page, the menu never opened). Its query mock also built new data on every call, which a cache never does; each read now keeps one identity. The same twelve copies pass.
axe skips a fully transparent dialog and fails a nearly transparent one. CI starts the audit a few frames into the dialog's fade, so it judged the text at a few percent (1.07:1) in the connected case, in both themes. Locally the audit starts at the first frame and passes. With the fade stretched and the audit started 60 ms in, the old test fails all four cases with the same reading. Wait for the animations that end; the waiting dot pulses for good and would never settle.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Two heavy-tier failures that red
mainand every merge group, both from tests that landed without the heavy tier running. Both fail only on a loaded runner; each is reproduced locally and fixed.Sandbox row menu closes under a re-render (
sandboxes-settings.stop-task.test.tsx, from #4263; UI shard 3/4 failed about half the runs, infrmostly, last in the queue).useBackendActionreturns the rawuseMutationresult, which React Query v5 rebuilds on every render ({ ...result, mutate, mutateAsync: result.mutate }). The table's column memo depended onstopandsetPinned, so every render produced new column definitions, and TanStack renders a cell function as a component type: every cell remounted, an open row menu closed and focus went to the page. In the suite the reconcile request settles just after the menu opens. A probe on a copy of the test showed the trigger node gone (connected=false, focus onbody) right afteraria-expandedturned true. This is also real behaviour: an admin's open row menu closes whenever the page re-renders. The columns now depend on the stablemutateAsynctriggers, and the suite's query mock returns one identity per read, as the cache's data does.Connect dialog audit (
connect-agent-dialog.browser.test.tsx, from #4958; Browser job, "connected" case, both themes). The audit starts a few frames into the dialog's fade-in: axe skips a fully transparent element and fails a nearly transparent one, so CI read the text at a few percent (1.07:1). Locally axe starts at the first frame and passes. The test now waits for the animations that end (the waiting dot pulses for good).Verified:
settings/sandboxespass, plus the stop-task browser file (15).app/finds no other column memo that depends on a mutation object.Not run locally: the full
bun run checkand the heavy tier (the PR's fast tier and the merge group run them).