Skip to content

fix(vscode): keep indexing status in sync - #13796

Merged
marius-kilocode merged 3 commits into
mainfrom
investigate-stuck-indexing
Sep 4, 2026
Merged

fix(vscode): keep indexing status in sync#13796
marius-kilocode merged 3 commits into
mainfrom
investigate-stuck-indexing

Conversation

@marius-kilocode

@marius-kilocode marius-kilocode commented Sep 4, 2026

Copy link
Copy Markdown
Collaborator

What Problem This Solves

Codebase indexing can remain on an old "Indexing is initializing" status after the worker has finished. A delayed consent HTTP response can overwrite a newer completion event, status events can be discarded when a repository subfolder differs from the resolved indexing root, and reconnecting does not refresh the status.

Directories containing characters outside the HTTP header ByteString range also prevent the consent request from being sent at all. Closes #13769.

Why This Change Was Made

Keep HTTP responses and live status events tied to the same indexing target. Newer events invalidate pending status snapshots, superseded targets cannot overwrite the current view, and project-scoped events retain their project ID. Explicit consent revocation keeps its authoritative Disabled response even if old progress arrives in flight. A delayed save for another project still applies consent without replacing the selected status target. Refresh indexing on reconnect without waiting for the profile request. Encode the directory header using the same convention as the SDK.

The patch is limited to extension consent and status handling. It does not change embedding requests, indexing concurrency, file discovery, or diagnostic logging, and does not claim to fix every backend indexing stall.

User Impact

Indexing can be enabled from Unicode-named paths. Repository subfolders receive completion updates for their resolved project root, and a late response no longer puts a completed index back into an initializing state.

Evidence

  • 135 focused indexing, consent, session-refresh, routing, and architecture tests pass, including Unicode/percent encoding, delayed HTTP versus live completion, project-root filtering, reconnect-before-profile, consent revocation during progress, and delayed saves after switching projects. The architecture guard checks the complete connection callback rather than an arbitrary character window.
  • Extension typecheck, lint, build, unused-export guard, marker guard, formatting, and diff checks pass. The complete local unit suite exceeded its 120-second command limit; it was not counted as a pass.
  • Self-tested the built extension in isolated VS Code on macOS, opening a subfolder of a Unicode-named Git repository. A localhost embedding fixture and LanceDB processed the files and reached IDX Complete. The completed state also appeared after reloading VS Code. After the consent-race fixes, disabling showed IDX Disabled and re-enabling returned to IDX Complete. The isolated instances were cleaned up afterward. The original reporter's Windows environment was not available.

Indexing enabled with IDX Complete and File watcher started. Index up-to-date.

Indexing disabled with the matching IDX Disabled status.

Comment thread packages/kilo-vscode/src/KiloProvider.ts
@kilo-code-bot

This comment has been minimized.

Comment thread packages/kilo-vscode/src/KiloProvider.ts Outdated
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.

Code indexing permanently stuck at "Indexing disabled." when the workspace path contains non-ASCII characters

2 participants