{"record":{"id":"63f03cad1fe98907","repo":"multica-ai/multica","slug":"resolve-project-resource-w","errorCode":null,"errorMessage":"resolve project resource: %w","messagePattern":"resolve project resource: %w","errorType":"console","errorClass":null,"httpStatus":null,"severity":"error","filePath":"server/cmd/multica/cmd_project.go","lineNumber":672,"sourceCode":"\treturn cli.PrintJSON(os.Stdout, result)\n}\n\nfunc runProjectResourceUpdate(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\tprojectRef, err := resolveProjectID(ctx, client, args[0])\n\tif err != nil {\n\t\treturn fmt.Errorf(\"resolve project: %w\", err)\n\t}\n\tresourceRef, err := resolveProjectResourceID(ctx, client, projectRef.ID, args[1])\n\tif err != nil {\n\t\treturn fmt.Errorf(\"resolve project resource: %w\", err)\n\t}\n\n\t// Fetch the existing row so per-type shortcuts know which schema to\n\t// emit and which fields to preserve. The server treats resource_ref as\n\t// opaque-replace, so a partial edit like `--default-branch-hint` has to\n\t// rebuild the full payload here — otherwise the unmentioned `url` would\n\t// vanish and the server would 400.\n\tvar existing map[string]any\n\tif err := client.GetJSON(ctx, \"/api/projects/\"+projectRef.ID+\"/resources\", &existing); err != nil {\n\t\treturn fmt.Errorf(\"list project resources: %w\", err)\n\t}\n\tvar resourceType string\n\tvar existingRef map[string]any\n\tif list, ok := existing[\"resources\"].([]any); ok {\n\t\tfor _, raw := range list {\n\t\t\trow, ok := raw.(map[string]any)\n\t\t\tif !ok {\n\t\t\t\tcontinue","sourceCodeStart":654,"sourceCodeEnd":690,"githubUrl":"https://github.com/multica-ai/multica/blob/2c0912b6ec764b373d44eeea1e80f0d9f11ab417/server/cmd/multica/cmd_project.go#L654-L690","documentation":"Error \"resolve project resource: %w\" thrown in multica-ai/multica.","triggerScenarios":"Thrown at server/cmd/multica/cmd_project.go:672 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":["Verify the project resource ID exists."],"exampleFix":null,"handlingStrategy":null,"validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"2c0912b6ec764b373d44eeea1e80f0d9f11ab417","analyzedAt":"2026-08-15T13:25:18.241Z","schemaVersion":2},"datasetVersion":"2026-08-15T17:31:12.345Z"}