Skip to content

fix(vscode): show consistent session activity indicators - #13504

Merged
marius-kilocode merged 7 commits into
mainfrom
improve-vscode-tab-session-status
Aug 28, 2026
Merged

fix(vscode): show consistent session activity indicators#13504
marius-kilocode merged 7 commits into
mainfrom
improve-vscode-tab-session-status

Conversation

@marius-kilocode

@marius-kilocode marius-kilocode commented Aug 27, 2026

Copy link
Copy Markdown
Collaborator

What Problem This Solves

When several sessions are open, a loading indicator alone does not show which session needs an answer or permission. Stopped, completed, and failed sessions also look too similar across the sidebar, native editor tabs, and Agent Manager.

Why This Change Was Made

Use one cached session-activity calculation for every presentation surface. Native editor tabs receive the derived state instead of maintaining a second backend-event state machine. Session ancestry comes from session metadata and task metadata, so a child request remains visible even when its originating task is outside the loaded transcript page.

The existing prompt-recovery path is preserved. There are no new polling loops or notification settings.

User Impact

Session state Sidebar tabs, Agent Manager tabs, and worktree cards Native editor tab
Running or retrying Loading indicator
Needs input or permission Amber warning
Completed Green check
Failed or disconnected while active Red warning
Idle Normal tab or worktree appearance No status prefix
  • Covers the sidebar's multiple-session tab strip and switcher, Open in Tab, standalone sub-agent tabs, Agent Manager session tabs, local/worktree cards, and session search.
  • Pending child questions, permissions, and suggestions take precedence over ongoing work in their parent context. A child's terminal outcome does not overwrite a recovered parent's outcome.
  • Answering a request, starting a new turn, or reverting clears the relevant old state. Removed worktrees and unrelated session history do not keep the native Agent Manager tab marked for attention.
  • Status colors use theme tokens and work without depending on Agent Manager styles being loaded into the sidebar.

Evidence

Automated checks

  • bun run compile: passed, including extension/webview typechecks, lint, and bundles.
  • bun run test:unit: 4,319 passed, 0 failed after resolving conflicts with current main.
  • bun run knip, bun run check-kilocode-change, package formatting, and diff whitespace checks passed.
  • The new mounted-provider regression drives real VS Code message transport through SessionProvider and renders actual Agent Manager tabs. It covers nested requests without loaded transcript pages, resolution, stale permissions, retry/offline states, completion/error ownership, next-turn and revert resets, reconnection, deletion, and disposal.

Screenshot tests

Added seven stories to the existing automatically discovered Playwright screenshot suite:

  • All session-tab states at the default sidebar width.
  • All session-tab states at 1280px.
  • Multiple sidebar sessions at 420px and 200px.
  • All worktree-card activity states, including selected worktrees.
  • Agent Manager session-tab states with its actual tab-bar styles.

The existing switcher story now uses a real portal and includes waiting and error states.

The original five stories and the three focused review-regression scenarios were rendered locally in dark and light themes. Repeated captures were byte-identical, and warning, success, and error colors were distinct. Spinner animation is frozen only in the screenshot fixtures. Linux baseline generation and pixel comparison run in CI; the repository intentionally skips baseline comparison on macOS.

VS Code self-test

Verified the sidebar's multiple-session tabs, native editor tabs, Agent Manager tabs, and worktree cards in isolated VS Code. Checked input-required priority, stale-permission recovery, completion, new-turn reset, failure, revert, reconnect, and removal/history scoping. These checks used controlled session events, not a live model round trip.

Native editor tabs

Native VS Code tabs showing a completed Agent Manager context and a Kilo session that needs attention

Multiple sessions in the sidebar

Sidebar session tabs showing running, input-required, and completed sessions

All tab states, dark and light themes

Dark theme session-tab states: running, needs input, completed, retrying, error, and idle

Light theme session-tab states: running, needs input, completed, retrying, error, and idle

Worktree cards

Agent Manager worktree cards showing all six activity states with consistent icons and colors

Manual test

Run two sessions in the sidebar or Agent Manager. Trigger a question or permission in one while the other runs, answer the request, then complete a session and start its next turn. Confirm that both the session tab and its native/context indicator update and that old attention or completion states clear.

Review regression checks in VS Code

Verified that the selected worktree retains its warning color and that the real portalled sidebar switcher retains warning, completion, and error colors.

Selected worktree retains its amber attention indicator

Portalled sidebar switcher retains warning, completion, and error colors

Comment thread packages/kilo-vscode/webview-ui/agent-manager/agent-manager.css Outdated
Comment thread packages/kilo-vscode/webview-ui/src/styles/session-tabs.css
@kilo-code-bot

This comment has been minimized.

@marius-kilocode
marius-kilocode force-pushed the improve-vscode-tab-session-status branch from 7a23321 to cdcf69e Compare August 27, 2026 11:17
@marius-kilocode
marius-kilocode force-pushed the improve-vscode-tab-session-status branch from 4cfe71d to ec20f8f Compare August 27, 2026 11:28
@marius-kilocode
marius-kilocode force-pushed the improve-vscode-tab-session-status branch from be85dc2 to 9a287dc Compare August 27, 2026 11:58
@marius-kilocode
marius-kilocode force-pushed the improve-vscode-tab-session-status branch from c2b5fc6 to f6ff101 Compare August 27, 2026 13:00
Comment thread packages/kilo-vscode/webview-ui/agent-manager/sidebar-search.ts Outdated
@marius-kilocode
marius-kilocode force-pushed the improve-vscode-tab-session-status branch from aeccb9b to 84a0b4b Compare August 28, 2026 06:02
@marius-kilocode
marius-kilocode merged commit 3c5c8c8 into main Aug 28, 2026
26 checks passed
@marius-kilocode
marius-kilocode deleted the improve-vscode-tab-session-status branch August 28, 2026 08:14
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