Build AI methods with your coding agent, then run them anywhere: as an MCP for chatbots, as a webapp for people, or via API for your software.
Fix direction override for ReactFlow and duration=0 badge rendering
Louis Choquel718473efaa9c
diff --git a/pipelex/graph/graph_factory.py b/pipelex/graph/graph_factory.pyindex 27d4e87c0..d7e0eb0fd 100644--- a/pipelex/graph/graph_factory.py+++ b/pipelex/graph/graph_factory.py@@ -127,9 +127,12 @@ async def generate_graph_outputs(if graph_config.data_inclusion.stuff_html_content:rf_stuff_data_html = collect_stuff_data_html(graph_spec)+ effective_rf_config = graph_config.reactflow_config+ if direction is not None:+ effective_rf_config = effective_rf_config.model_copy(update={"layout_direction": direction})reactflow_html = await generate_reactflow_html_async(graph_spec,- graph_config.reactflow_config,+ effective_rf_config,stuff_data_text=rf_stuff_data_text,stuff_data_html=rf_stuff_data_html,title=page_title,diff --git a/pipelex/graph/reactflow/templates/_scripts.js.jinja2 b/pipelex/graph/reactflow/templates/_scripts.js.jinja2index cdfb7d92c..3376707ac 100644--- a/pipelex/graph/reactflow/templates/_scripts.js.jinja2+++ b/pipelex/graph/reactflow/templates/_scripts.js.jinja2@@ -547,7 +547,7 @@ function buildOrchestrationGraph(graphspec) {const isFailed = node.status === 'failed';const isSucceeded = node.status === 'succeeded';const label = node.pipe_code || node.node_id.split(':').pop() || node.node_id;- const badge = node.timing?.duration ? node.timing.duration.toFixed(1) + 's' : '';+ const badge = node.timing?.duration != null ? node.timing.duration.toFixed(1) + 's' : '';// Calculate width: ~8px per char (monospace 13px) + padding + status dotconst nodeWidth = Math.max(160, (label.length || 10) * 8 + 50);