Repository navigation
perf(chat): cache revisions for immutable conversation turns - #788
Conversation
|
Warning Review limit reachedYou've used all free OSS reviews for now. Wait for the free limit to reset to keep reviewing this public repository. Next included review available in 37 minutes. View limit details
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info
📝 Summary
Merge Risk: ⚪ Minimal · up to No current ChatView update path was found to mutate cached turns, so this change has no identified merge-blocking risk. Pre-merge checks |
|
…791) ## Change When an agent's structured conversation is not yet available, ChatView used to await a terminal read even while its terminal-output disclosure was folded. A stalled read held the serialized conversation reader and delayed initial display and later structured answers. Agent terminal fallback now reads independently, only while its disclosure is open and the page is visible. Non-agent scrollback stays inline. Conversation/terminal HTTP headers and JSON/error bodies share a 15-second deadline; a timed-out late answer cannot replace the conversation ETag cache. Changing the agent in the same pane reinstalls and immediately refreshes the reader. This standalone change is separate from #650's Codex session identity work and #783's Send now behavior. It adds ko/ja/zh timeout labels, documentation/changelog and registered/typechecked browser coverage without private APIs or deployment configuration. ## Validation - Generated schema freshness, full typecheck and production build: pass. - Full unit suite: 2,508 pass, 50 skip, 0 fail (138.02s). Header/body stalls, ignored-abort late body and ETag identity/recovery covered. - Actual ChatView browser: no hidden terminal read; an opened stalled fallback cannot block structured refresh; late cleanup; same-pane agent-kind change resumes reads; non-agent output remains inline. - Complete official browser lane: pass (492.2s), including the new regression. - Independent implementation review: GO; agent-change polling finding reproduced and fixed before re-review. - Workflow syntax skipped (actionlint unavailable); no workflow YAML changed. No separate Native integration pass is claimed: unchanged-server baseline comparison is recorded in #787/#788. Fork CI requires maintainer approval. Synthetic [closed fallback screenshot](https://github.com/kilhyeonjun/herdr-web-ui/blob/fix/chat-read-fallback-20261011/docs/screenshots/chat-fallback/terminal-fallback-closed.png). ## Review follow-up Addressed both posted review findings: agent terminal fallback no longer presents an empty-conversation prompt, and terminal-read failures use `role="alert"`. The actual ChatView browser regression reproduced both before the fixes and now verifies fallback/failure, the ordinary empty structured-conversation prompt, non-agent inline output and stale cleanup. Frozen final commit `a1ff9a3`: generated freshness, typecheck, build and full unit pass (2508 pass, 50 skip, zero failures; unit 138.33s). The previously reported full browser lane ran on `22f707b`; the updated focused actual-component browser regression passed for the two UI fixes, with refreshed synthetic evidence. Changelog now links this PR and credits its author. Validation remains against public baseline `2f6bb46`; latest observed main `5eafefc` is separate, and full Native/Windows/updated-main integration is not claimed. --------- Co-authored-by: Hako <[email protected]> Co-authored-by: Claude Opus 5.5 <[email protected]> Co-authored-by: devswha <[email protected]>
The changelog entry moves under Unreleased: the branch was cut before 0.4.6 and 0.4.7 were released. Unreleased had two Fixed headings on main since a clean auto-merge; they are one again here. Co-Authored-By: Claude Fable 5.1 <[email protected]>
## Change Release 0.4.8, from main at ca6db6e (20 PRs since v0.4.7: the 0.4.7 mobile walk-through fixes, two contributor PRs and the revived #793). - `package.json` and `herdr-plugin.toml`: 0.4.8. - CHANGELOG: `[Unreleased]` becomes `[0.4.8] - 2026-10-12`, with the compare links. Twelve entries that had no PR link get theirs (#835 #837 #838 #840 #842 #843 #844+#848 #845 #847 #849 #851 #852). A Maintenance line says the remote-PC runtime is now version 27. - `release-summaries.json`: 0.4.8 in en/ko/ja/zh/tr (3 new, 6 improved, 8 fixed). The Turkish lines are not checked by a native speaker. - `REMOTE_BUNDLE_VERSION` 26 -> 27: #836 adds the `pending-hold` server feature and #787 serves precompressed assets, so `remote-v27` is published before the app release. Every PR merged since v0.4.7 is linked in the section: #787 #788 #793 #835 #836 #837 #838 #839 #840 #841 #842 #843 #844 #845 #846 #847 #848 #849 #851 #852. ## Validation - `bun scripts/release-notes.ts 0.4.8` renders the summaries and the full changelog (116 lines). - `bun run check fast`: generated types, typecheck, build and 2800+ unit tests pass. ## Release After this merges and its CI on `main` passes: push `remote-v27`, wait for its release, then run the Release workflow with `0.4.8`. 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-authored-by: Claude Fable 5.1 <[email protected]>
Conflicts: version 0.4.801; the classic tab strip and one-pane canvas kept beside upstream devswha#835's pane actions in the touch tab menu; the open latest work prop kept with devswha#788's immutable turn revisions. Upstream devswha#846 removed the header's plan button and its dialog: they stay as the default, and its plan in the background-task chip is Settings → Appearance → Plan in the message box, off (on under automation). Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
Change
Unrelated chat renders no longer rescan an unchanged immutable conversation turn to build its render-boundary revision. An explicit immutable opt-in caches revisions in a WeakMap; the default remains mutation-sensitive, including same-length edits. Only ChatView's API snapshot turns opt in. New snapshots retain new revisions and the existing boundary behavior.
This is a standalone client optimization from main. It does not change API polling, ETag responses, turn sharing or pane state. Includes mutation/read-count regression tests and the immutability contract in source documentation.
Validation
The Native integration suite was also run, not marked green: cache 397 pass/5 fail/6 skip (295.2s), compression 398 pass/4 fail/6 skip (307.7s). An unchanged same-SHA baseline with the same Bun/herdr binary reproduced all those named failures: 396 pass/6 fail/6 skip (285.1s), in the same three unchanged server contract files. No new named failure in either candidate. Main has since merged the pending-input fixture polling fix (#756); this branch is independently based on 2f6bb46.
Workflow syntax skipped (actionlint unavailable); no workflow YAML changed. Fork CI requires maintainer approval.