fix(coding-agent): show errors from write tool in UI

fixes #856
This commit is contained in:
Mario Zechner 2026-01-19 22:30:23 +01:00
parent d37b5a52d7
commit 46545276e3
2 changed files with 12 additions and 0 deletions

View file

@ -2,6 +2,10 @@
## [Unreleased]
### Fixed
- Fixed `write` tool not displaying errors in the UI when execution fails ([#856](https://github.com/badlogic/pi-mono/issues/856))
## [0.49.2] - 2026-01-19
### Added

View file

@ -542,6 +542,14 @@ export class ToolExecutionComponent extends Container {
` ${keyHint("expandTools", "to expand")})`;
}
}
// Show error if tool execution failed
if (this.result?.isError) {
const errorText = this.getTextOutput();
if (errorText) {
text += `\n\n${theme.fg("error", errorText)}`;
}
}
} else if (this.toolName === "edit") {
const rawPath = this.args?.file_path || this.args?.path || "";
const path = shortenPath(rawPath);