You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
ifstrings.Contains(err.Error(), "config not valid") {
28
+
log.Info("It seems your config file is not valid. Please check the official documentation https://docs.devstream.io, or use the \"dtm show config\" command to get an example.")
returnnil, fmt.Errorf("failed to process variables in the tools section. Missing variable definition: %s", err.Error()[keyNotFoundIndex+len(missingVariableErrorMsg):])
73
+
}
67
74
returnnil, fmt.Errorf("failed to get tools from config file. Error: %w", err)
75
+
68
76
}
69
77
70
78
// 3. apps tools with global variables rendered
71
79
appTools, err:=r.getAppToolsWithVars(vars)
72
80
iferr!=nil {
81
+
keyNotFoundIndex:=strings.Index(err.Error(), "map has no entry for key ")
82
+
ifkeyNotFoundIndex!=-1 {
83
+
returnnil, fmt.Errorf("failed to process variables in the apps section. Missing variable definition: %s", err.Error()[keyNotFoundIndex+len(missingVariableErrorMsg):])
84
+
}
73
85
returnnil, fmt.Errorf("failed to get apps from config file. Error: %w", err)
74
86
}
75
87
// all tools from apps should depend on the original tools,
0 commit comments