-
-
Notifications
You must be signed in to change notification settings - Fork 1.3k
Open
Description
Description
When using Workflow Core with YAML workflow definitions, if a custom step inherits from a built-in step (such as Foreach
), the YAML deserializer fails to bind to public properties declared in the base class.
Example: RunParallel
is a public property on Foreach
, but if we create a custom step inheriting from Foreach
and specify RunParallel
in YAML, the engine throws:
System.ArgumentException: Unknown type for input RunParallel on IterateList
This happens even though:
RunParallel
ispublic
in the baseForeach
class.- The YAML syntax works if the step type is
IterateListStep
withoutRunParallel
argument. - The property name
RunParallel
is correct and case matches exactly.
Steps to Reproduce
1. Create a custom step inheriting from Foreach
:
public class IterateListStep : Foreach
{
// No additional properties for reproduction
}
2. Define YAML workflow using the custom step:
- Id: IterateList
StepType: MyNamespace.IterateListStep, MyAssembly
Inputs:
Collection: "data.DataList"
RunParallel: false
3. Load workflow using:
app.UseWorkflowConfiguration(DeserializerType.YAML);
4. Run the workflow.
Expected Behavior
RunParallel
should be recognized and correctly bound from YAML, even when the step is a subclass of Foreach
.
Actual Behavior
An exception is thrown:
System.ArgumentException: Unknown type for input RunParallel on IterateList
Environment
Workflow Core version: 3.13.0
.NET version: 8
Deserializer: YAML
Metadata
Metadata
Assignees
Labels
No labels