mirror of
https://github.com/Sea-Haven-Industries/open-swe.git
synced 2026-10-06 14:42:11 +00:00
fix: Better message when tool call returned empty string (#537)
* fix: Better message when tool call returned empty string * cr
This commit is contained in:
parent
ff5af2b93b
commit
e024341ddd
3 changed files with 12 additions and 3 deletions
|
|
@ -128,7 +128,10 @@ export async function takeActions(
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!result) {
|
if (!result) {
|
||||||
result = toolCallStatus;
|
result =
|
||||||
|
toolCallStatus === "success"
|
||||||
|
? "Tool call returned no result"
|
||||||
|
: "Tool call failed";
|
||||||
}
|
}
|
||||||
} catch (e) {
|
} catch (e) {
|
||||||
toolCallStatus = "error";
|
toolCallStatus = "error";
|
||||||
|
|
|
||||||
|
|
@ -124,7 +124,10 @@ export async function takeAction(
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!result) {
|
if (!result) {
|
||||||
result = toolCallStatus;
|
result =
|
||||||
|
toolCallStatus === "success"
|
||||||
|
? "Tool call returned no result"
|
||||||
|
: "Tool call failed";
|
||||||
}
|
}
|
||||||
} catch (e) {
|
} catch (e) {
|
||||||
toolCallStatus = "error";
|
toolCallStatus = "error";
|
||||||
|
|
|
||||||
|
|
@ -110,7 +110,10 @@ export async function takeReviewerActions(
|
||||||
toolCallStatus = toolResult.status;
|
toolCallStatus = toolResult.status;
|
||||||
|
|
||||||
if (!result) {
|
if (!result) {
|
||||||
result = toolCallStatus;
|
result =
|
||||||
|
toolCallStatus === "success"
|
||||||
|
? "Tool call returned no result"
|
||||||
|
: "Tool call failed";
|
||||||
}
|
}
|
||||||
} catch (e) {
|
} catch (e) {
|
||||||
toolCallStatus = "error";
|
toolCallStatus = "error";
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue