File tree Expand file tree Collapse file tree 1 file changed +7
-1
lines changed Expand file tree Collapse file tree 1 file changed +7
-1
lines changed Original file line number Diff line number Diff line change @@ -727,6 +727,12 @@ func (t *TaskHandler) CreateFromScope(req api.Context) error {
727
727
if thread .Spec .AgentName != "" {
728
728
additionalCredentialContexts = append (additionalCredentialContexts , thread .Spec .AgentName )
729
729
}
730
+
731
+ var agent v1.Agent
732
+ if err := req .Get (& agent , thread .Spec .AgentName ); err != nil {
733
+ return err
734
+ }
735
+
730
736
workflow := v1.Workflow {
731
737
ObjectMeta : metav1.ObjectMeta {
732
738
GenerateName : system .WorkflowPrefix ,
@@ -735,7 +741,7 @@ func (t *TaskHandler) CreateFromScope(req api.Context) error {
735
741
Spec : v1.WorkflowSpec {
736
742
ThreadName : thread .Name ,
737
743
Manifest : workflowManifest ,
738
- KnowledgeSetNames : thread .Status .KnowledgeSetNames ,
744
+ KnowledgeSetNames : append ( agent . Status . KnowledgeSetNames , thread .Status .KnowledgeSetNames ... ) ,
739
745
WorkspaceName : workspace .Name ,
740
746
CredentialContextID : thread .Name ,
741
747
AdditionalCredentialContexts : additionalCredentialContexts ,
You can’t perform that action at this time.
0 commit comments