From 841c42e4688ee4af8a3bf180971d856167fda11c Mon Sep 17 00:00:00 2001 From: olaservo Date: Wed, 18 Feb 2026 21:06:44 -0700 Subject: [PATCH] Remove misleading structured content compatibility warning The MCP spec allows `content` to be a human-readable summary rather than a JSON-stringified copy of `structuredContent`. Remove the yellow warning that was shown when no text block JSON-matched structuredContent, keeping only the positive blue indicator when a match does exist. Fixes #1089 Co-Authored-By: Claude Opus 4.6 --- client/src/components/ToolResults.tsx | 27 +++++++-------------------- 1 file changed, 7 insertions(+), 20 deletions(-) diff --git a/client/src/components/ToolResults.tsx b/client/src/components/ToolResults.tsx index 38d1d0382..d036298b9 100644 --- a/client/src/components/ToolResults.tsx +++ b/client/src/components/ToolResults.tsx @@ -22,17 +22,14 @@ const checkContentCompatibility = ( text?: string; [key: string]: unknown; }>, -): { isCompatible: boolean; message: string } => { +): { hasMatch: boolean; message: string } | null => { // Look for at least one text content block that matches the structured content const textBlocks = unstructuredContent.filter( (block) => block.type === "text", ); if (textBlocks.length === 0) { - return { - isCompatible: false, - message: "No text blocks to match structured content", - }; + return null; } // Check if any text block contains JSON that matches the structured content @@ -49,7 +46,7 @@ const checkContentCompatibility = ( if (isEqual) { return { - isCompatible: true, + hasMatch: true, message: `Structured content matches text block${textBlocks.length > 1 ? " (multiple blocks)" : ""}${unstructuredContent.length > textBlocks.length ? " + other content" : ""}`, }; } @@ -59,10 +56,7 @@ const checkContentCompatibility = ( } } - return { - isCompatible: false, - message: "No text block matches structured content", - }; + return null; }; const ToolResults = ({ @@ -195,16 +189,9 @@ const ToolResults = ({
Unstructured Content:
- {compatibilityResult && ( -
- {compatibilityResult.isCompatible ? "✓" : "⚠"}{" "} - {compatibilityResult.message} + {compatibilityResult?.hasMatch && ( +
+ ✓ {compatibilityResult.message}
)}