Conversation
code-crusher
commented
Feb 23, 2026
- rename to Orbital extension
- feat: prevent duplicate tool calls in streaming responses
- Add tool call signature tracking to detect duplicate executions - Implement getToolCallSignature() and checkAndRegisterToolCall() methods - Clear signature cache on new user messages to allow re-execution - Update presentAssistantMessage to skip duplicate tool calls - Improve readFileTool to calculate effective limit based on actual file size
There was a problem hiding this comment.
🧪 PR Review is completed: The PR successfully implements the rebranding to 'Orbital' across the codebase. However, there are a few critical issues: a syntax error in a Playwright CSS selector, and a severe logic bug in getToolCallSignature where JSON.stringify strips nested object properties, leading to false-positive duplicate tool call detection.
Skipped files
DEVELOPMENT.md: Skipped file patternREADME.md: Skipped file patternapps/kilocode-docs/docs/advanced-usage/custom-rules.md: Skipped file patternapps/kilocode-docs/docs/advanced-usage/memory-bank.md: Skipped file patternapps/kilocode-docs/docs/basic-usage/how-tools-work.md: Skipped file patternapps/kilocode-docs/docs/basic-usage/the-chat-interface.md: Skipped file patternapps/kilocode-docs/docs/extending/contributing-to-kilo.md: Skipped file patternapps/kilocode-docs/docs/extending/development-environment.md: Skipped file patternapps/kilocode-docs/docs/features/checkpoints.md: Skipped file patternapps/kilocode-docs/docs/features/code-actions.md: Skipped file patternapps/kilocode-docs/docs/features/mcp/using-mcp-in-kilo-code.md: Skipped file patternapps/kilocode-docs/docs/getting-started/installing.md: Skipped file patternapps/kilocode-docs/docs/providers/anthropic.md: Skipped file patternapps/kilocode-docs/docs/providers/deepseek.md: Skipped file patternapps/kilocode-docs/docs/providers/fireworks.md: Skipped file patternapps/kilocode-docs/docs/providers/openai.md: Skipped file patternapps/kilocode-docs/docs/providers/xai.md: Skipped file patternapps/kilocode-docs/i18n/zh-CN/docusaurus-plugin-content-docs/current/extending/development-environment.md: Skipped file patternapps/kilocode-docs/i18n/zh-CN/docusaurus-plugin-content-docs/current/features/code-actions.md: Skipped file patternapps/kilocode-docs/i18n/zh-CN/docusaurus-plugin-content-docs/current/getting-started/installing.md: Skipped file patternapps/kilocode-docs/i18n/zh-CN/docusaurus-plugin-content-docs/current/providers/anthropic.md: Skipped file patternapps/kilocode-docs/i18n/zh-CN/docusaurus-plugin-content-docs/current/providers/deepseek.md: Skipped file patternapps/kilocode-docs/i18n/zh-CN/docusaurus-plugin-content-docs/current/providers/fireworks.md: Skipped file patternapps/kilocode-docs/i18n/zh-CN/docusaurus-plugin-content-docs/current/providers/openai.md: Skipped file patternapps/kilocode-docs/i18n/zh-CN/docusaurus-theme-classic/navbar.json: Skipped file patterncli/package.dist.json: Skipped file patternsrc/i18n/locales/ar/common.json: Skipped file patternsrc/i18n/locales/ca/common.json: Skipped file patternsrc/i18n/locales/cs/common.json: Skipped file patternsrc/i18n/locales/de/common.json: Skipped file patternsrc/i18n/locales/en/common.json: Skipped file patternsrc/i18n/locales/es/common.json: Skipped file patternsrc/i18n/locales/fr/common.json: Skipped file patternsrc/i18n/locales/hi/common.json: Skipped file patternsrc/i18n/locales/id/common.json: Skipped file patternsrc/i18n/locales/it/common.json: Skipped file patternsrc/i18n/locales/ja/common.json: Skipped file patternsrc/i18n/locales/ko/common.json: Skipped file patternsrc/i18n/locales/nl/common.json: Skipped file patternsrc/i18n/locales/pl/common.json: Skipped file patternsrc/i18n/locales/pt-BR/common.json: Skipped file patternsrc/i18n/locales/ru/common.json: Skipped file patternsrc/i18n/locales/th/common.json: Skipped file patternsrc/i18n/locales/tr/common.json: Skipped file patternsrc/i18n/locales/uk/common.json: Skipped file patternsrc/i18n/locales/vi/common.json: Skipped file patternsrc/i18n/locales/zh-CN/common.json: Skipped file patternsrc/i18n/locales/zh-CN/kilocode.json: Skipped file patternsrc/i18n/locales/zh-TW/common.json: Skipped file patternsrc/package.nls.ar.json: Skipped file patternsrc/package.nls.ca.json: Skipped file patternsrc/package.nls.cs.json: Skipped file patternsrc/package.nls.de.json: Skipped file patternsrc/package.nls.es.json: Skipped file patternsrc/package.nls.fr.json: Skipped file patternsrc/package.nls.hi.json: Skipped file patternsrc/package.nls.id.json: Skipped file patternsrc/package.nls.it.json: Skipped file patternsrc/package.nls.ja.json: Skipped file patternsrc/package.nls.json: Skipped file patternsrc/package.nls.ko.json: Skipped file patternsrc/package.nls.nl.json: Skipped file patternsrc/package.nls.pl.json: Skipped file patternsrc/package.nls.pt-BR.json: Skipped file patternsrc/package.nls.ru.json: Skipped file patternsrc/package.nls.th.json: Skipped file pattern
⬇️ Low Priority Suggestions (1)
cli/src/commands/teams.ts (1 suggestion)
Location:
cli/src/commands/teams.ts(Lines 10-10)🔵 Documentation
Issue: The example in the comment is outdated after the rebranding. "Orbital" would normalize to "orbital", not "kilo-code".
Fix: Update the comment to reflect the correct normalization.
Impact: Improves code documentation accuracy.
- * Example: "Orbital" -> "kilo-code" + * Example: "Orbital" -> "orbital"
| public getToolCallSignature(toolName: string, params: Record<string, unknown>): string { | ||
| // Ensure params is an object before sorting keys (defensive against null/undefined from LLM output) | ||
| const safeParams = params || {} | ||
| const sortedParams = JSON.stringify(safeParams, Object.keys(safeParams).sort()) | ||
| return `${toolName}:${sortedParams}` | ||
| } |
There was a problem hiding this comment.
🔴 Logic Error
Issue: Using Object.keys(safeParams).sort() as the replacer array in JSON.stringify will strip all nested object properties that don't share a key name with the top-level object. This causes different tool calls with identical top-level keys but different nested values to generate the exact same signature, leading to false-positive duplicate detection and dropped tool calls.
Fix: Use a recursive sorting function to deterministically sort all keys at all levels before stringifying.
Impact: Prevents valid tool calls from being incorrectly blocked as duplicates.
| public getToolCallSignature(toolName: string, params: Record<string, unknown>): string { | |
| // Ensure params is an object before sorting keys (defensive against null/undefined from LLM output) | |
| const safeParams = params || {} | |
| const sortedParams = JSON.stringify(safeParams, Object.keys(safeParams).sort()) | |
| return `${toolName}:${sortedParams}` | |
| } | |
| public getToolCallSignature(toolName: string, params: Record<string, unknown>): string { | |
| // Ensure params is an object before sorting keys (defensive against null/undefined from LLM output) | |
| const safeParams = params || {} | |
| const sortObject = (obj: any): any => { | |
| if (obj === null || typeof obj !== "object") return obj | |
| if (Array.isArray(obj)) return obj.map(sortObject) | |
| return Object.keys(obj).sort().reduce((acc, key) => { | |
| acc[key] = sortObject(obj[key]) | |
| return acc | |
| }, {} as Record<string, any>) | |
| } | |
| const sortedParams = JSON.stringify(sortObject(safeParams)) | |
| return `${toolName}:${sortedParams}` | |
| } |
Co-authored-by: matter-ai-bot[bot] <150888575+matter-ai-bot[bot]@users.noreply.github.com>
Co-authored-by: matter-ai-bot[bot] <150888575+matter-ai-bot[bot]@users.noreply.github.com>
|
✅ Reviewed the changes: The PR successfully implements the suggested fix for the line counting fallback logic. |
1 similar comment
|
✅ Reviewed the changes: The PR successfully implements the suggested fix for the line counting fallback logic. |
…g, improve MCP UI icons - Update all MCP documentation links from /features/mcp/using-mcp-in-kilo-code to /orbital/features/mcp - Fix getToolCallSignature to recursively sort object keys for deterministic serialization - Replace codicon icons with custom Delete01Icon and Refresh04Icon in McpView - Adjust MCP server list spacing and padding for better UI - Fix locator selector in vscode-helpers.ts for extension verification
|
✅ Reviewed the changes: The PR looks good. The deterministic tool call signature generation is implemented correctly with recursive key sorting, and the UI/documentation link updates are straightforward and clean. |