{"record":{"id":"e8f0029d664fb441","repo":"gastownhall/beads","slug":"project-update-reported-as-unsuccessful","errorCode":null,"errorMessage":"project update reported as unsuccessful","messagePattern":"project update reported as unsuccessful","errorType":"exception","errorClass":null,"httpStatus":null,"severity":"error","filePath":"internal/linear/client.go","lineNumber":1588,"sourceCode":"\t\tQuery: query,\n\t\tVariables: map[string]interface{}{\n\t\t\t\"id\":    projectID,\n\t\t\t\"input\": updates,\n\t\t},\n\t}\n\n\tdata, err := c.Execute(ctx, req)\n\tif err != nil {\n\t\treturn nil, fmt.Errorf(\"failed to update project: %w\", err)\n\t}\n\n\tvar updateResp ProjectUpdateResponse\n\tif err := json.Unmarshal(data, &updateResp); err != nil {\n\t\treturn nil, fmt.Errorf(\"failed to parse update project response: %w\", err)\n\t}\n\n\tif !updateResp.ProjectUpdate.Success {\n\t\treturn nil, fmt.Errorf(\"project update reported as unsuccessful\")\n\t}\n\n\treturn &updateResp.ProjectUpdate.Project, nil\n}\n","sourceCodeStart":1570,"sourceCodeEnd":1593,"githubUrl":"https://github.com/gastownhall/beads/blob/71377f276968b452ee607177637970a4ff888584/internal/linear/client.go#L1570-L1593","documentation":"UpdateProject returns this when Linear responded with a well-formed ProjectUpdateResponse whose projectUpdate.success flag is false. The mutation was executed and answered, but Linear reported the update itself did not succeed.","triggerScenarios":"Client.UpdateProject receives a response where updateResp.ProjectUpdate.Success is false — Linear accepted the request but reports the mutation failed (e.g. permission denied, no-op, entity-level validation).","commonSituations":"API token lacks write access to the project, project is in an archived/workspace-restricted state, another integration changed the project concurrently, Linear-side soft failures.","solutions":["Inspect the full GraphQL response for additional errors/messages accompanying success=false.","Verify the API token has write permission (admin or appropriate project scope) for the workspace.","Confirm the project is not archived or restricted in Linear.","Re-fetch the project and retry the update in case of a transient conflict.","Log updateResp to capture any 'lastSyncedAt' or error detail fields Linear returned."],"exampleFix":"// before\nif !updateResp.ProjectUpdate.Success {\n\treturn nil, fmt.Errorf(\"project update reported as unsuccessful\")\n}\n// after\nif !updateResp.ProjectUpdate.Success {\n\treturn nil, fmt.Errorf(\"project update reported as unsuccessful for project %s (id %s)\", project.Name, project.ID)\n}","handlingStrategy":"try-catch","validationCode":"// pre-check: fetch project and confirm token can see it\nproj, err := client.GetProject(ctx, id)\nif err != nil || proj == nil {\n\treturn fmt.Errorf(\"project %s not accessible with current token\", id)\n}","typeGuard":null,"tryCatchPattern":"if _, err := client.UpdateProject(ctx, id, updates); err != nil {\n\tif strings.Contains(err.Error(), \"reported as unsuccessful\") {\n\t\t// inspect full response / permissions, then surface actionable message\n\t\treturn fmt.Errorf(\"linear refused update to project %s: check token write scope\", id)\n\t}\n\treturn err\n}","preventionTips":["Grant the integration token write (not read-only) scope for the workspace.","Avoid updating archived or restricted projects.","Log the full GraphQL response, not just the success flag.","Handle concurrent-modification by re-fetching before retrying.","Monitor Linear workspace permission changes affecting the bot."],"tags":["linear","graphql","mutation","permissions"],"backgroundTag":"mutation-unsuccessful","analyzedSha":"71377f276968b452ee607177637970a4ff888584","analyzedAt":"2026-08-30T18:55:39.744Z","schemaVersion":2},"datasetVersion":"2026-08-30T23:17:21.991Z"}