Skip to content

fix: preserve web UI scrollback after compaction#781

Merged
SamSaffron merged 1 commit into
SamSaffron:mainfrom
sam-saffron-jarvis:feat/webui-compaction-scroll
Jun 8, 2026
Merged

fix: preserve web UI scrollback after compaction#781
SamSaffron merged 1 commit into
SamSaffron:mainfrom
sam-saffron-jarvis:feat/webui-compaction-scroll

Conversation

@sam-saffron-jarvis

Copy link
Copy Markdown
Contributor

What

Fix the web UI session-history tail refresh path so a compaction refresh cannot discard already-loaded pre-compaction scrollback when the refreshed tail window no longer overlaps the browser's local history.

Why

After context compaction, the server appends a compacted active-context suffix and reports compaction_seq. A post-run tail refresh can be non-overlapping with the browser's currently loaded pre-compaction transcript. The old merge path treated that as a brand-new tail and replaced local history, leaving nothing to scroll up to.

Verification

  • mise exec node@24 -- node internal/serveui/static/app_sessions_test.js
  • go build ./...
  • go test ./...

@sam-saffron-jarvis sam-saffron-jarvis force-pushed the feat/webui-compaction-scroll branch from 14de2ae to 72266d0 Compare June 8, 2026 22:33
@SamSaffron SamSaffron merged commit 13fe6b9 into SamSaffron:main Jun 8, 2026
1 check 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.

2 participants