fix(vscode): persist snapshot setting per project - #13198
Conversation
| const PROJECT_SCOPED_KEYS: ReadonlySet<string> = new Set(["commit_message"]) | ||
| // global one. Settings that are inherently per-repository (e.g. snapshots and | ||
| // commit message conventions) belong here so they don't leak across workspaces. | ||
| const PROJECT_SCOPED_KEYS: ReadonlySet<string> = new Set(["commit_message", "snapshot"]) |
There was a problem hiding this comment.
SUGGESTION: Consider cleaning up the stale global snapshot value written by the old code path
Users who disabled Checkpoints before this fix already have snapshot: false persisted in their global config. After this change, the Checkpoints toggle only ever writes project scope, so:
- Re-enabling snapshots in one project writes
snapshot: trueto that project's config, but the stale globalsnapshot: falsekeeps snapshots disabled in every other project. - There is no Settings UI path to unset the global key (the toggle now routes exclusively to project scope), so affected users can only fix it per-project or by hand-editing the global config file.
Not blocking — the per-project toggle self-heals each workspace — but you may want to also send a global unset for snapshot when saving the project-scoped value, or do a one-time cleanup on load.
Reply with @kilocode-bot fix it to have Kilo Code address this issue.
Code Review SummaryStatus: 1 Issue Found | Recommendation: Address before merge Overview
The fix is correct: Fix these issues in Kilo Cloud Issue Details (click to expand)SUGGESTION
Files Reviewed (3 files)
Reviewed by kimi-k3 · Input: 67.7K · Output: 9K · Cached: 920.7K Review guidance: REVIEW.md from base branch |
|
Closing this PR as superseded by #13195. The project-scoped Checkpoints toggle is not the right fix: the normal Settings toggle should retain its existing user/global behavior. #13195 fixes the actual slow-repository popup bug by preserving the project instance context while persisting |
The Checkpoints setting was saved through the generic config path, but
snapshotwas not included in the project-scoped key set. As a result, disabling snapshots from Settings wrotesnapshot: falseto the global config, where a project-level override could take precedence again after restarting VS Code.Classify
snapshotas project-scoped and add a regression test covering the split. This makes the Settings toggle persist in the workspacekilo.jsoncand remain effective across restarts.Fixes #13134