Skip to content

ci-fix: margin refresh intermittently exceeds layout budget #2793

Closed

Description

@leaf-agent

Main CI run 38482557053 failed test_unchanged_margin_passes_over_the_corpus_do_bounded_work_and_write_nothing: five synthetic resize events counted 69 browser layouts against the test's limit of 40. The assertion protects bounded layout work on the example corpus during margin refreshes. The preceding completed main run passed this case; on current main, the same focused test passed three consecutive local runs. The failure is intermittent, and a passing retry does not explain which work the CDP counter included in the failing run.

The run's other four failing cases are addressed by merged #2788; all four pass together on current main. I made no change to the margin test because increasing its budget or dropping the browser work assertion would weaken the behavior it protects without identifying the extra layouts. The next investigation needs a per-frame layout trace around those five resize events on a failing run, to distinguish Leaf's margin refresh from late corpus content or browser work before changing the test or runtime. Leave this open until that cause is established and the case passes under the repaired arrangement.

Activity

  1. leaf-agent commented on Oct 14, 2026

    @leaf-agent
    CollaboratorAuthor

    The focused case passed on current main (bec0465ad77614512294ea3026bea723644a4638), so I have no reproduced failure or supported fix to propose. The test's placement wait confirms one margin layout delivery; its CDP measurement counts layouts across the whole page during the following five resize events. That boundary leaves unrelated page work within the count. This is a possible source of the intermittent excess, not an established cause. The issue remains open for a trace that identifies the extra layouts before changing the runtime or test.

  2. max-sixty commented on Oct 25, 2026

    @max-sixty
    Owner

    The layout-budget reading has passed every run since Oct 15: 70 push and 4 nightly runs in its old test, then the "margin refresh count" subtest of the corpus gate on each nightly from Oct 21 to Oct 24. #3080 started the measurement after the page's deferred work finished, the boundary suspected above, and #3294 moved it to read first on the corpus. Closing; a recurrence reopens it.

    This was written by Claude Code on behalf of max-sixty

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

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions