{"record":{"id":"53db1f9661f253ba","repo":"multica-ai/multica","slug":"unresolve-comment-w","errorCode":null,"errorMessage":"unresolve comment: %w","messagePattern":"unresolve comment: %w","errorType":"console","errorClass":null,"httpStatus":null,"severity":"error","filePath":"server/cmd/multica/cmd_issue.go","lineNumber":2070,"sourceCode":"func runIssueCommentResolution(cmd *cobra.Command, commentID string, resolve bool) error {\n\tclient, err := newAPIClient(cmd)\n\tif err != nil {\n\t\treturn err\n\t}\n\n\tctx, cancel := cli.APIContext(context.Background())\n\tdefer cancel()\n\n\tpath := \"/api/comments/\" + url.PathEscape(commentID) + \"/resolve\"\n\tvar result map[string]any\n\tif resolve {\n\t\tif err := client.PostJSON(ctx, path, nil, &result); err != nil {\n\t\t\treturn fmt.Errorf(\"resolve comment: %w\", err)\n\t\t}\n\t\tfmt.Fprintf(os.Stderr, \"Comment %s resolved.\\n\", commentID)\n\t} else {\n\t\tif err := client.DeleteJSONResponse(ctx, path, &result); err != nil {\n\t\t\treturn fmt.Errorf(\"unresolve comment: %w\", err)\n\t\t}\n\t\tfmt.Fprintf(os.Stderr, \"Comment %s unresolved.\\n\", commentID)\n\t}\n\n\toutput, _ := cmd.Flags().GetString(\"output\")\n\tif output == \"table\" {\n\t\treturn nil\n\t}\n\treturn cli.PrintJSON(os.Stdout, result)\n}\n\n// ---------------------------------------------------------------------------\n// Execution history commands\n// ---------------------------------------------------------------------------\n\nfunc runIssueRuns(cmd *cobra.Command, args []string) error {\n\tclient, err := newAPIClient(cmd)\n\tif err != nil {","sourceCodeStart":2052,"sourceCodeEnd":2088,"githubUrl":"https://github.com/multica-ai/multica/blob/2c0912b6ec764b373d44eeea1e80f0d9f11ab417/server/cmd/multica/cmd_issue.go#L2052-L2088","documentation":"`multica issue comment unresolve <comment-id>` sends DELETE to /api/comments/{id}/resolve. This error wraps that call failing: unknown comment, comment not currently resolved, permission denied, or network/server errors.","triggerScenarios":"Unresolving a comment that is not resolved; mistyped ID; missing rights; API unreachable. The comment ID is URL-escaped into the path, so odd characters are safe but wrong IDs still 404.","commonSituations":"Batch scripts unresolving already-unresolved comments; copied IDs from a different workspace.","solutions":["Confirm the comment is currently resolved via `multica issue comment list`.","Treat 'not resolved' outcomes as idempotent success in automation.","Fix auth/permissions for 401/403; retry transient failures."],"exampleFix":null,"handlingStrategy":"try-catch","validationCode":"# bash: only unresolve comments that are resolved\nstate=$(multica issue comment list \"$ISSUE\" --output json | jq -r --arg c \"$CID\" '.[] | select(.id == $c) | .resolved')\n[[ \"$state\" == \"true\" ]] || { echo \"comment $CID is not resolved\" >&2; exit 2; }","typeGuard":null,"tryCatchPattern":"# bash: idempotent unresolve\nmultica issue comment unresolve \"$CID\" 2>/tmp/err || {\n  grep -qE '404|not (resolved|found)' /tmp/err && exit 0\n  cat /tmp/err >&2; exit 1;\n}","preventionTips":["Sync resolved state before unresolve batches.","Treat state-mismatch failures as no-ops in automation."],"tags":["cli","http","api-client","comments","unresolve"],"backgroundTag":null,"analyzedSha":"2c0912b6ec764b373d44eeea1e80f0d9f11ab417","analyzedAt":"2026-08-15T13:25:18.241Z","schemaVersion":2},"datasetVersion":"2026-08-15T22:17:37.221Z"}