multica-ai/multica · error
no fields to update; use --name, --description, --content, o
Error message
no fields to update; use --name, --description, --content, or --config
What it means
Validation in `multica skill update <id>`: after collecting optional fields (--name, --description, --content, --config), the request body map is empty, meaning no field was actually provided. The CLI refuses to send an empty PUT because it would be a no-op at best and ambiguous at worst. Note that --content with empty bytes is rejected earlier by the empty-content check, so this specifically means no flags changed anything.
Source
Thrown at server/cmd/multica/cmd_skill.go:376
}
content, hasContent, err := resolveSkillContentFlag(cmd)
if err != nil {
return err
}
if hasContent {
body["content"] = content
}
if cmd.Flags().Changed("config") {
v, _ := cmd.Flags().GetString("config")
var config any
if err := json.Unmarshal([]byte(v), &config); err != nil {
return fmt.Errorf("--config must be valid JSON: %w", err)
}
body["config"] = config
}
if len(body) == 0 {
return fmt.Errorf("no fields to update; use --name, --description, --content, or --config")
}
ctx, cancel := cli.APIContext(context.Background())
defer cancel()
var result map[string]any
if err := client.PutJSON(ctx, "/api/skills/"+args[0], body, &result); err != nil {
return fmt.Errorf("update skill: %w", err)
}
output, _ := cmd.Flags().GetString("output")
if output == "json" {
return cli.PrintJSON(os.Stdout, result)
}
fmt.Printf("Skill updated: %s (%s)\n", strVal(result, "name"), strVal(result, "id"))
return nil
}View on GitHub (pinned to 2c0912b6ec)
Solutions
- Include at least one field flag: --name, --description, --content/--content-file/--content-stdin, or --config.
- In scripts, assert at least one update variable is set before invoking multica.
- Use `multica skill get <id>` first to see current values and decide what to change.
Example fix
# before multica skill update abc123 # after multica skill update abc123 --description 'New description'
Defensive patterns
Strategy: validation
Validate before calling
# Assert at least one update field is set before invoking
[ -n "$NAME$DESC$CONFIG" ] || [ -n "$CONTENT_FILE" ] || { echo "no fields to update"; exit 2; }
multica skill update "$SKILL_ID" ${NAME:+--name "$NAME"} ${DESC:+--description "$DESC"} ${CONFIG:+--config "$CONFIG"} ${CONTENT_FILE:+--content-file "$CONTENT_FILE"} Try / catch
Match 'no fields to update' and surface it as a usage bug in the caller (missing arguments), not a server problem; nothing was sent, so no rollback is needed.
Prevention
- Require at least one update field in script argument parsing.
- Use `multica skill get` to review current values before updating.
- Don't expect update to be interactive — it never opens an editor.
When it happens
Trigger: Running `multica skill update <id>` with no field flags at all, or with flags whose values are empty strings that the collection code skips.
Common situations: Scripts passing update flags conditionally where every condition evaluated false; interactive users expecting update to open an editor; copy-pasted create commands with the field flags removed.
Related errors
- --content, --content-stdin, and --content-file are mutually
- --name is required
- --%s, --%s-stdin, and --%s-file are mutually exclusive; pick
- --%s-file: path must not be empty
- --runtime-id must not be empty
AI-assisted analysis of multica-ai/multica@2c0912b6ec (2026-08-15).
Data as JSON: /api/errors/94a5fa0c23e7f143.
Report an issue: GitHub.