Skip to content

armgit / dify

Public Imported from GitHub
0

Build Agentic workflows, RAG pipelines, with rich AI model and tool support on one collaborative workspace. Deploy on cloud, VPC, or self-hosted, so teams move from prototype to production without rebuilding the stack.

fix: some parallel logs missing (#16923)

Joel395fdc496053
diff --git a/web/app/components/workflow/run/utils/format-log/parallel/index.ts b/web/app/components/workflow/run/utils/format-log/parallel/index.ts
index 245337dc0c2..5375620343b 100644
--- a/web/app/components/workflow/run/utils/format-log/parallel/index.ts
+++ b/web/app/components/workflow/run/utils/format-log/parallel/index.ts
@@ -78,6 +78,7 @@ const format = (list: NodeTracing[], t: any, isPrint?: boolean): NodeTracing[] =
// list to tree by parent_parallel_start_node_id and branch by parallel_start_node_id. Each parallel may has more than one branch.
result.forEach((node) => {
const parallel_id = node.parallel_id ?? node.execution_metadata?.parallel_id ?? null
+ const parallel_start_node_id = node.parallel_start_node_id ?? node.execution_metadata?.parallel_start_node_id ?? null
const parent_parallel_id = node.parent_parallel_id ?? node.execution_metadata?.parent_parallel_id ?? null
const branchStartNodeId = node.parallel_start_node_id ?? node.execution_metadata?.parallel_start_node_id ?? null
const parentParallelBranchStartNodeId = node.parent_parallel_start_node_id ?? node.execution_metadata?.parent_parallel_start_node_id ?? null
@@ -85,7 +86,7 @@ const format = (list: NodeTracing[], t: any, isPrint?: boolean): NodeTracing[] =
if (isNotInParallel)
return
- const isParallelStartNode = !parallelFirstNodeMap[parallel_id]
+ const isParallelStartNode = parallel_start_node_id === node.node_id // in the same parallel has more than one start node
if (isParallelStartNode) {
const selfNode = { ...node, parallelDetail: undefined }
node.parallelDetail = {