From 237c9aa02f771f4abf3a3568ac3b526c5581b163 Mon Sep 17 00:00:00 2001 From: Saoud Rizwan <7799382+saoudrizwan@users.noreply.github.com> Date: Thu, 3 Oct 2024 03:16:37 -0400 Subject: [PATCH] Fix recursive api request generator --- src/core/ClaudeDev.ts | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/core/ClaudeDev.ts b/src/core/ClaudeDev.ts index a14e5fc..e7abee0 100644 --- a/src/core/ClaudeDev.ts +++ b/src/core/ClaudeDev.ts @@ -751,7 +751,8 @@ export class ClaudeDev { throw new Error("API request failed") } await this.say("api_req_retried") - return this.attemptApiRequest(previousApiReqIndex) + // delegate generator output from the recursive call + yield* this.attemptApiRequest(previousApiReqIndex) } }