feat(mobile): pinned "Active now" tray on the Agents session list#4626
Open
iscekic wants to merge 4 commits into
Open
feat(mobile): pinned "Active now" tray on the Agents session list#4626iscekic wants to merge 4 commits into
iscekic wants to merge 4 commits into
Conversation
The Agents session list body/full-screen error was driven by the combined isError (stored || active), so a transient active-poll failure could wrongly surface a full-screen "Could not load sessions" (or a query-error-empty under the tray) instead of the intended first-use / no-past-sessions state. Active poll failures already surface only through the inline "Couldn't refresh" line via activeIsError, per the useAgentSessions contract. Wire the non-search body error to storedIsError so active blips never hide stored history.
Contributor
Code Review SummaryStatus: No Issues Found | Recommendation: Merge Executive SummaryReviewed the mobile "Active now" tray UI/state-machine, the web active-sessions enrichment router (tenant-scoped, two-phase failure handling verified against the PR's stated non-collapse behavior), and the shared Files Reviewed (23 files)
Reviewed by claude-sonnet-5 · Input: 26 · Output: 7.6K · Cached: 607.6K Review guidance: REVIEW.md from base branch |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Adds a pinned "Active now" tray to the Agents session list. Live sessions are pinned above history and appear only in the tray (excluded from the history date sections), so an active session is never shown twice. Each tray row shows a platform badge (e.g.
CLI) — or aLIVEfallback when the session isn't enriched — alongside a live dot and a relative-time meta line.Stacked on top of
feature/mobile-agent-attention-notifications(PR #4605); please merge that first.What changed
activeSessions.listis enriched by joiningcli_sessions_v2for per-session platform + timestamps. Two-phase failure handling: a worker/parse failure degrades to an empty list; a DB failure during enrichment falls back to unenriched rows (never collapses the list).KNOWN_PLATFORMSrelocated to@kilocode/app-shared/platformsas the single source for web routers and the mobileotherbucket.selectPinnedActiveSessions,excludeActiveFromGroups,remoteAgentLabel/remoteMeta), theActiveNowSectiontray, asession-list-body-modelstate machine, and the section header / empty-body components. History rows are no longer markedlive; the tray owns live presentation viametaWhileLive. Loading→loaded uses an animated cross-fade; the inline "Couldn't refresh" retry line shows only when cached content is visible.Verification
LIVEfallback badge with empty history under the tray, and filtered active-only-empty with clear/restore.active-sessions-routertests pass.check:unused, and formatting are clean.Follow-ups (not in this PR)
sessions.heartbeatupdates into the mobile list so the tray updates without waiting on the 10s poll.LIVE/CLI) and meta to screen readers; today the row's accessibility label is the title only, matching the existing Home/history row pattern.