{"record":{"id":"2dfd77b2ea724c2c","repo":"multica-ai/multica","slug":"resolve-issue-w","errorCode":null,"errorMessage":"resolve issue: %w","messagePattern":"resolve issue: %w","errorType":"console","errorClass":null,"httpStatus":null,"severity":"error","filePath":"server/cmd/multica/cmd_issue.go","lineNumber":755,"sourceCode":"\t\t}\n\t\trows = append(rows, row)\n\t}\n\tcli.PrintTable(os.Stdout, headers, rows)\n\treturn nil\n}\n\nfunc runIssuePullRequests(cmd *cobra.Command, args []string) 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\tissueRef, err := resolveIssueRef(ctx, client, args[0])\n\tif err != nil {\n\t\treturn fmt.Errorf(\"resolve issue: %w\", err)\n\t}\n\n\tvar result map[string]any\n\tif err := client.GetJSON(ctx, \"/api/issues/\"+url.PathEscape(issueRef.ID)+\"/pull-requests\", &result); err != nil {\n\t\treturn fmt.Errorf(\"list issue pull requests: %w\", err)\n\t}\n\n\toutput, _ := cmd.Flags().GetString(\"output\")\n\tif output == \"json\" {\n\t\treturn cli.PrintJSON(os.Stdout, result)\n\t}\n\n\tprs, _ := result[\"pull_requests\"].([]any)\n\tprintIssuePullRequestsTable(normalizePullRequestList(prs))\n\treturn nil\n}\n\nfunc normalizePullRequestList(raw []any) []map[string]any {","sourceCodeStart":737,"sourceCodeEnd":773,"githubUrl":"https://github.com/multica-ai/multica/blob/2c0912b6ec764b373d44eeea1e80f0d9f11ab417/server/cmd/multica/cmd_issue.go#L737-L773","documentation":"Before listing an issue's pull requests, the CLI must resolve args[0] (an issue reference — ID, key, or similar accepted form) to a concrete issue ID via resolveIssueRef. That resolution failed; the %w carries the reason (no match, ambiguous match, or a lookup API error). This is the same resolution step every issue subcommand performs.","triggerScenarios":"Running `multica issue pull-requests <ref>` where <ref> is a typo'd issue key, an ID that was deleted, a key that matches multiple issues, or when the resolution lookup itself hit a network/auth failure.","commonSituations":"Script reusing an issue key captured before the issue was renamed/moved/deleted; copy-paste truncating the key; parallel sessions where the issue was just deleted.","solutions":["Read the wrapped error — not-found vs ambiguous vs transport failure each have different fixes.","Confirm the issue exists with `multica issue list` (or `issue get <ref>`) and copy the exact key/ID.","If ambiguous, use the unambiguous numeric/canonical ID.","If transport-related, fix connectivity/auth first (same steps as any API error)."],"exampleFix":"# before\nmultica issue pull-requests MUL-9999   # deleted issue\n# after\nmultica issue list --limit 20          # find the live key\nmultica issue pull-requests MUL-4252","handlingStrategy":"validation","validationCode":"# confirm the ref resolves before the subcommand\nmultica issue get \"$REF\" --output json >/dev/null 2>&1 \\\n  || { echo \"issue ref does not resolve: $REF\" >&2; exit 1; }","typeGuard":null,"tryCatchPattern":null,"preventionTips":["Use canonical issue IDs in scripts; keys are human-facing and can collide/change.","Treat 'resolve issue' errors as fatal for that item but skip-and-log in batch traversal."],"tags":["cli","issue-ref","resolution","pull-requests"],"backgroundTag":null,"analyzedSha":"2c0912b6ec764b373d44eeea1e80f0d9f11ab417","analyzedAt":"2026-08-15T13:25:18.241Z","schemaVersion":2},"datasetVersion":"2026-08-15T22:17:37.221Z"}