Skip to content

ci-fix: ci failing — six unowned tests from the panel becoming a modal dialog #139

Closed

Description

@leaf-agent

Failure

ci run 33328423276 on 635a92c — 34 failed, 1493 passed in the nightly suite. ci has been red on every run on main since ac5ba54, and re-running that run's 34 node ids on today's tip 0d7e0d0 still gives 29.

Diagnosis

Six of them have no owner, and this issue is for the decision behind them rather than for another attempt at a fix.

Applying every open bot PR to 0d7e0d0 at once — #121, #136, #137 and #138 all apply clean; #132 does not — takes the 34 to 10 red. Four of those ten belong to PRs already on the board: test_example_renders[corpus], test_the_arrows_say_which_way_the_section_under_the_reader_goes and test_a_widget_that_renames_its_role_keeps_the_press_offer_gave_it on #132, and the catalog digest on #134 / #133. The remaining six all come from .lf-panel being a <dialog> since 335bf9a, in two mechanisms.

A covering panel is modal, so the page behind it is inert — five tests. syncPanelLayer calls showModal() when panelCovers(), and the four click/tap ones fail with <dialog open id="lf-threads" class="lf-ui lf-panel open"> intercepts pointer events while the fifth presses s and gets no hints because the document cannot hear the key.

test fails on
test_render_controls.py::test_coarse_pointer_chrome_gives_its_compact_controls_humane_aims Locator.tap timeout
test_render_controls.py::test_coarse_pointer_resize_reach_stays_reachable_without_trapping_scroll wait_for_function timeout on .lf-threads scrollTop
test_render_controls.py::test_workspaces_replace_each_other_instead_of_stacking[500] Locator.click timeout
test_render_controls.py::test_the_responsive_action_shelf_keeps_primary_actions_in_reach Locator.click timeout
test_render_semantic_selection.py::test_selection_hints_do_not_name_page_content_behind_a_covering_panel .lf-target-hint expected not to have count 0

#138's "What this does not fix" names four of these five. The fifth, test_the_responsive_action_shelf_keeps_primary_actions_in_reach, is named on no PR or issue: it reads as a scrollWidth/clientWidth failure until #121 is applied, and only then shows the same intercepts pointer events shape as the rest of the group.

Opening the panel moves focus into it — one test. test_esc_hands_the_page_back_after_it_has_closed_the_last_panel is listed on #138 as #137's, but #137 does not touch it and its failure is not about Escape. It fails at expect(toggle).to_be_focused() on the line straight after toggle.click(), before any Escape is pressed: the dialog focusing steps run on show() as well as showModal(), so the press that opens the panel loses the button that opened it. The test's own comment asks for the opposite — "opened with the pointer, the button holds focus and the browser withholds the ring".

Probes, on the suite's pinned Chromium 151.0.7922.34
// both spellings take focus off the invoker
t.focus(); d.show();       // document.activeElement -> the dialog's first button
t.focus(); d.showModal();  // document.activeElement -> the dialog's first button

The same page, launched the way render_harness.py launches it.

How the ten were measured

uv run pytest --run-nightly -q in the tend sandbox against the seeded headless shell, -n2 for the set and -n0 for each detail.

  1. The 34 node ids from run 33328423276, on 0d7e0d0: 29 red.
  2. git apply of Keep the root's bar standing rather than reserving a gutter it never draws in #121, Narrow the sidebar page to the width its measured rail asks for #136, Give the versions menu back its way in, its way out, and the reader's place #137, Fix margin rail, float placement, thread marks, and preview tab order after the chrome change #138 together on 0d7e0d0 (each applies clean; Read the settled ask's disclosure keys from DISCLOSE, and repaint every disclosure row's shortcuts #132's does not): 10 red.
  3. Fix margin rail, float placement, thread marks, and preview tab order after the chrome change #138's branch head 741fe2a is already based on 0d7e0d0, so this is its own tree plus the other three, not a speculative rebase. The six were re-run on 741fe2a + Keep the root's bar standing rather than reserving a gutter it never draws in #121 alone and fail identically, so none of them is an artefact of stacking the four.
  4. Bisect for the group: every one of the six passes at 01ec4f4, 335bf9a's parent — the two that need Keep the root's bar standing rather than reserving a gutter it never draws in #121's overflow-y: scroll to pass there were given it — and every one fails at 335bf9a with that same CSS change applied. So the panel-as-dialog cause is separable from the scrollbar-gutter one on both sides.

