Self Checks
Dify version
1.10.1
Cloud or Self Hosted
Self Hosted (Docker)
Steps to reproduce
Bug Description
Legacy workflow data containing Variable Assigner nodes in V1 format fails to execute the assignment operation silently. The node execution reports success, but no actual variable assignment occurs.
The root cause is that DifyNodeFactory.create_node() always uses LATEST_VERSION to instantiate node classes, ignoring the version field in node data. When V1 format data (without version and items fields) is processed by VariableAssignerNodeV2, the items field defaults to an empty list, causing the _run() method's for-loop to skip all operations.
Steps to Reproduce
- Import or use a legacy workflow that was created before the Variable Assigner V2 upgrade
- The legacy Variable Assigner node data contains:
{
"data": {
"assigned_variable_selector": ["conversation", "query"],
"input_variable_selector": ["sys", "query"],
"write_mode": "append",
"type": "assigner"
// Missing: "version": "2" and "items": [...]
}
}
- Run the workflow with a conversation variable list append operation
- The Variable Assigner node completes without error, but the list variable is not updated
Example
Use the following example:
Variable Assigner Test.yml
The normal operating result is as follows:
✔️ Expected Behavior
Expected Behavior
❌ Actual Behavior
Actual Behavior
- The node execution returns
WorkflowNodeExecutionStatus.SUCCEEDED
- No variable assignment actually occurs
- No error message is displayed to the user
- Re-editing the node in the UI "fixes" the issue by saving in V2 format
Self Checks
Dify version
1.10.1
Cloud or Self Hosted
Self Hosted (Docker)
Steps to reproduce
Bug Description
Legacy workflow data containing Variable Assigner nodes in V1 format fails to execute the assignment operation silently. The node execution reports success, but no actual variable assignment occurs.
The root cause is that
DifyNodeFactory.create_node()always usesLATEST_VERSIONto instantiate node classes, ignoring theversionfield in node data. When V1 format data (withoutversionanditemsfields) is processed byVariableAssignerNodeV2, theitemsfield defaults to an empty list, causing the_run()method's for-loop to skip all operations.Steps to Reproduce
{ "data": { "assigned_variable_selector": ["conversation", "query"], "input_variable_selector": ["sys", "query"], "write_mode": "append", "type": "assigner" // Missing: "version": "2" and "items": [...] } }Example
Use the following example:
Variable Assigner Test.yml
The normal operating result is as follows:
✔️ Expected Behavior
Expected Behavior
The system should either:
VariableAssignerNodeV1class based on missingversionfield (backward compatibility), ORVariableAssignerNodeV2should auto-migrate V1 data format by convertingassigned_variable_selector,input_variable_selector, andwrite_modeto equivalentitemsarrayThe variable assignment should execute correctly regardless of data format version
❌ Actual Behavior
Actual Behavior
WorkflowNodeExecutionStatus.SUCCEEDED