feat(vscode): add option to extend viewable sessions limit - #14272
lightmanLP wants to merge 3 commits into
Conversation
| "description": "Render Markdown files in Kilo diff viewers by default. Toggle this from a Markdown file header in the diff viewer." | ||
| }, | ||
| "kilo-code.new.sessionsLimit": { | ||
| "type": "number", |
There was a problem hiding this comment.
SUGGESTION: The setting is declared as number, which permits decimals, but the value is passed straight through to the session-list limit query and into a SQL LIMIT. The server schema for session.list (ListQuery.limit in packages/opencode/src/server/routes/instance/httpapi/groups/session.ts) does not enforce an integer, unlike the message pagination query which checks Schema.isInt(), so a value like 100.5 reaches the query unchanged. Using "type": "integer" keeps the value well-formed.
Reply with @kilocode-bot fix it to have Kilo Code address this issue.
There was a problem hiding this comment.
To use Kilo from GitHub you first need to link your GitHub account to Kilo. Link your Kilo account to continue. After linking, mention me again in this issue or pull request.
| { | ||
| directory: dir, | ||
| roots: true, | ||
| limit: vscode.workspace.getConfiguration("kilo-code.new").get<number>("sessionsLimit", 100) |
There was a problem hiding this comment.
SUGGESTION: Consider bounding this value. loadSessions calls the listSessions callback once for the workspace directory and once per registered worktree directory, then merges the results and posts every session to the webview on each refresh. A very large sessionsLimit multiplies both the rows fetched from the backend and the payload sent to the webview, so an accidental unbounded value can make history loading noticeably slow. A maximum in the setting schema (or a smaller per-directory fetch with lazy loading) would keep this predictable.
Reply with @kilocode-bot fix it to have Kilo Code address this issue.
Code Review SummaryStatus: 1 Issue Found | Recommendation: Address before merge Overview
Issue Details (click to expand)SUGGESTION
Files Reviewed (3 files)
Fix these issues in Kilo Cloud Previous Review Summary (commit e9e57ce)Current summary above is authoritative. Previous snapshots are kept for context only. Previous review (commit e9e57ce)Status: 3 Issues Found | Recommendation: Address before merge Overview
Issue Details (click to expand)SUGGESTION
Files Reviewed (2 files)
Reviewed by deepseek-v4.1-flash · Input: 0 · Output: 0 · Cached: 0 Review guidance: REVIEW.md from base branch |
|
Thanks for the feedback and effort @lightmanLP , I opted for paging instead. Thanks |
Issue
I just saw that my old sessions disappeared from tabs suddenly. I tried to reopen them, but list just can't show em, cause there was more than 100 sessions between.
Context
Allows you to view more than 100 sessions in vscode extension.
Implementation
Its really basic edit, I just hooked limit to config variable.
How to Test
Manual/local verification
Checklist