- 
                Notifications
    
You must be signed in to change notification settings  - Fork 657
 
.NET: Make WorkflowBuilder more intuititve #503
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
.NET: Make WorkflowBuilder more intuititve #503
Conversation
Right now Executorish binding has some unintutitive behaviour. When a user adds an eecutor with an id of an executor that already exists, we silently replace it, if the user provides it inside of add_edge. When a user introduces an executor via an unbound id, the user must bind it via BindExecutor, even though the registration is created implicitly when an edge id added. The change will remove the invisible update in favor of a "best efforts" check of type and instance equality.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull Request Overview
This PR improves the WorkflowBuilder's executor binding behavior by replacing silent replacement with validation checks. Instead of automatically overwriting existing executors with the same ID, the system now validates that new bindings match existing ones by type and instance reference.
Key changes:
- Added validation to prevent binding executors with same ID but different types or instances
 - Enhanced ExecutorRegistration to track raw executor data for comparison
 - Added comprehensive test coverage for the new binding validation behavior
 
Reviewed Changes
Copilot reviewed 4 out of 4 changed files in this pull request and generated 1 comment.
| File | Description | 
|---|---|
| WorkflowBuilderSmokeTests.cs | Adds test cases covering late binding, implicit binding, and validation scenarios | 
| WorkflowBuilder.cs | Implements validation logic to check type and instance equality before binding | 
| ExecutorRegistration.cs | Adds RawExecutorishData property to store original executor data for comparison | 
| ExecutorIsh.cs | Adds RawData property and updates Registration to include raw data | 
Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
* feat: Make WorkflowBuilder more intutitve Right now Executorish binding has some unintutitive behaviour. When a user adds an eecutor with an id of an executor that already exists, we silently replace it, if the user provides it inside of add_edge. When a user introduces an executor via an unbound id, the user must bind it via BindExecutor, even though the registration is created implicitly when an edge id added. The change will remove the invisible update in favor of a "best efforts" check of type and instance equality. * Expand errors when rebinding to disallowed Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com> --------- Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Before this change, Executorish binding has some unintuitive behaviour. When a user adds an executor with an id of an executor that already exists, we silently replace it, if the user provides it inside of add_edge. When a user introduces an executor via an unbound id, the user must bind it via BindExecutor, even though the registration is created implicitly when an edge id added.
The change will remove the invisible update in favor of a "best efforts" check of type and instance equality.