Repository navigation
Description
Summary
When a WayflowFlow has an InputMessageNode as its first gate (the bug described in #151), any data flow edges (DFEs) originating from StartNode are never populated. Downstream nodes — such as LlmNode or ApiCallNode — receive empty strings or None for all StartNode-sourced variables, even when the triggering message/send call carries those values in the task input.
Root cause
The pre-execute bug (#151) means StartNode is never processed against the trigger payload: the pre-execute runs the flow before the incoming message (which carries the StartNode inputs) is appended, so StartNode.output_data is empty when execute_async() first runs. Any DFE edges wired from StartNode → LlmNode.system_message or StartNode → ApiCallNode.body therefore receive empty values for the entire lifetime of the task — including after the user later resumes the task via subsequent message/send calls.
Steps to reproduce
- Create a
WayflowFlowwhere:StartNodehas one or moreinput_descriptors(e.g.run_id: str).- The first node after
StartNodeis anInputMessageNode. - A later
LlmNodeorApiCallNodehas a DFE wired fromStartNode.run_id.
- Send an initial
message/sendwith{"input": {"run_id": "abc123"}}. - Resume the task after the
InputMessageNodegate. - Observe: the
LlmNode/ApiCallNodereceives""orNoneforrun_idinstead of"abc123".
Expected behaviour
Values supplied in the initial message/send input should be bound to StartNode.output_data and propagated along DFE edges regardless of whether an InputMessageNode appears as the first gate.
Actual behaviour
StartNode.output_data is empty because the node processes its inputs during the pre-execute phase — before the trigger message is appended to the conversation. All DFE-sourced variables from StartNode arrive at downstream nodes as empty strings for the full duration of the task.
Impact
Any integration that relies on passing per-task metadata (e.g. correlation IDs, tenant IDs, run identifiers) through StartNode DFE edges into LlmNode or ApiCallNode is broken when an InputMessageNode is the first gate. The workaround is to inject the metadata through some other mechanism (e.g. system-message templating outside the flow, or a custom ContextVar propagation layer), which defeats the purpose of DFE wiring for these values.
Context
wayflowcore26.1.1- Reproduces on any
WayflowFlowwithInputMessageNodeas first gate - Root cause: A2AAgentWorker pre-executes flow before user's first message, causing InputMessageStep to consume trigger message as form data #151 — fixing A2AAgentWorker pre-executes flow before user's first message, causing InputMessageStep to consume trigger message as form data #151 should also resolve this
Suggested fix
Same as #151: guard the pre-execute so it does not run (or runs differently) when InputMessageNode is the first gate. When the pre-execute is skipped or corrected, StartNode will process its inputs from the trigger payload before any DFE evaluation occurs, and downstream nodes will receive the correct values.
Activity