Skip to content

feat(tui): accessibility reader, alert policies and partial-reply fixes - #1360

Merged
huichen merged 7 commits into
mainfrom
dev-huichen
Oct 26, 2026
Merged

huichen merged 7 commits into
mainfrom
dev-huichen

Conversation

@huichen

@huichen huichen commented Oct 26, 2026 •

Copy link
Copy Markdown
Collaborator

This PR carries the remaining TUI work that landed on dev-huichen but never reached main: a native linear reading mode with accessibility preferences and notification alert policies, plus overlay fixes that no longer drop a reply still being written, and the weak-network measurement of the remote download control plane.

Commits

  • feat(tui): add native linear reading and alert policies
  • fix(tui): complete accessible linear reader and notification policy
  • fix(tui): preserve linear output across overlays
  • fix(tui): preserve partial replies across overlays
  • test(remote): measure the weak-network cost of the download control plane

Two merge commits on the branch (feat/tui-final-review, twice) only bring the four TUI commits above; they add no content of their own.

Verification

Local, on the branch tip with the pinned toolchain (rustc/clippy 1.97.0):

  • cargo fmt --all -- --check — clean
  • cargo clippy -p future-tui -p future-remote-interop --all-targets -- -D warnings — clean
  • cargo test -p future-tui --lib — 1219 passed, 0 failed
  • make check-docs — 339 docs OK (placement, bilingual pairing, links, script paths, fences), provider matrix 13 rows

CI on the merged head (0483ad1a): all required contexts pass — Detect affected projects, Rust check / Rust Linux / Rust macOS / Rust Windows test (tui-cli), CI result; the TypeScript, Android and iOS contexts are path-filtered to skipping.

Notes

  • No migrations, no default-value changes: the new preferences start from their defaults and the existing settings file is untouched.
  • tests/remote-interop/tests/weak_network.rs is feature-gated behind network-tests and needs a local nats-server, so CI only compiles it.

huichen and others added 7 commits October 26, 2026 08:43
…lane

The proposal to replace one pull per 512-KiB chunk with a four-chunk range
batch claims its value is in round trips, loss recovery and host scheduling,
none of which had been measured. This adds the fixture and the measurement.

`tests/support/weak_link.rs` proxies the client's leg to the broker with a
per-direction delay and a packet-loss model, and counts NATS frames exactly:
pulls by subject, acknowledgements by the reply subject of the pull they
answer. Delay is applied to bytes rather than reads, so an unlimited-bandwidth
link is what it models; a lost packet stalls the stream by one retransmission
instead of deleting bytes, because TCP redelivers and a byte-deleting proxy
would measure a protocol error. Loss decisions hash (seed, packet index), so the
same byte offsets are lost whichever way reads split.

`tests/weak_network.rs` measures 4 MiB and 10 MiB pages at 2/40/120/300 ms RTT
with 0 and 1% loss, and keeps one cheap correctness test outside `#[ignore]` so
a fixture that stopped delaying, counting or forwarding fails the default run.

Measured (release, macOS arm64, nats-server 2.15.0): the download spends
3.16 RTTs (4 MiB) and 6.60 RTTs (10 MiB), against a structural 3 and 6 — eight
pulls are two waves, not eight round trips, because four pull concurrently.
Loss costs about one recovery window per wave and never a retry. The report
projects a four-chunk batch at one and three round trips saved, with the
boundaries it ignores, in docs/testing/remote-weak-network-2026-10-26.md.
@huichen
huichen enabled auto-merge (squash) October 26, 2026 01:08
@huichen
huichen merged commit 89a1874 into main Oct 26, 2026
10 checks passed
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