-
Notifications
You must be signed in to change notification settings - Fork 487
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
flow: always allow running with a partially evaluated graph #4411
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -284,12 +284,14 @@ func (cn *ComponentNode) evaluate(scope *vm.Scope) error { | |
if cn.managed == nil { | ||
// We haven't built the managed component successfully yet. | ||
managed, err := cn.reg.Build(cn.managedOpts, argsCopyValue) | ||
if err != nil { | ||
return fmt.Errorf("building component: %w", err) | ||
} | ||
cn.managed = managed | ||
cn.args = argsCopyValue | ||
|
||
// We do the error check at the end to allow the component to still return | ||
// a component instance with an error to signal that it should still run. | ||
if err != nil { | ||
return fmt.Errorf("building component: %w", err) | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. what do you think about logging this error in addition to returning it? I am coming at this from the perspective of someone debugging the agent. We should provide as much telemetry data as possible for failed nodes. This is a small tradeoff for giving the extra flexibility in behavior (not stopping the agent on a single bad node) |
||
} | ||
return nil | ||
} | ||
|
||
|
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.
For me looks reasonable. But I'd like to hear the opinion of @spartan0x117 and @jcreixell before moving forward.