mirror of
https://github.com/SillyTavern/SillyTavern.git
synced 2025-06-05 21:59:27 +02:00
Tool Calling: stringify errors instead of silently failing
This commit is contained in:
@ -292,10 +292,10 @@ export class ToolManager {
|
||||
|
||||
if (error instanceof Error) {
|
||||
error.cause = name;
|
||||
return error;
|
||||
return error.toString();
|
||||
}
|
||||
|
||||
return new Error('Unknown error occurred while invoking the tool.', { cause: name });
|
||||
return new Error('Unknown error occurred while invoking the tool.', { cause: name }).toString();
|
||||
}
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user