From 2f22a435906ae65e9432b7e17e64a1ec9a153035 Mon Sep 17 00:00:00 2001 From: Matt Aitken Date: Tue, 4 Nov 2025 18:56:43 -0800 Subject: [PATCH 1/3] Fix for the MCP tool that gets logs for debugging runs This was broken when we changed the data on the backend that returns log/span data from runs. We changed the data structured and the internal API that the MCP client uses was failing to parse with the Zod schema --- .changeset/fuzzy-wolves-repeat.md | 5 +++++ packages/cli-v3/src/mcp/formatters.ts | 2 +- packages/core/src/v3/schemas/api.ts | 5 ++--- 3 files changed, 8 insertions(+), 4 deletions(-) create mode 100644 .changeset/fuzzy-wolves-repeat.md diff --git a/.changeset/fuzzy-wolves-repeat.md b/.changeset/fuzzy-wolves-repeat.md new file mode 100644 index 0000000000..e9133636a3 --- /dev/null +++ b/.changeset/fuzzy-wolves-repeat.md @@ -0,0 +1,5 @@ +--- +"trigger.dev": patch +--- + +Fix for the MCP tool that gets run logs to help debugging diff --git a/packages/cli-v3/src/mcp/formatters.ts b/packages/cli-v3/src/mcp/formatters.ts index a16f947a73..eee9ccf18f 100644 --- a/packages/cli-v3/src/mcp/formatters.ts +++ b/packages/cli-v3/src/mcp/formatters.ts @@ -238,7 +238,7 @@ function formatSpan( const duration = formatDuration(span.data.duration); const startTime = formatDateTime(span.data.startTime); - lines.push(`${indent}${prefix} ${span.message} ${statusIndicator}`); + lines.push(`${indent}${prefix} ${span.data.message} ${statusIndicator}`); lines.push(`${indent} Duration: ${duration}`); lines.push(`${indent} Started: ${startTime}`); diff --git a/packages/core/src/v3/schemas/api.ts b/packages/core/src/v3/schemas/api.ts index b018b2a4a8..b372ed5fa5 100644 --- a/packages/core/src/v3/schemas/api.ts +++ b/packages/core/src/v3/schemas/api.ts @@ -1267,9 +1267,9 @@ export type ApiBranchListResponseBody = z.infer Date: Fri, 7 Nov 2025 12:32:57 +0000 Subject: [PATCH 2/3] add changeset --- .changeset/hot-dryers-search.md | 6 ++++++ 1 file changed, 6 insertions(+) create mode 100644 .changeset/hot-dryers-search.md diff --git a/.changeset/hot-dryers-search.md b/.changeset/hot-dryers-search.md new file mode 100644 index 0000000000..97871a8919 --- /dev/null +++ b/.changeset/hot-dryers-search.md @@ -0,0 +1,6 @@ +--- +"trigger.dev": patch +"@trigger.dev/core": patch +--- + +Fix the MCP tool that gets logs for debugging runs From 1684b2399800d7c554677e01da1fdfb465b714a7 Mon Sep 17 00:00:00 2001 From: nicktrn <55853254+nicktrn@users.noreply.github.com> Date: Fri, 7 Nov 2025 12:33:46 +0000 Subject: [PATCH 3/3] Revert "add changeset" This reverts commit 86eca836d5907fa0d0f8ac595d4d5ebade140514. --- .changeset/hot-dryers-search.md | 6 ------ 1 file changed, 6 deletions(-) delete mode 100644 .changeset/hot-dryers-search.md diff --git a/.changeset/hot-dryers-search.md b/.changeset/hot-dryers-search.md deleted file mode 100644 index 97871a8919..0000000000 --- a/.changeset/hot-dryers-search.md +++ /dev/null @@ -1,6 +0,0 @@ ---- -"trigger.dev": patch -"@trigger.dev/core": patch ---- - -Fix the MCP tool that gets logs for debugging runs