{"record":{"id":"892435357910d3da","repo":"gastownhall/beads","slug":"s-is-not-an-epic-or-molecule-type-s","errorCode":null,"errorMessage":"'%s' is not an epic or molecule (type: %s)","messagePattern":"'(.+?)' is not an epic or molecule \\(type: (.+?)\\)","errorType":"exception","errorClass":null,"httpStatus":null,"severity":"error","filePath":"cmd/bd/swarm_proxied_server.go","lineNumber":63,"sourceCode":"\t\tr := uowMolReader{uw: uw}\n\n\t\tepicID, err := utils.ResolvePartialID(ctx, r, args[0])\n\t\tif err != nil {\n\t\t\treturn nil, fmt.Errorf(\"epic '%s' not found: %v\", args[0], err)\n\t\t}\n\n\t\tepic, err := uw.IssueUseCase().GetIssue(ctx, epicID)\n\t\tif gateProxiedNotFound(err) || (err == nil && epic == nil) {\n\t\t\t// Classic reports a nil epic after a successful resolve this way;\n\t\t\t// keep the message for parity.\n\t\t\treturn nil, fmt.Errorf(\"epic '%s' not found\", epicID)\n\t\t}\n\t\tif err != nil {\n\t\t\treturn nil, fmt.Errorf(\"failed to get epic: %v\", err)\n\t\t}\n\n\t\tif epic.IssueType != types.TypeEpic && epic.IssueType != \"molecule\" {\n\t\t\treturn nil, fmt.Errorf(\"'%s' is not an epic or molecule (type: %s)\", epicID, epic.IssueType)\n\t\t}\n\n\t\tanalysis, err := analyzeEpicForSwarm(ctx, r, epic)\n\t\tif err != nil {\n\t\t\treturn nil, fmt.Errorf(\"failed to analyze epic: %v\", err)\n\t\t}\n\t\treturn analysis, nil\n\t})\n\tif err != nil {\n\t\treturn HandleErrorRespectJSON(\"%v\", err)\n\t}\n\n\tif !verbose {\n\t\tanalysis.Issues = nil\n\t}\n\n\tif jsonOutput {\n\t\tif jerr := outputJSON(analysis); jerr != nil {","sourceCodeStart":45,"sourceCodeEnd":81,"githubUrl":"https://github.com/gastownhall/beads/blob/71377f276968b452ee607177637970a4ff888584/cmd/bd/swarm_proxied_server.go#L45-L81","documentation":"Error from runSwarmValidateProxiedServer in cmd/bd/swarm_proxied_server.go:63. A guard that rejects arguments resolving to an issue whose IssueType is neither \"epic\" nor \"molecule\" — `bd swarm validate` only operates on swarm-capable parents. The actual type is reported in the message.","triggerScenarios":"`bd swarm validate <id>` where <id> resolves to a plain task, bug, feature, or chore issue rather than an epic or molecule.","commonSituations":"Passing a child/task ID instead of its parent epic; the issue's type was changed after creation (e.g. via `bd update --type`); confusing molecule membership with epic ownership.","solutions":["Identify the parent epic: `bd show <id>` and follow its parent-child dependency, or use `bd dep tree <id>`.","Re-run with the epic or molecule ID: `bd swarm validate <epic-id>`.","If the issue should be an epic, recreate or retype it (type changes may be restricted depending on existing dependencies).","For checking a single task's swarm status, use `bd swarm status <task-id>` instead."],"exampleFix":"// before\nbd swarm validate bd-1240   // bd-1240 is a task\n\n// after\nbd swarm validate bd-1230   // bd-1230 is the parent epic","handlingStrategy":"validation","validationCode":"type=$(bd show \"$ID\" --json | jq -r '.issue_type'); [ \"$type\" = epic ] || [ \"$type\" = molecule ] || echo \"$ID is $type, not an epic/molecule\"","typeGuard":"func isSwarmableType(issueType string) bool {\n    return issueType == \"epic\" || issueType == \"molecule\"\n}","tryCatchPattern":null,"preventionTips":["Resolve the parent epic before validating a child task","Check issue_type in bd show --json before scripting","Use bd swarm status for non-epic issues"],"tags":["go","cli","validation","user-input"],"backgroundTag":"wrong-issue-type","analyzedSha":"71377f276968b452ee607177637970a4ff888584","analyzedAt":"2026-08-30T18:55:39.744Z","schemaVersion":2},"datasetVersion":"2026-08-30T23:17:21.991Z"}