Skip to content

feat(tui,remote): every overlay owns its clicks; download tier observed across processes - #1365

Merged
huichen merged 5 commits into
mainfrom
pr/huichen
Oct 26, 2026
Merged

huichen merged 5 commits into
mainfrom
pr/huichen

Conversation

@huichen

@huichen huichen commented Oct 26, 2026 •

Copy link
Copy Markdown
Collaborator

Frozen snapshot of \dev-huichen\ at \41195c53\ (merged with current \origin/main). Carries what the integration branch has beyond \main:

  • overlay hit-testing (\dd9e0ee8): every workbench overlay now owns its clicks. Adds two acceptance drivers —
    \ ui/examples/workbench_interaction.rs\ (sends real key/pointer events to every page and asserts each registered region is in-frame, topmost-hit-testable, and actually returns an action or changes state; non-zero exit otherwise) and \ ui/examples/workbench_semantics.rs. Layout/mod/screen changes so overlays claim input instead of letting it fall through.
  • download tier across processes (\28de675e): a desktop download is observed end-to-end across two real processes, not a single-process simulation.
  • acceptance record (\4c5ad62b): the record states its own gate result.

Merged per \AGENTS.md\ (integration branch → frozen PR branch → squash). CI decides.

huichen and others added 3 commits October 26, 2026 12:03
The split shipped with one gap: it had been exercised inside one process
only. A 12.5 MB installer "saved by the desktop" had never actually crossed
a socket, and the architecture page said so.

This adds a real-network run in the shape of `remote/real_network`: the
production host bridge in one child process, the desktop's own
`download_for_desktop` and `write_to_path` in another, a real nats-server
between them, and source files created for the run. Measured (release): the
12.5 MiB installer saves with a matching shasum in 94 ms, a 64 MiB file in
437 ms, 600 MiB and 512 MiB + 1 byte are refused with the desktop's own
sentence, the phone's mode and type rule still refuse their cases word for
word, and a host built from `b594ac2bc` answers `Unsupported download
variant.` and is asked again for `original`, which completes.

One documentation sentence was wrong and is corrected: the host's staging
copy is released when the download completes (the client cancels), so the
30-minute TTL is the failure path, not the normal one. The preview control
still answers the same installer with the phone's 10 MB sentence by design;
that is recorded as an open item rather than changed here.
The record pointed at the merge report for its `make check-docs` result
instead of printing it, and undercounted the downloads it drained the host
staging directory with. Both now say what was measured.
Driving all 28 pages with real key and pointer events (`workbench_interaction`)
found four holes that no static frame could show:

* an overlay registered nothing of its own, so a click on its padding reached
  the control painted beneath it and was then dropped - and a click on the page
  around the box only closed it where no region happened to exist;
* the command palette drew its entries without registering them, so `ctrl+p`
  was usable only from the keyboard;
* a queued prompt under its overlay answered nothing, because the page's click
  handler is not reached while a card is up;
* the workflow boxes computed hit regions for a centred box while painting it
  at column 0 - right at 120 columns, a whole margin out at 160, where clicking
  a file name closed the diff instead of opening the file;
* an approval button the box had to clip still answered, at 12 columns, from
  outside the frame.

The hit map now exposes a mark, so a pointer inside an overlay resolves against
the overlay alone; every box claims its own surface; the palette and queue
register their rows; the boxes are indented to where their regions are; and a
clipped button leaves no target.

Both new examples are gates: `workbench_interaction` walks every page at any
size, and `workbench_semantics` checks that the row under the pointer is the
row that answers (scroll, filter, resize, tab focus, wheel, escape).
@huichen
huichen enabled auto-merge (squash) October 26, 2026 04:15
@huichen huichen changed the title test(remote): observe a desktop download across two real processes feat(tui,remote): every overlay owns its clicks; download tier observed across processes Oct 26, 2026
@huichen
huichen merged commit e52667a into main Oct 26, 2026
21 checks passed
@huichen
huichen deleted the pr/huichen branch October 26, 2026 04:48
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant