Skip to content

Closing a panel thread briefly toggles its quick control visibility #4745

Description

@leaf-agent

Closing an empty panel thread with Escape makes .lf-fp-quick's hidden attribute change and return to its starting value in the same script. The browser write watch reports unchanged write: hidden on div.lf-fp-quick.

Reproduced on main 7e4132fbf7ef254398b25a21dc8debd1cf46fd87 while repairing #4674. In test_a_thread_about_an_ask_stands_at_the_ask_from_the_panel, first update the stale opening expectation to require PANEL_REPLY focus, then press Escape to focus the thread view before its existing digit-2 assertion. Keep the existing Escape immediately after the #store-cookie assertion. Run uv run pytest tests/browser/projection/test_current_location.py::test_a_thread_about_an_ask_stands_at_the_ask_from_the_panel -q -n0: its behavioral assertions pass, but teardown reports the unchanged write.

The write watch's own lfWrites ledger locates both hidden mutations at that second Escape, which closes the view; opening the next thread directly through Threads avoids the finding. This is distinct from #4674's obsolete expectation that opening a resolved thread focuses its view. Trace the close transition and its focus-driven panel repaint, and eliminate the intermediate write in its owning renderer rather than suppressing the watch.

Activity

  1. leaf-agent commented on Oct 30, 2026

    @leaf-agent
    CollaboratorAuthor

    Push run 41014020492 records the same unchanged write: hidden on div.lf-fp-quick diagnostic in eleven cases: walked-thread key scopes, obligation-walk chrome measurement, keyboard panel-thread projection, seven floating-panel lifecycle/menu/comment variants, and the page variant of opening a plain agent question. These broaden the affected callers beyond the local reproduction in this issue; the current diagnostic names the same attribute and element, without establishing that every caller takes the same close path.

  2. leaf-agent commented on Oct 30, 2026

    @leaf-agent
    CollaboratorAuthor

    #4760 fixes the close transition: it now clears the panel's writing state before rendering, preventing the quick control from hiding and reappearing when focus subsequently leaves. The same mechanism affected closing Threads after leaving its comment field.

    The restored Escape-close regression fails with the reported warning before the fix and passes afterward. Seven focused browser checks, all 712 runtime tests, and the browser type/build check pass locally. The push is recorded for landing; the queued review and CI retain the remaining verification, with no CI wait in this triage run (await_ci: false).

  3. leaf-agent commented on Nov 2, 2026

    @leaf-agent
    CollaboratorAuthor

    Reopened from push run 41395985405, after #4760 landed. The write watch again reports unchanged write: hidden on div.lf-fp-quick, this time in test_c_comments_and_g_t_navigates_to_threads, test_the_panels_own_c_answers_a_page_whose_log_has_not_arrived, and test_z_names_what_it_takes_and_how_long_ago_in_a_fresh_tab. This repeats the element/attribute diagnostic but does not prove that every case takes the repaired Escape-close path. The reopened triage worker owns current-main reproduction and tracing the writer before choosing a repair.

  4. leaf-agent commented on Nov 4, 2026

    @leaf-agent
    CollaboratorAuthor

    Current main (dc27bd09e) still reproduces all three reported cases. They come from two separate double paints, neither of them the Escape-close path #4760 repaired.

    • Opening the page comment from an open view (test_c_comments_and_g_t_navigates_to_threads, test_the_panels_own_c_answers_a_page_whose_log_has_not_arrived). writeOnPage clears the view and paints with writing false, which shows the quick control. The same paint then focuses the field, and that focus hides the control again. fix: start the panel's writing posture in the paint that puts the caret in the page comment #5335 starts the writing posture in the paint that lands the caret. Both tests fail before that change and pass after it. Its review and CI are queued, and it lands through the usual bot path once they pass.
    • A menu row whose command opens a view (test_z_names_what_it_takes_and_how_long_ago_in_a_fresh_tab). Pressing Undo in the menu goes through putAwayThen, so close() paints the empty row (control shown) before the undo command shows the resolved thread in a panel view (control hidden), all in the click's task. fix: start the panel's writing posture in the paint that puts the caret in the page comment #5335 doesn't change this. The repair has to make the menu's put-away and the command's view draw as one transition, which changes the focus-then-paint order that putAwayThen's header relies on. It stays open here.
  5. added
    tend-ci-cause
    on Nov 5, 2026
  6. leaf-agent commented on Nov 11, 2026

    @leaf-agent
    CollaboratorAuthor

    test_z_names_what_it_takes_and_how_long_ago_in_a_fresh_tab still fails at teardown with unchanged write: hidden on div.lf-fp-quick, on both Linux and macOS. That is in scheduled run 42802603869 at e6756ad43. The menu-row path the last comment traced (putAwayThen painting the empty row before the undo command's view) is still the open part here.

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

    tend-ci-cause

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions