@mastra/playground-ui 4.0.0-alpha.6 → 4.0.0-alpha.8
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.es.js +2 -2
- package/dist/index.es.js.map +1 -1
- package/package.json +3 -3
package/dist/index.es.js
CHANGED
|
@@ -4368,7 +4368,7 @@ const refineTraces = (traces, isWorkflow = false) => {
|
|
|
4368
4368
|
}
|
|
4369
4369
|
return name;
|
|
4370
4370
|
};
|
|
4371
|
-
const groupedTraces = traces
|
|
4371
|
+
const groupedTraces = traces?.reduce((acc, curr) => {
|
|
4372
4372
|
const newCurr = { ...curr, name: newName(curr.name), duration: curr.endTime - curr.startTime };
|
|
4373
4373
|
listOfSpanIds.add(curr.id);
|
|
4374
4374
|
return { ...acc, [curr.traceId]: [...acc[curr.traceId] || [], newCurr] };
|
|
@@ -4968,7 +4968,7 @@ const useTraces = (componentName, baseUrl, isWorkflow = false) => {
|
|
|
4968
4968
|
if (!res.traces) {
|
|
4969
4969
|
throw new Error("Error fetching traces");
|
|
4970
4970
|
}
|
|
4971
|
-
const refinedTraces = refineTraces(res?.traces || [], isWorkflow);
|
|
4971
|
+
const refinedTraces = refineTraces(res?.traces?.traces || [], isWorkflow);
|
|
4972
4972
|
return refinedTraces;
|
|
4973
4973
|
} catch (error2) {
|
|
4974
4974
|
throw error2;
|