chore(vscode): remove unused translation keys - #12602
Conversation
| { name: "host", dict: hostEn, roots: [VSCODE], runtime: [] }, | ||
| ] as const | ||
|
|
||
| const EXACT_RE = /["'`]([a-zA-Z][a-zA-Z0-9_]*(?:[.:][a-zA-Z0-9_]+)+)["'`]/g |
There was a problem hiding this comment.
WARNING: Regex-based "used" detection scans raw file text, including comments/prose
EXACT_RE/PREFIX_RE/DYNAMIC_RE (lines 78-80) run over the entire raw text of every scanned file (text.matchAll(...)), not just executable string-literal positions. SOURCE_GLOB even includes .md/.mdx. This means a key or key-prefix mentioned inside a // comment, JSDoc example, or markdown prose is enough to mark it "used" and suppress the lint failure - a truly dead key can be kept alive indefinitely by a stray comment referencing its name. Since the test's explicit goal is to catch keys that "lose their last usage during refactors," it's worth noting this loophole so reviewers don't rely on a passing test as strong evidence a flagged-and-then-"fixed" key is genuinely used.
Reply with @kilocode-bot fix it to have Kilo Code address this issue.
| path.join(REPO, "packages/kilo-gateway"), | ||
| ] | ||
|
|
||
| const pools = [ |
There was a problem hiding this comment.
WARNING: packages/kilo-jetbrains is never scanned, so JetBrains-only key usage relies entirely on the manually curated runtime prefix lists
None of the roots in pools (line 63) or WEBVIEW_ROOTS (line 56) point at packages/kilo-jetbrains. Some shared protocol-style keys (e.g. plan.followup.question, settings.providers.note.*) are consumed directly from the JetBrains plugin (Kotlin/.properties), and this currently only avoids false failures because those exact prefixes already happen to be listed under runtime (lines 64/70-71/73). Any future key that's added to a Kilo-i18n dictionary and consumed only from the JetBrains side - without also adding its prefix to runtime - will be incorrectly flagged as dead and fail CI even though it's genuinely used. Consider either scanning the JetBrains source tree directly (SOURCE_GLOB on line 81 already includes kt,kts,java extensions, suggesting this was intended) or documenting that runtime must be kept in sync manually.
Reply with @kilocode-bot fix it to have Kilo Code address this issue.
| --- | ||
| "kilo-code": patch | ||
| --- | ||
|
|
There was a problem hiding this comment.
SUGGESTION: Changeset description reads as internal implementation notes rather than a user-facing summary
Removing unused i18n dictionary keys and adding an internal lint test has no user-visible effect, and the current text lists internal subsystems (Agent Manager, sidebar webview, kilo-i18n, autocomplete) and describes the added test - details end users reading release notes won't find meaningful. Per AGENTS.md, changeset text should describe what changed from a user's perspective. Consider trimming this to something like "Clean up unused translation strings" (or confirm this specific patch-only cleanup should even ship a changeset, since it has no functional/user impact).
Reply with @kilocode-bot fix it to have Kilo Code address this issue.
Code Review SummaryStatus: 3 Issues Found | Recommendation: Address before merge Overview
Issue Details (click to expand)WARNING
SUGGESTION
Files Reviewed (85 files)
Fix these issues in Kilo Cloud Reviewed by claude-sonnet-5 · Input: 40 · Output: 13.3K · Cached: 1.1M Review guidance: REVIEW.md from base branch |
* chore(vscode): remove unused translation keys * docs(kilo-docs): refresh source links
The VS Code translation dictionaries accumulated hundreds of keys copied from upstream or left behind by retired components. Keeping those keys synchronized across every locale creates substantial maintenance churn and obscures real translation coverage gaps.
This removes unreferenced keys from the Kilo-owned sidebar, Agent Manager, shared Kilo overrides, and autocomplete dictionaries while leaving upstream-owned
packages/uitranslations untouched.A conservative unit lint now checks Kilo-owned dictionaries against production source and resource files. It recognizes exact, template, prefix, backend-provided, and explicitly protected runtime keys, and directs contributors to review external/runtime consumers instead of deleting flagged keys automatically. This keeps locale files aligned with shipped surfaces without adding upstream merge conflicts or risking protocol-driven translations.