ac4af582301a4e8a29245dbba767eba31334ddf9
3
Commits
| Author | SHA1 | Message | Date | |
|---|---|---|---|---|
|
|
ce8b67de37 |
gui tests: a page's first load gets a minute, not a click's 5s (#4470)
claude-switch-only set page.setDefaultTimeout(5000) and then called page.goto with no timeout of its own, so Playwright held the first load of app.js, i18n.js and the plugins to the 5s bar meant for clicks. On a busy box (a whole-suite run at load 130-160) that load took longer and goto timed out. The same pattern is in 988 GUI test files (1174 pages): every one of them now also sets setDefaultNavigationTimeout(60000) on the same page, right after its default, so goto, reload and waitForURL wait on the load itself with room, while clicks and waits keep their short bar. group-from-model-add's own 20s navigation bar is raised to the same minute. claude-switch-only also gives its first provider row (drawn from the page's first reads) a minute before clicking it. nav-timeout.test.cjs (no browser) reads every GUI test file and names each page given a default under a minute without a navigation timeout of at least a minute, so a new file can't bring the pattern back. What was run (WSL magpie-desktop, Playwright 1.62.0, load 70-260 from other sessions): - node --check on every file in internal/gui/tests: all parse. - nav-timeout.test.cjs against origin/main's test files: red (names the 1174 pages); against this tree: its only reds were my own probe copies of the old files, since removed. - By hand: claude-switch-only with app.js served 7s late (a busy box's first load), --test-name-pattern "1100 en": origin/main's file 4 of 4 red with "page.goto: Timeout 5000ms exceeded"; this file 4 of 4 green. - claude-switch-only.test.cjs, both engines, en/zh/ja/de, 1100 and 420: 32 of 32. group-from-model-add, usage-access-key-card and i18n-keys: green. agent-plugin-agents: Chromium green; WebKit's de 420 subtest red on a 5s waitForFunction at line 115 (a wait after load, not the navigation), at load ~230. Not tried: the whole GUI suite (about 1000 files; the change is one mechanical line per page), Windows or mote (mote's browsers, #4125). |
||
|
|
f1e4516da2 |
gui: Codex's and Claude Code's own settings are in the agent's row on the Agents page, not in Settings
The owner, 10-20: Settings › General held Codex subagents, Long
conversations, Codex background compaction, thread titles, thread
descriptions, composer predictions, the auto-review model and the
memories model, apart from the agents they set; "很割裂、很分散,不直观".
They now sit with their agent (AGENT_PREFS): in its opened row on the
Agents page (a Settings list in connectPanel), in a sheet from the
tray panel's row ("Settings" line, openAgentPrefs) and from the agent's
menu ("{agent} settings"). Each row is the one element moved between
those places, so its handlers and state go with it. Settings' search
still finds them, with a row that opens the agent's sheet
(#agentPrefLinks). A gateway has no Agents page and none of them.
Strings for zh, zh-TW, ja and de; docs (reference, agent-wiring,
gui-shell) point at the new place. app.js 1,277,298 bytes and the core
scripts 1,469,058, so both budgets rise.
Run on 6416d639c (the dialog morph, on origin/main
|
||
|
|
700315dff5 |
gui: a click made while the page is drawn again is kept: a Settings option pressed through a redraw is still picked, and a menu still loading opens at the redrawn button (#1211)
* gui: a Settings option pressed while the page is drawn again is still picked when let go on it Every save's answer runs renderSettings(), which replaces each option control. A second option pressed while the first one's save came back was let go on a new button: down and up were on two nodes, the browser sent the click to neither, and nothing was saved. Two quick clicks lost the second one silently. A capture-phase pointerdown/pointerup pair now clicks the new button when the pressed one was taken out of the page and the pointer is let go on the same option of the same control. The same control means the same place under the nearest element with an id, among as many controls of its kind, in rows alike by their data-*; a list drawn again with a row gone, come in or moved above the pressed one is another control, and nothing is picked. Let go anywhere else (dragged off to another option, or to another control) picks nothing, as for any button. A click the browser sends after all is not doubled. A tap is left to the browser, which clicks what is under the finger as it lifts. It covers every segs() control, so every option on Settings. segs-press-redraw.test.cjs, Chromium and WebKit, en/zh/ja/de, 900 and 440px (42 tests): the probe (press Lightweight → On, renderSettings(), let go) posts once; drag-offs post nothing; a plain click posts once; every option control on every Settings tab (49 in English) pressed through a redraw clicks its new self once; a Chromium tap through a redraw posts once; a list drawn again with its rows changed picks nothing. Without the fix the probe and the sweep get no click at all in both engines; without the touch skip a tap posts twice; matching by place alone picks the row below. * gui: a menu still loading when its button is drawn again opens at the redrawn button openAgentModels kept the clicked button across its fetch and gave up when a redraw had taken it off the page, so a click on Pick, Claude Desktop's model menu or the models line was silently dropped whenever Agents was drawn again while the list loaded: a periodic refresh, or the /api/state re-read that closing a changed list queues (agent-models.test.cjs's Escape-then-Pick was racing it). The loading record now holds the button, the builders hold it to the button they draw (holdAgentModels, beside the existing re-anchor of an open list), and the list opens at the current one. A click on the redrawn button while it loads takes the click back, as one on the first did. The same await-then-open gap was in the two other menus that wait on a fetch before opening: - a gateway key's models badge dropped the click when the keys were drawn again during GET /api/caller-keys/models; - the menu bar's allowances pill, opened while the allowances loaded and Settings was drawn again (another setting saved), came up in the window's corner at the dead pill and saved the other setting back as it was. Both now open from the button drawn last, with what that drawing keeps. Reproduced on the unfixed code with the new tests, which delay the fetch and redraw during it: agent-models-redraw, gateway-key-models-redraw and tray-usage-redraw, in Chromium and WebKit at a wide and a 560px width. They pass after the fix, as do the agent-models, gateway-key and tray-usages tests. Full GUI suite in both engines: 3503 of 3518 pass; the 15 failures are in 8 files outside these paths (account-mask, panel-arrange, session-identity fail on upstream/main too; profile-confirm is flaky there too; azure-endpoint, lightweight, purpose-filter and routing-time failed only under the full run's load and pass alone on both). |