multica-ai/multica · error
add agent skills: %w
Error message
add agent skills: %w
What it means
Error "add agent skills: %w" thrown in multica-ai/multica.
Source
Thrown at server/cmd/multica/cmd_agent.go:1067
}
if !cmd.Flags().Changed("skill-ids") {
return fmt.Errorf("--skill-ids is required (comma-separated skill IDs)")
}
cleanIDs := cleanSkillIDsFlag(cmd)
if len(cleanIDs) == 0 {
return fmt.Errorf("--skill-ids must include at least one skill ID")
}
body := map[string]any{
"skill_ids": cleanIDs,
}
ctx, cancel := cli.APIContext(context.Background())
defer cancel()
var result json.RawMessage
if err := client.PostJSON(ctx, "/api/agents/"+args[0]+"/skills/add", body, &result); err != nil {
return fmt.Errorf("add agent skills: %w", err)
}
return printAgentSkillsMutationResult(cmd, args[0], result)
}
func cleanSkillIDsFlag(cmd *cobra.Command) []string {
skillIDs, _ := cmd.Flags().GetStringSlice("skill-ids")
cleanIDs := make([]string, 0, len(skillIDs))
for _, id := range skillIDs {
id = strings.TrimSpace(id)
if id != "" {
cleanIDs = append(cleanIDs, id)
}
}
return cleanIDs
}
func printAgentSkillsMutationResult(cmd *cobra.Command, agentID string, result json.RawMessage) error {View on GitHub (pinned to 2c0912b6ec)
Solutions
- Check the server connectivity and response; inspect the error from the add agent skills call.
When it happens
Trigger: Thrown at server/cmd/multica/cmd_agent.go:1067 when the library encounters an invalid state.
Common situations: See trigger scenarios.
AI-assisted analysis of multica-ai/multica@2c0912b6ec (2026-08-15).
Data as JSON: /api/errors/1efa65ac30f8ab35.
Report an issue: GitHub.