From 1e3afd73989432a7604cb7bd618ad38bb759e311 Mon Sep 17 00:00:00 2001 From: Aiden Cline Date: Mon, 31 Aug 2026 16:29:37 -0500 Subject: [PATCH] fix(core): use patch tool name in duplicate errors --- packages/core/src/tool/plugin/patch.ts | 2 +- packages/core/test/tool-patch.test.ts | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/packages/core/src/tool/plugin/patch.ts b/packages/core/src/tool/plugin/patch.ts index a9b2e47dcc3..c3a5f5f3696 100644 --- a/packages/core/src/tool/plugin/patch.ts +++ b/packages/core/src/tool/plugin/patch.ts @@ -132,7 +132,7 @@ export const Plugin = { const target = yield* resolveTarget(hunk.path) if (prepared.some((change) => change.target.absolute === target.absolute)) { return yield* new ToolFailure({ - message: `apply_patch verification failed: invalid patch: multiple operations target ${target.absolute}`, + message: `patch verification failed: invalid patch: multiple operations target ${target.absolute}`, }) } if (hunk.type === "add") { diff --git a/packages/core/test/tool-patch.test.ts b/packages/core/test/tool-patch.test.ts index 45bfad41c86..b7a74111936 100644 --- a/packages/core/test/tool-patch.test.ts +++ b/packages/core/test/tool-patch.test.ts @@ -347,7 +347,7 @@ describe("PatchTool", () => { status: "error", error: { type: "tool.execution", - message: `apply_patch verification failed: invalid patch: multiple operations target ${target}`, + message: `patch verification failed: invalid patch: multiple operations target ${target}`, }, }) expect(yield* Effect.promise(() => fs.readFile(target, "utf8"))).toBe("before\n")