From 26466630ce0bc5e13d4d7c7c2ad55e8b364efc7d Mon Sep 17 00:00:00 2001 From: Harshvardhan Date: Fri, 19 Jun 2026 02:30:02 +0530 Subject: [PATCH] fix: display exception message in trace output column when outputs is null MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit When a trace span contains an exception event but no outputs, the output column in the observability table showed an em dash (—). This fix checks for exception events and displays the exception message/type in red when outputs are absent. Fixes #4731 --- .../assets/getObservabilityColumns.tsx | 42 +++++++++++++------ 1 file changed, 30 insertions(+), 12 deletions(-) diff --git a/web/oss/src/components/pages/observability/assets/getObservabilityColumns.tsx b/web/oss/src/components/pages/observability/assets/getObservabilityColumns.tsx index ed0a53301d..24b18d95ce 100644 --- a/web/oss/src/components/pages/observability/assets/getObservabilityColumns.tsx +++ b/web/oss/src/components/pages/observability/assets/getObservabilityColumns.tsx @@ -121,18 +121,36 @@ export const getObservabilityColumns = ({evaluatorSlugs}: ObservabilityColumnsPr width: 400, maxWidth: 400, render: (_, record) => { - const outputs = getTraceOutputs(record) - const {data: sanitizedOutputs} = sanitizeDataWithBlobUrls(outputs) - return ( - - ) - }, + const outputs = getTraceOutputs(record) + const exception = record.events?.find((event) => event.name === "exception") + const {data: sanitizedOutputs} = sanitizeDataWithBlobUrls(outputs) + + if (!outputs && exception) { + const exceptionMessage = + (exception.attributes?.["exception.message"] as string) || + (exception.attributes?.["exception.type"] as string) || + "Exception" + return ( + + ) + } + + return ( + + ) +}, }, ...(evaluatorSlugs.length > 0 ? [