- selectSession now samples _liveOutputGen before its fresh fetch, as the refresh and manual-pull paths do, so output that arrives during the download keeps the session marked for Reload history.
- Test: live output during the fresh fetch keeps the mark after a mux-full-history replay.
- _renderHistoryTruncationBanner sets aria-live to polite for the truncation notice and off for a reload-only bar, which re-renders on nearly every scroll-up in a busy tab; its button stays reachable with Tab.
- docs: comma in the Reload eligibility list, and the live-region rule in the invariants paragraph.
- _historyReloadActionEligible() and _maybeRefetchFullHistory stand aside while _terminalRefreshOwner holds the active session, so Reload, Load full history and the top-of-buffer pull no longer start a second capture whose download-time queue the refresh's own load would replace.
- _onSessionNeedsRefresh re-syncs the action when it takes the owner and again in its finally once it releases it.
- Tests: a refresh-in-flight visibility row, and a tap during a held refresh that fetches nothing and gets the action back afterwards.
- A content-anchored Load full history pull sets _historyReloadActionLoadingFor and clears it on settle, as Reload history does.
- The button renders from that loading state, so the re-render the in-flight pull triggers keeps it disabled on Loading….
- The top-anchor case keeps no loading state, so the bar still hides on a scroll back to live output.
- Content-anchored replay travel reveals the notice on an upward move that reaches row 0 and retires it on a downward move back at live output, as a live scroll does.
- _captureViewportAnchor returns only viewportY, rowsFromBottom and context; tests read anchor.context.
- _onSessionNeedsRefresh clears the Reload mark only after a completed mux replay.
- A later drop during an open load keeps the deferred recovery's higher attempt.
- Replay travel that reaches row 0 reveals the partial-history notice; at live output it retires it.
- The onScroll coalescing test drives the scheduler instead of evaluating a source line.
- _restoreViewportAnchor searches expected - 4000 + rows .. expected + rows
(same 4,001 candidates / 4,064 reads): filled rows only move the reader
up, so gaps up to 4000 - rows land exactly, also at the scrollback cap.
- _resetAllAppState and _cleanupPreviousSession clear
_pendingDroppedOutputRecovery next to the recovery timer, so a reconnect
load does not resume a stale recovery and run a second full capture.
- Tests: capped 2,500- and 3,900-row gaps; both real cleanup methods drop
the pending recovery. Docs: the window and the beyond-window fallback.
- The notice's Load full history button pulls with anchor 'content' when
Reload history is eligible (read at click time, since the bar only
re-renders on eligibility transitions) and keeps 'top' otherwise.
- Tests: the single load control asserts the content anchor; an
ineligible session keeps the top anchor.
- _onSessionNeedsRefresh adds the session to _historyReloadDismissed when
the full capture would shrink the buffer and it falls back to ?tail=,
past the ownership guard, so a no-history pane is not re-captured by
the next tap.
- Changeset: scope the note to agent sessions (seen with OMP).
- CLAUDE.md: one warning sentence on the Reload history rules.
- terminal-resilience test reads each whole method instead of a
4,000-character window.
- _onSessionNeedsRefresh samples the live-output generation before its
fetch and, after replaying a mux-full-history capture, clears
_liveOutputSinceFullPull and _historyReloadDismissed while it still owns
the active session and the generation is unchanged; the ?tail= fallback
never clears them.
- test/terminal-viewport-marker.test.ts: gated test driving the real
flushPendingWrites over @xterm/headless at a full scrollback; the reading
row holds with the marker and drifts without it.
- Docs: the anchor sentence matches minimumScore, and the refresh rule is
in the Repair while reading paragraph.
- A content-anchored reload answered by anything but mux-full-history (an
empty response, or the byte-history fallback for a blank or failed pane
capture) adds the session to _historyReloadDismissed until the next mux
replay; only a mux replay clears the mark, so each tap repeated a forced,
unbounded capture. An error envelope leaves it available.
- Only the request still current (active session and select generation)
may dismiss: a slow answer from before an A -> B -> A switch must not
retire the action a newer capture already cleared.
- _historyReloadActionEligible() also requires no terminal load state:
selectSession sets it before switching activeSessionId, so the sync
right after the switch no longer offers Reload for the loading tab.
- _clearTerminalLoadState() re-syncs the action, so a marked tab offers
Reload once its load ends.
- Changeset: note the reading-position fix for live flushes at the
scrollback cap.
- _historyReloadActionEligible() no longer reads _paneHistoryLines: it is
recorded at the last load, so a session first opened empty kept 0 after
the burst that opens the gap, and the action never appeared (found by the
live #814 recipe).
- A pane with no tmux history is still retired by the downgrade refusal,
which dismisses the action until the next mux-full-history replay.
- Reload history requires pane history and no buffer load in flight; a
downgrade-refused pull hides it until the next mux-full-history replay,
and a stale tap re-checks eligibility before fetching.
- x during Loading... hides the bar at once; the pull continues.
- The content anchor scores up to 64 visible rows, so repeated TUI borders
cannot outvote the row being read; ambiguous matches keep the viewport.
- Live flushes track the reading row with an xterm marker across
scrollback trimming at the cap.
- Docs: Settings-Reference row, Dashboard notice text, ~1 s capture cost,
byte-history replays rely on the top-of-buffer pull.
- Scrolling pulls tmux history only at the top of the buffer again (#205);
the automatic pull on any upward scroll is removed.
- Reload history lives in the existing #historyTruncationBar on desktop and
touch, shown for a marked non-shell session scrolled away from live output.
It never duplicates Load full history; one × dismisses what the bar carried.
- New per-device setting historyReloadAction (Terminal & Input > Scrolling &
rendering), default on, kept out of SettingsUpdateSchema.
- Eligibility sync is transition-only and onScroll is coalesced per frame.
- Remove the floating #historyReloadBtn and its z-index 20 layer.
- Deferred dropped-output recovery resumes at its saved attempt.
- zh-CN entries for the new strings; docs and changeset updated.
Review follow-up on #815, and the phone case from #814: the gap opens
below a reader who stays scrolled up while output arrives, and the
bottom-only trigger never fired there.
- Open the buffer load before the capture fetch so output arriving during
the download is queued and replayed, not wiped by the reset. Every
non-replay exit flushes the queue. A drop at the 128 KiB cap during an
open load is deferred and resumed when the load ends instead of
spending its retries against it.
- Clear the live-output mark only when the response is
source 'mux-full-history', on the scroll and tab-switch paths.
- Repair on any upward scroll in a marked non-shell session, not only
from the bottom. A content anchor (3-row signature, searched at most
2000 rows either side) keeps the row being read in place; no match
falls back to distance from the bottom.
- Tie replay travel to its session so a tab switch does not swallow
moves on the new tab.
- Reveal the partial-history notice when the initiating gesture
reached the top, even if the anchor moved the viewport off row 0.
- Touch-only Reload history button (#historyReloadBtn), styled in
styles.css so wide touch viewports get it too. Non-touch pages skip
its work entirely.
- Docs, JSDoc and a changeset. Unit tests, and a Playwright browser test
with trusted touch events and real xterm.
Fixes#814
Review follow-up. The early re-pull sampled the live-output generation after
its fetch, but nothing gates live output while the capture downloads, so
output newer than the capture was overwritten and the session marked clean.
Sample before the fetch.
Travel made during the replay was one signed sum clamped once, so scrolling
to the bottom and back up cancelled out. Record moves in order and clamp
after each, as live scrolling does.
A tmux repaint burst overwrites rows that never reach xterm scrollback,
leaving a hole just above the live screen. The #205 re-pull only fired at
viewportY 0, so the user had to scroll past the hole first.
Mark a non-shell session dirty on each live write; the first upward scroll
from the bottom of a dirty session runs the existing full-history re-pull
anchored to the bottom, keeping the viewport's distance from live output and
replaying travel made during the replay. Cooldown, downgrade guard and the
top-of-buffer path are unchanged.
caret() also returns generation; the parsed-buffer marker waits for a parsed write only when it changes.
Say the wait is a heuristic, not a delivery acknowledgement.
Toolbar Enter spends one-shot Ctrl; Backspace finds the last grapheme with Segments.containing(); accessory Shift+Tab keeps the draft like a typed one.
Pass the captured session to Compose uploads, voice compose and held CJK drafts; clear Ctrl on deletion-only native edits; path picker clears predictions.
Clear xterm dead-key state on native commits; restore a borrowed clipboard field before classifying a key; overlay removeChar spans the pending/flushed boundary.
Place the trackpad caret from the overlay layout (getInputAnchor, committedText) or validated xterm cells, hiding when unproven; no end-minus-width arithmetic.
Grapheme-aware replay Backspace; docs, README rows, changeset and comment updates.
Both editBetween() functions return a pure append as-is before the grapheme split, so a mark typed onto the last letter is not a DEL plus the retyped cluster (zsh would double the base letter).
Drop a redundant setFlushed() in the Tab-completion fallback; detectBufferText() already stores it.
The keyCode-229 recovery diff counts grapheme clusters, matching the overlay and the iOS owner, so one Backspace on a multi-code-point emoji is one DEL.
List xterm-zerolag-input in the changeset; document getInputEndAnchor(), onLayout() and the grapheme unit of removeChar().
Count native edits and overlay deletions in grapheme clusters (Intl.Segmenter, code-point fallback), so one Backspace on a multi-code-point emoji sends one DEL.
Toolbar Enter with echo off tells the codex predictor about the CR, clearing its predictions as typed Enter does.
Fall back to the keyCode-229 recovery when the iOS owner refuses to start, in the main pane and tiles.
submitFromToolbar() puts the CR on the FIFO, bypassing xterm scrollOnUserInput; scroll the focused pane before sending.
Remove app.sendInput(), which has no production caller; update @dependency headers and test stubs.
Retarget the codex predictive-echo recorders to _enqueueReliableInput.
Correct the docs and the _sendInputAsync JSDoc for the session FIFO; drop stale _pendingInput stubs.
The single-user suite pinned this; the multi-user one only showed that
header-less requests are not counted. Fill the per-IP bucket with
malformed headers, then expect 401 + challenge for no header and 429
for another malformed one. Fails on master.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The pipeline list said it "runs in this order" but put the no-header
challenge before the HTTP Basic check, while single-user auth.ts checks
the correct password first. Swap steps 3 and 4. Note in the README and
the Security / Remote-Access wiki pages that a request with no
credentials is never counted, and add the patch changeset.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Held-mode Ctrl, Backspace and restored drafts send to the session their text was typed for; a Ctrl-only field releases it.
Voice compose Send settles the iOS owner without flushing the unsent local-echo draft.
Cover Send on Enter across focus moves, the toolbar Enter in the CJK field and the same-session reload.
Describe Pane B iOS input ownership; drop a stub for a removed helper.
Review on #838. The unchanged half had no test: send the cap's worth of
`Authorization: Bearer x` and expect the next request to be 429, in
single-user and multi-user mode. Both fail if the header-less skip is
widened to malformed headers.
docs/security-architecture.md gets a pipeline step for the header-less
challenge (not counted, even during a lockout), and the Rate limit rows in
CLAUDE.md and docs/architecture-invariants.md say so, so a later change
cannot bring the counting back unnoticed. auth.ts uses challengeBasicAuth()
at the two spots that still inlined it, with a blank comment line before
the new paragraph.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The native owner bypasses xterm triggerDataEvent, so scrollOnUserInput never ran; scroll before sending.
Derive the local-echo overlay switch from the echo policy instead of a second mode check.
Link docs/ios-native-input.md and describe Pane B input ownership on iOS.
Keep the unsent draft out of slash-command keys; settle the iOS owner without flushing local echo.
Restore the overlay last-prompt fallback and the #520 Shift/Ctrl+Enter gate guard.
Pin the xterm privates the iOS owner needs; retarget browser/mobile harnesses to the session FIFO edge.
Document the session FIFO invariants and link #830 for the device sequences.
One changeset for everything since 1.51.0: the eleven PRs merged on this
branch, #803's MLX row and #812 already on master, the dead-code cleanup and
the fixes applied while landing. It replaces the eight PR changesets. Patch
until the owner says otherwise.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Removing THROTTLE_DELAY_MS and STATS_POLLING_INTERVAL_MS in 6fb8b277 left
each neighbour carrying the deleted line's comment, so the toast maximum read
as a throttle delay and the terminal sync wait as stats polling.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
A test pins the symlink and non-file branch of the reply store (a planted
link or a folder at the metadata path is never replaced, and replies are
still accepted), the @fileoverview names the file, its bounds, where the
bridge claims and the four rules a reader has to keep, and a comment left
from the #793 journal approach says store file.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Each allowed Discord reply is claimed by its message id in a small private store (discord-reply-dedupe.json, 0600) before the rate-limit and exited-agent checks; when the store fails the bridge falls back to memory and still types the reply.
The owner of a managed dsh tab is compared with the server's starter only in
multi-user mode: a record created there keeps its owner, while a single-user
start records none, so that tab would never get its cookie again (new route
test). CLAUDE.md and the invariants doc name the cookie rules. The third item,
Codeman's session cookie filtered on the WebSocket leg whether or not the dsh
cookie is injected, came in with the merge itself, where it met #827.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The format check passes again (Prettier breaks the createCpuUsageMeter call
one argument per line), and the load-average fallback answers 0 instead of
dividing by a core count of 0 on the platform it exists for, where cpus()
is empty.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
A comment says why the wait after the kill keeps its 2>/dev/null (bash 3.2
prints a Terminated job line there, bash 5.2 does not, so CI would not
notice its removal), and the two probe tests use the file's own imports.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The blank list-keys -T answer is not a development-build quirk: tmux commit
09bd686327 sent a one-binding listing to a status message instead of stdout,
and it shipped in 3.7, 3.7a, 3.7b and 3.7c until 7ec94fda08 fixed it for 3.8.
The comments, the tests and the invariants doc now say so.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The fs.watch failure tests skip on macOS, where chokidar 3 never calls
fs.watch for these watchers (fsevents, or polling without it), so the stub
never fired and the waits timed out. TeamWatcher.stop() clears its outage
set, so a stop() and start() on the same instance warns again about a
watcher that still fails; a new test pins it.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The wheel gate reads each CLI's wheelForward rule from the registry (window.__codemanWheelForward) instead of a list of ids, so a custom full-screen CLI in clis.json can opt in.
A persistent:false watcher closes on its first error (closeWatcherOnError), so a failing fs.watch costs one warning instead of an endless climb to /, and TeamWatcher re-creates a stopped watcher from its 30 s poll.
The DeepSeek Harness web tab trades the dsh web launch token for its session cookie, a relative <base href> resolves against the document's own directory, and root-absolute import("/...") inside scripts is rewritten onto the proxy prefix.
# Conflicts:
# src/web/routes/webview-routes.ts
# test/routes/webview-routes.test.ts