handle errors correctly in the edit tool
This commit is contained in:
parent
9ae05fea12
commit
921f5ee5bd
4 changed files with 78 additions and 82 deletions
|
|
@ -183,7 +183,7 @@ func (w *writeTool) Run(ctx context.Context, call ToolCall) (ToolResponse, error
|
|||
|
||||
result := fmt.Sprintf("File successfully written: %s", filePath)
|
||||
result = fmt.Sprintf("<result>\n%s\n</result>", result)
|
||||
result += appendDiagnostics(filePath, w.lspClients)
|
||||
result += getDiagnostics(filePath, w.lspClients)
|
||||
return WithResponseMetadata(NewTextResponse(result),
|
||||
WriteResponseMetadata{
|
||||
Additions: stats.Additions,
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue