enable async tool discovery by making the registry accessor async; remove call to discoverTools that caused duplicate discovery (#691)

This commit is contained in:
Olcan
2025-06-02 09:56:32 -07:00
committed by GitHub
parent 467dec4edf
commit c5869db080
7 changed files with 21 additions and 20 deletions

View File

@@ -40,8 +40,7 @@ export async function runNonInteractive(
input: string,
): Promise<void> {
const geminiClient = new GeminiClient(config);
const toolRegistry: ToolRegistry = config.getToolRegistry();
await toolRegistry.discoverTools();
const toolRegistry: ToolRegistry = await config.getToolRegistry();
const chat = await geminiClient.startChat();
const abortController = new AbortController();