Repository navigation
Name every window once, beside tab, and read its pointer from it - #5268
Merged
Merged
Conversation
eval's presets, page_defects.yaml's widths and pins' VIEWPORTS were three tables of named windows, and two readers decided a window's pointer by its name being "phone". WINDOWS in leaf_dev/browser.py names each window with its size, touch and description; eval, the page-defect judge, pins and tab_options' --viewport read it. Every window keeps its size and pointer; the page-defect judge's windows take the shared names and descriptions.
leaf-agent
previously approved these changes
Nov 4, 2026
…y what --touch overrides The defect schema still listed wide, so the judge saw a window named large but had to label a defect there wide. The schema now reads the widths list through a YAML anchor. --touch's help said a page was otherwise off, which a state's own pointer contradicts.
leaf-agent
approved these changes
Nov 4, 2026
max-sixty
added a commit
that referenced
this pull request
Nov 4, 2026
) #5268 named every window once in `WINDOWS`, but `tab()` still took a size and a touch flag, so each caller split a `Window` back into its parts, and `State` and `tab_options` carried the same pair. Now a window is one value: `tab(browser, window, scheme)` takes a `Window`, a state names its own `window`, and `--viewport` gives one. The default 1440×900 window is the named entry `macbook` ("a 1440px by 900px MacBook content viewport"). `desktop` stays eval's 1280×800, and `laptop` would clash with `middle` ("a 900px by 700px laptop window") and with the render gate, which calls its 1280×720 window "the fixed laptop window". `tab`, and stills and probe for a state that names no window, open `macbook` unless told another; `leaf-dev journey` and `bench-latency` read its size. The unnamed `DESKTOP` and `PHONE` constants are gone. Since `eval --viewport` offers every named window, `eval --viewport macbook` now works too. `chosen_window`, beside `tab_options`, replaces the option wrapper and `State.window()`: `--viewport` replaces a state's window, and `--touch` or `--no-touch` sets the pointer of whichever window the tab opens in. One behavior changed: a size `--viewport` spells, such as `600x900`, now has a mouse even over a state that names a finger, as a named `--viewport` window already overrode a state's pointer. Pass `--touch` for a finger at that size. The eval's scripted comment and the user agent's decision keep the first selected window's size under a mouse (`Run.journey_window`), as before. The scripted comment selects with mouse events, and a coarse pointer changes how the composer keeps a selection. ## Checks - Every state keeps its size and pointer: all 249 states compared with main's `STATES`, and the named windows' sizes, pointers and descriptions are unchanged. - Stills of `failed-widget` (its own 1600×900), `margin-gallery` (phone, finger), `breakout-captions-scrolled` (phone size, mouse) and `plan-panel`, by default, at `--viewport phone` and at `--viewport 600x900 --touch`: all 16 `base.png`/`head.png` captures are pixel-identical to main's tooling. - `leaf-dev probe` reports `[390, 844, coarse]` for `--state margin-gallery`, `[390, 844, fine]` for `--viewport phone --no-touch`, and `[1440, 900, fine]` by default. - `dev/tests/model/test_stills.py` covers each way a run chooses a window, and the eval tests near the changed code pass. > _This was written by Claude Code on behalf of max-sixty_
max-sixty
added a commit
that referenced
this pull request
Nov 5, 2026
A re-measurement on 2026-11-05 found 0 of 10 dashboard/write-up authors on main cramping a dashboard into a workspace, and none with the older guidance under today's runtime, so the note no longer calls it the likeliest next target. It also says --viewport desktop opens 1280x800 since #5268.
max-sixty
added a commit
that referenced
this pull request
Nov 8, 2026
…losed issues' citations at their work (#5714) Two changes from the issue triage. The maintainer chose on 8 Nov to land them. ## A page's trace keeps no password (#4079) A page's local trace records every typed value, key, paste and selection for debugging. The maintainer chose on 2026-11-04 to keep that raw capture. The alternatives were recording only the structural fields leaf.page's Worker keeps, or recording nothing unless the user turns it on. So the `TODO(privacy)` note in `interaction_log.py` becomes a record of that choice. A password field is the one thing left out. The trace still shows that the user typed there, and drops the key, code, data, clipboard, value and selection of each event on it. A field the trace has seen as a password field stays one, so switching it to a text field to show the password no longer records what was typed. An independent review had found that leak in Chromium, Firefox and WebKit. A field inside a closed shadow root is seen only as its host, which capture at the document can't change, and `interaction-log.js` says so. `test_browser_trace_leaves_out_a_password_fields_characters` types into a password field, toggles it to text, types again and selects the text. It checks that the trace records the typing and selecting, and none of the characters. ## What cited the closed issues The triage closed #4036, #4017, #4781, #4009, #4048 and #4098, so text that pointed at them now says where their work went: - The tab test's comment gives the reason a revision above the reader moves it (a page read from its top keeps its top, `reading-place.js`) rather than #4036. - `notes/browser-support.md` moves the Firefox rule rewrite to #5194, with #4781's other follow-ups. - `notes/agent-usability-evals.md` says #4017's brief gave way to `TODO.md`'s first challenge. It also says #4098's workspace failure no longer reproduces: 0 of 10 dashboard and write-up authors on main cramped one into a workspace (2026-11-05). And `--viewport desktop` opens 1280×800 since #5268. - `notes/threads.md` drops its "Current status" plan, which went with #4009. - `leaf-dev journey`'s sample store no longer calls itself a stopgap until #4048: CI's samples stay in `publish-site`'s run logs. Nothing changes outside the trace's handling of password fields. Closes #4079 > _This was written by Claude Code on behalf of max-sixty_
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.
eval's presets,page_defects.yaml's widths andpins.py'sVIEWPORTSwere three tables of named windows, andarrangement_eval.pyandpane_readings.pydecided a window's pointer by testingname == "phone".WINDOWSindev/leaf_dev/browser.py, besidetab, now names every window once, each with its size, whether a finger drives it, and its description.eval --viewport, the page-defect judge andpinsread it by name, and every capture, reading and judge instruction takes a window's pointer from itstouchflag.--viewportinstillsandprobe(tab_options) also takes a window's name, which brings its pointer, so--viewport phonereplaces--viewport 390x844 --touch;--touchand--no-touchstill override it.Every window keeps its size and pointer:
evalgenerates the same Promptfoo configuration as main, byte for byte, for the whole catalogue (268 tests under both harnesses and all four conditions) at each of 12 selections of windows, from the default alone to all four presets together. What reaches the author and the judges at run time is the same too: the window preference, the report's listing, each comparison's saved widths, and the judge's "Use --mobile for phone".pinsreads its 26 cases at desktop (1280×800) and phone (390×844, touch), and its report names the same windows.Behavior changes:
largerather thanwide, and it reads "a large 1600px by 1000px desktop content viewport" rather than "a fullscreen desktop window". The phone reads "a 390px by 844px phone window" rather than "a phone held upright, with touch"; the judge's instructions still say "Use --mobile for phone". The 900×700 window reads "a 900px by 700px laptop window beside other work". The judge labels each defect with these names, which its output schema now takes from the same list. Its grades weren't rerun, so this change doesn't show they are unchanged. One description per window can't keep both this judge's words and the eval author's, and the author's request is the one only fresh authoring runs could re-measure.eval --viewportalso offersmiddle(900×700), the page-defect judge's window, whose description now gives its size as the others do, for an author's request.thread_snapshots.Casestill declares its own windows, since a change to thread snapshots is still under discussion.