From 33a0b6093ec55b60e9fd7d964630026661aea144 Mon Sep 17 00:00:00 2001 From: "google-labs-jules[bot]" <161369871+google-labs-jules[bot]@users.noreply.github.com> Date: Fri, 9 Jan 2026 18:37:58 +0000 Subject: [PATCH] cleanup: remove obsolete comments and unused code in ToolManager Removed `extraTools` variable which was unused and associated obsolete "thinking" comments that described previous refactoring issues. This cleans up the code in `src/runner/executors/llm/tool-manager.ts` without affecting functionality. --- src/runner/executors/llm/tool-manager.ts | 18 ------------------ 1 file changed, 18 deletions(-) diff --git a/src/runner/executors/llm/tool-manager.ts b/src/runner/executors/llm/tool-manager.ts index 2d345de..c000139 100644 --- a/src/runner/executors/llm/tool-manager.ts +++ b/src/runner/executors/llm/tool-manager.ts @@ -73,24 +73,6 @@ export class ToolManager { // 2. Step Tools & Standard Tools const standardToolsRecord = STANDARD_TOOLS as any; // Handle index signature issue - const extraTools = [ - ...(step.tools || []), - ...(step.useStandardTools ? Object.values(standardToolsRecord) : []), - ]; - - // Logic to merge standard tools correctly: - // If useStandardTools is true, we want all standard tools. - // But the loop above iterates over step.tools (definitions) + values? - // In original code: const extraTools = [...(step.tools || []), ...(step.useStandardTools ? STANDARD_TOOLS : [])]; - // Wait, STANDARD_TOOLS is an object, not array. - // Original code issue: `step.useStandardTools ? STANDARD_TOOLS : []` -> if STANDARD_TOOLS is object, iterate? - // In original code: `for (const tool of extraTools)` - // If STANDARD_TOOLS is object, it is NOT iterable. - // The original code probably relied on `STANDARD_TOOLS` being iterable or `Object.values` was intended? - // Actually, `STANDARD_TOOLS` import in `llm-executor` might be different? - // No, strictly it probably failed if `useStandardTools` was true unless `STANDARD_TOOLS` is array-like. - // Let's assume `STANDARD_TOOLS` is a Record. - // I will iterate properly. const toolsToRegister: any[] = [...(step.tools || [])]; if (step.useStandardTools === true) {