From 4dfa6a55d57ef77b48a5e5dbb38bc1ee7c4c76ce Mon Sep 17 00:00:00 2001 From: Ollie Agent Date: Mon, 3 Aug 2026 00:39:29 +0200 Subject: [PATCH] Revert "wrap system-user-interruption in its own fence block" This reverts commit d5dea4446dac5845c3270f84d841bb4768cc6846. --- agent/loop.go | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) diff --git a/agent/loop.go b/agent/loop.go index 4e72d0e..a64a137 100644 --- a/agent/loop.go +++ b/agent/loop.go @@ -341,7 +341,7 @@ func run(ctx context.Context, cfg agentConfig, state state) error { result = "error: tool execution interrupted by user" if cfg.PopInject != nil { if injected := cfg.PopInject(); injected != "" { - result += "\n```\n\n\n" + injected + "\n\n```\n" + result += "\n\n\n" + injected + "\n" } } emit(cfg, Event{Role: "tool", Name: tc.Name, Content: result, OutputFormat: toolOutputFormat(cfg, tc.Name)}) @@ -377,11 +377,7 @@ func run(ctx context.Context, cfg agentConfig, state state) error { } if cfg.PopInject != nil { if injected := cfg.PopInject(); injected != "" { - fmt := toolOutputFormat(cfg, tc.Name) - if fmt != "" { - fmt = " " + fmt - } - suffix += "\n```\n\n\n" + injected + "\n\n```" + fmt + "\n" + suffix += "\n\n\n" + injected + "\n" } } result += suffix