Not re-measured here: the two tests 0d7e0d0 brought red on main, test_the_shipped_long_thread_opens_beside_its_source_in_the_right_margin and test_the_full_thread_posture_follows_the_page_container_and_left_claims. They are outside run 33328423276's set and #138 already records them.

Why no fix was produced

Whether a covering panel should take the page out of reach entirely, or cover it and leave it working, is the product call #138 declined, and declining it a second time on the same grounds is the honest answer rather than a gap: the five tests state the old contract, showModal() states the new one, and picking between them decides what a reader can do behind an open panel on a phone. Nothing in the repository says which 335bf9a intended.

The focus one is smaller but not separable in practice. Restoring focus to the toggle after show() would turn that test, but focus on the panel press is the same surface #137 is currently rewriting for the versions menu, and the Escape ladder in leaf.js already states a deliberate opposite intent for the close, citing setPanel for why ("it lands them on the control that closes it"). It belongs in that PR rather than a seventh open branch — flagged here because #138's attribution sends whoever picks it up to a PR that does not contain it.

Activity

  1. leaf-agent commented on Aug 30, 2026

    @leaf-agent
    CollaboratorAuthor

    #144 answers the product call in the direction the repository already states, and takes five of the six.

    The decision this issue held open — whether a covering panel should take the page out of reach — is not silent in the tree. Five tests state the old contract and 335bf9a updated none of them; test_selection_hints_do_not_name_page_content_behind_a_covering_panel is the one that says outright what "covering" means here ("A fixed panel covers rather than clips the page"), and it was not among the files that commit touched. skills/leaf/CLAUDE.md states the same reading from the other side, about a different surface: presentPage demotes authored showModal() calls to non-modal dialogs precisely so a modal's top-layer inertness cannot disable the recovery chrome. And the two things modality was carrying for the panel are already owned elsewhere — the covering sheet's root scroll lock by the stylesheet, Escape by the ladder, which hands the platform only the layers the platform really owns.

    So #144 shows the panel at either posture and gives the invoker its focus back. It deletes panelModal, ignoreNextClose, the close-and-reopen across the breakpoint, the two re-syncs that existed only to switch modality, and the close listener only a native modal dismissal could reach. The visible half is the scrim: measured on the same fixture, every pixel outside the panel goes from (222,221,219) to (250,249,246) — including the banner, which was being drawn as unavailable while it was.

    The sixth, test_coarse_pointer_resize_reach_stays_reachable_without_trapping_scroll, needs #121 as well and is still red with both, on a failure that is #121's own and reachable without #144: it is green on main and on #144 alone, red on main + #121. Details are in #144's last <details> block, and worth reading before #121 lands.

    One overlap to resolve: #141 opened while this was being measured and fixes the focus test alone, by extending syncPanelLayer's restore while keeping showModal(). #144 supersedes it — once the panel is never modal, the same restore falls out of a smaller function — so only one of the two should land.

  2. added a commit that references this issue on Aug 30, 2026
    8afe5f0
  3. leaf-agent commented on Aug 30, 2026

    @leaf-agent
    CollaboratorAuthor

    Re-measured on today's tip. The ci run this session was dispatched for — 33331209744 on 0d7e0d0, the first full run on main for that commit — had 32 red, this issue's 34 less six and plus four. Since then #121, #136, #138, #141 and #142 have merged. Running those same 32 node ids on 996ae23, twice: 13 red in both passes, three red in one of the two, 16 green in both — and nothing red is unowned.

    The two this issue left as "not re-measured" — the test_render_margin.py pair 0d7e0d0 brought — are green on main now, and they were #121's rather than the margin code's. Measured before it merged, its chrome-style.js hunks alone took that file from 2 failed / 20 passed to 22 passed; the note on #121 has the mechanism.

    So the six this issue holds are still six, minus whatever #144 takes. test_esc_hands_the_page_back_after_it_has_closed_the_last_panel is the one that has moved: #141 fixed the focus half it was failing on, and it now passes alone and failed one of two loaded passes on a later assertion (expected to be visible) — a different question from the one this issue records for it.

    The rows, and who has each

    Red in both passes:

    test owner
    test_render_anchors.py::test_the_menu_a_first_version_opens_is_a_menu_it_can_close #137
    test_render_anchors.py::test_the_versions_menu_suspends_the_pages_own_keys #137
    test_render_anchors.py::test_the_version_menu_is_worked_by_pointer_and_key #137
    test_render_anchors.py::test_a_row_the_platform_activates_names_both_of_its_keys #137
    test_render_controls.py::test_coarse_pointer_chrome_gives_its_compact_controls_humane_aims this issue / #144
    test_render_controls.py::test_coarse_pointer_resize_reach_stays_reachable_without_trapping_scroll this issue / #144
    test_render_controls.py::test_the_responsive_action_shelf_keeps_primary_actions_in_reach this issue / #144
    test_render_controls.py::test_workspaces_replace_each_other_instead_of_stacking[500] this issue / #144
    test_render_semantic_selection.py::test_selection_hints_do_not_name_page_content_behind_a_covering_panel this issue / #144
    test_render_gate.py::test_example_renders[corpus] #143
    test_render_navigation.py::test_the_arrows_say_which_way_the_section_under_the_reader_goes #132 / #140
    test_render_navigation.py::test_a_widget_that_renames_its_role_keeps_the_press_offer_gave_it #132 / #140
    test_site.py::test_the_public_catalog_is_a_visual_index_of_full_page_routes #133 / #134

    Red in one pass of two, green at -n0:

    test note
    test_render_controls.py::test_esc_hands_the_page_back_after_it_has_closed_the_last_panel this issue, on the moved failure above
    test_render_pages.py::test_a_left_sidebar_uses_the_margin_until_the_page_needs_it_back assert 1258 <= (1234 + 1), a different assertion from the one #136 fixed
    test_render_gate.py::test_a_reader_arrives_at_what_they_left_rather_than_watching_it_arrive no branch behind it; #121 measured it at the same rate with and without its changes

    The last row is the only one nothing owns. #121 recorded it naming the thread panel open and the leaves tray standing; this run named the tray panel at the width the reader drew it to. Three arrangements, one shape.

    How that was taken

    In the tend sandbox against the seeded headless shell, on a 4-CPU runner. The 32 node ids came from run 33331209744's own summary with @site group suffixes stripped, run whole with --run-nightly -n2 twice at 996ae23, and each one-pass-only row re-run at -n0.

    That selection is fifteen-odd browser tests on two workers with none of the suite's cheap tests between them, so it is denser than CI's whole-suite -n2 and reads the load class harder than CI does. Nothing in the second table is claimed as a regression.

    The margin measurement was taken before #121 merged, on 1ca4f40 with git apply of #121's chrome-style.js diff and nothing else: main 2 failed / 20 passed, plus that patch 22 passed. On main the @container lf-shell (min-width: 1208px) posture flipped at a 1223px window rather than at 1208 — lf-shell is body, whose box was the window less the 15px gutter — and with the patch it flipped at exactly 1208, which is what the two new tests assert against.

  4. added a commit that references this issue on Aug 30, 2026
    2b462cc
  5. leaf-agent commented on Aug 30, 2026

    @leaf-agent
    CollaboratorAuthor

    One correction to the row table above, and it is the only thing #144 leaves behind.

    test_coarse_pointer_resize_reach_stays_reachable_without_trapping_scroll is listed as #144's, and #144 does clear the modal failure it was dying on — but it is still red after that, on an earlier assertion that #121 brought and #144 does not touch. Walking it forward, each row a local -n0 run:

    tree first failure
    main at 1ca4f40 (pre-#121) line 1017, .lf-decisions click — <dialog … class="lf-ui lf-panel open"> intercepts pointer events
    1ca4f40 + #144 line 1077, assert edge["left"] >= -0.1 → -12
    1ca4f40 + #121 line 1006, wait_for_function on .lf-threads scrollTop after a touch swipe
    main at 0b7f148 (post-#121) line 1006, same
    0b7f148 + #144 line 1006, same

    Line 1006 is green on 1ca4f40 and on 1ca4f40 + #144, and red the moment #121's hunks are present with or without #144. It was masked while the modal failure at 1017 was in front of it, so it reads as "still #144's" and is not: a touch swipe beside the covering panel's grip stopped scrolling the thread list when the root stopped reserving its gutter. It is live on main now and needs its own fix.

    The other five are green on #144, and #144 is rebased onto merged #141 — its restore arm is replaced rather than competed with, so the esc test stays green there too. My earlier comment called #144 a supersession of #141; #141 landed first, and #144 now builds on it.

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