Skip to content

ci: the code editor's phone-sheet completion test fails now and then #4993

Closed

Description

@yannickmonney

Summary

packages/ui browser test CodeEditor completion › closes the list before the sheet, at phone width failed once in main's push Checks (job Browser) and passed on the next main commit, which did not change the editor or the test. Per .github/RELEASING.md ("A release that has to go out", step 2), a failure that the same source also passes is a flake and needs an issue that tracks it. This is that issue.

What the repo says today (main at 004953f)

  • packages/ui/src/components/forms/code-editor/code-editor.browser.test.tsx:1063 declares the test. At 375 × 800 it opens the completion list inside a ResponsiveDialog sheet and checks that the list sits inside the sheet before pressing Escape.
  • code-editor.browser.test.tsx:1096-1097 already notes the race: "CodeMirror places it a frame after it appears, so a busy machine can read it still unplaced". The check at :1099-1102 therefore runs inside waitFor.

What was observed

Run Source Result
Checks 38611880265, job Browser (push, 2026-10-14 18:04Z) 56c44e3 1 failed, 714 passed: AssertionError: expected 0 to be greater than or equal to 220.40625
Checks push run on the next commit (2026-10-15 05:53Z) 004953f Browser passed
  • git log 56c44e3832..004953f62f -- '*code-editor*' is empty, so the passing run had the same test and the same editor.
  • The list's top was still 0 (unplaced) when waitFor gave up, so in that run the list was not placed within waitFor's timeout.
  • Of the 25 most recent failed Checks runs (snapshot 2026-10-15 ~06:30Z), this test failed only in 38611880265.

Not examined: whether the list is placed late in the product too, under the same load (only the test run was seen), and how loaded the runner was during the job.

Constraints

  • The test protects a real behaviour: the completion list must render inside the phone sheet, and Escape must close the list before it closes the sheet.
  • RELEASING.md forbids waiving a failed check. A release candidate that meets this flake needs a full re-run of that run, so a flake here costs a release attempt.

Options

  1. Wait for placement before asserting: for example a waitFor with a longer timeout, or first wait until the list has a non-zero top, then compare it with the sheet.
  2. Assert placement through CodeMirror's own state, such as a positioned tooltip or an requestAnimationFrame flush, instead of geometry read at an arbitrary moment.
  3. Leave it and re-run on recurrence, counting occurrences here.

Related

Activity

  1. added
    agent-ready
    on Oct 29, 2026
  2. added a commit that references this issue on Oct 30, 2026
    69c92b3
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    agent-readybug

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions