mirror of
https://github.com/getcompanion-ai/co-mono.git
synced 2026-04-15 17:00:59 +00:00
Release v0.7.18
This commit is contained in:
parent
a11c1aa4ff
commit
22d8a0ae4a
16 changed files with 284 additions and 174 deletions
|
|
@ -2,6 +2,13 @@
|
|||
|
||||
## [Unreleased]
|
||||
|
||||
## [0.7.18] - 2025-11-18
|
||||
|
||||
### Fixed
|
||||
|
||||
- **Bash Tool Error Handling**: Bash tool now properly throws errors for failed commands (non-zero exit codes), timeouts, and aborted executions. This ensures tool execution components display with red background when bash commands fail.
|
||||
- **Thinking Traces Styling**: Thinking traces now maintain gray italic styling throughout, even when containing inline code blocks, bold text, or other inline formatting
|
||||
|
||||
## [0.7.17] - 2025-11-18
|
||||
|
||||
### Added
|
||||
|
|
|
|||
|
|
@ -1,6 +1,6 @@
|
|||
{
|
||||
"name": "@mariozechner/pi-coding-agent",
|
||||
"version": "0.7.17",
|
||||
"version": "0.7.18",
|
||||
"description": "Coding agent CLI with read, bash, edit, write tools and session management",
|
||||
"type": "module",
|
||||
"bin": {
|
||||
|
|
@ -21,8 +21,8 @@
|
|||
"prepublishOnly": "npm run clean && npm run build"
|
||||
},
|
||||
"dependencies": {
|
||||
"@mariozechner/pi-agent": "^0.7.17",
|
||||
"@mariozechner/pi-ai": "^0.7.17",
|
||||
"@mariozechner/pi-agent": "^0.7.18",
|
||||
"@mariozechner/pi-ai": "^0.7.18",
|
||||
"chalk": "^5.5.0",
|
||||
"diff": "^8.0.2",
|
||||
"glob": "^11.0.3"
|
||||
|
|
|
|||
|
|
@ -137,7 +137,7 @@ export const bashTool: AgentTool<typeof bashSchema> = {
|
|||
}
|
||||
if (output) output += "\n\n";
|
||||
output += "Command aborted";
|
||||
resolve({ content: [{ type: "text", text: `Command failed\n\n${output}` }], details: undefined });
|
||||
_reject(new Error(output));
|
||||
return;
|
||||
}
|
||||
|
||||
|
|
@ -150,7 +150,7 @@ export const bashTool: AgentTool<typeof bashSchema> = {
|
|||
}
|
||||
if (output) output += "\n\n";
|
||||
output += `Command timed out after ${timeout} seconds`;
|
||||
resolve({ content: [{ type: "text", text: `Command failed\n\n${output}` }], details: undefined });
|
||||
_reject(new Error(output));
|
||||
return;
|
||||
}
|
||||
|
||||
|
|
@ -163,10 +163,7 @@ export const bashTool: AgentTool<typeof bashSchema> = {
|
|||
|
||||
if (code !== 0 && code !== null) {
|
||||
if (output) output += "\n\n";
|
||||
resolve({
|
||||
content: [{ type: "text", text: `Command failed\n\n${output}Command exited with code ${code}` }],
|
||||
details: undefined,
|
||||
});
|
||||
_reject(new Error(`${output}Command exited with code ${code}`));
|
||||
} else {
|
||||
resolve({ content: [{ type: "text", text: output || "(no output)" }], details: undefined });
|
||||
}
|
||||
|
|
|
|||
|
|
@ -38,12 +38,16 @@ export class AssistantMessageComponent extends Container {
|
|||
if (content.type === "text" && content.text.trim()) {
|
||||
// Assistant text messages with no background - trim the text
|
||||
// Set paddingY=0 to avoid extra spacing before tool executions
|
||||
this.contentContainer.addChild(new Markdown(content.text.trim(), undefined, undefined, undefined, 1, 0));
|
||||
this.contentContainer.addChild(new Markdown(content.text.trim(), 1, 0));
|
||||
} else if (content.type === "thinking" && content.thinking.trim()) {
|
||||
// Thinking traces in dark gray italic
|
||||
// Use Markdown component because it preserves ANSI codes across wrapped lines
|
||||
const thinkingText = chalk.gray.italic(content.thinking);
|
||||
this.contentContainer.addChild(new Markdown(thinkingText, undefined, undefined, undefined, 1, 0));
|
||||
// Use Markdown component with default text style for consistent styling
|
||||
this.contentContainer.addChild(
|
||||
new Markdown(content.thinking.trim(), 1, 0, {
|
||||
color: "gray",
|
||||
italic: true,
|
||||
}),
|
||||
);
|
||||
this.contentContainer.addChild(new Spacer(1));
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -186,7 +186,7 @@ export class TuiRenderer {
|
|||
this.ui.addChild(new DynamicBorder(chalk.cyan));
|
||||
this.ui.addChild(new Text(chalk.bold.cyan("What's New"), 1, 0));
|
||||
this.ui.addChild(new Spacer(1));
|
||||
this.ui.addChild(new Markdown(this.changelogMarkdown.trim(), undefined, undefined, undefined, 1, 0));
|
||||
this.ui.addChild(new Markdown(this.changelogMarkdown.trim(), 1, 0));
|
||||
this.ui.addChild(new Spacer(1));
|
||||
this.ui.addChild(new DynamicBorder(chalk.cyan));
|
||||
}
|
||||
|
|
@ -989,7 +989,7 @@ export class TuiRenderer {
|
|||
this.chatContainer.addChild(new DynamicBorder(chalk.cyan));
|
||||
this.ui.addChild(new Text(chalk.bold.cyan("What's New"), 1, 0));
|
||||
this.ui.addChild(new Spacer(1));
|
||||
this.chatContainer.addChild(new Markdown(changelogMarkdown));
|
||||
this.chatContainer.addChild(new Markdown(changelogMarkdown, 1, 1));
|
||||
this.chatContainer.addChild(new DynamicBorder(chalk.cyan));
|
||||
this.ui.requestRender();
|
||||
}
|
||||
|
|
|
|||
|
|
@ -15,7 +15,7 @@ export class UserMessageComponent extends Container {
|
|||
}
|
||||
|
||||
// User messages with dark gray background
|
||||
this.markdown = new Markdown(text, undefined, undefined, { r: 52, g: 53, b: 65 });
|
||||
this.markdown = new Markdown(text, 1, 1, { bgColor: "#343541" });
|
||||
this.addChild(this.markdown);
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue