multica-ai/multica · error
unarchive property: %w
Error message
unarchive property: %w
What it means
Returned by `multica property unarchive` when the PATCH sending `{"archived": false}` to `/api/properties/<id>` fails. Same code path as archive (shared closure `makePropertyArchiveRun`), with the unarchive wording selected when `archive` is false.
Source
Thrown at server/cmd/multica/cmd_property.go:417
return err
}
ctx, cancel := cli.APIContext(context.Background())
defer cancel()
properties, err := fetchProperties(ctx, client)
if err != nil {
return err
}
property, err := resolvePropertyRef(properties, args[0])
if err != nil {
return err
}
var updated propertyDTO
if err := client.PatchJSON(ctx, "/api/properties/"+property.ID, map[string]any{"archived": archive}, &updated); err != nil {
if archive {
return fmt.Errorf("archive property: %w", err)
}
return fmt.Errorf("unarchive property: %w", err)
}
output, _ := cmd.Flags().GetString("output")
if output == "json" {
return cli.PrintJSON(os.Stdout, updated)
}
if archive {
fmt.Fprintf(os.Stdout, "Property %q archived.\n", updated.Name)
} else {
fmt.Fprintf(os.Stdout, "Property %q restored.\n", updated.Name)
}
return nil
}
}
// ---------------------------------------------------------------------------
// issue property {list|set|unset}
// ---------------------------------------------------------------------------
View on GitHub (pinned to 2c0912b6ec)
Solutions
- Check the wrapped message: 404 means the property no longer exists (re-fetch with `multica property list --archived`); 401 → re-login.
- Verify the property ref is correct and still archived.
- Fix connectivity and retry if it is a network error.
Example fix
// before multica property unarchive "Priority" // error: unarchive property: request failed: 404 not found // after multica property list --archived # find the current ref/id multica property unarchive <correct-ref>
Defensive patterns
Strategy: try-catch
Validate before calling
# bash: check the archived listing first multica property list --archived 2>/dev/null | grep -qw "$PROP" || echo "$PROP not in archived list"
Try / catch
if err := client.PatchJSON(ctx, path, map[string]any{"archived": false}, &updated); err != nil {
if isNotFound(err) { /* refetch archived list, use current ID */ }
return fmt.Errorf("unarchive property: %w", err)
} Prevention
- Archive/unarchive by stable ID rather than name when scripting.
- Expect 404s if the property may have been deleted server-side.
When it happens
Trigger: Restoring an archived property while the server rejects the request (permissions, validation), the token is invalid, or the API is unreachable.
Common situations: Restoring properties in scripts after server migration; the property was deleted server-side in the meantime (404); stale auth.
Related errors
AI-assisted analysis of multica-ai/multica@2c0912b6ec (2026-08-15).
Data as JSON: /api/errors/c826fb69b3b84699.
Report an issue: GitHub.