gastownhall/beads · error
failed to get swarm status: %v
Error message
failed to get swarm status: %v
What it means
Wrapper around getSwarmStatus failures once the epic has been resolved. Any error computing the swarm's aggregate status (dependent-issue queries, per-crew state reads) is wrapped here and then printed via HandleErrorRespectJSON.
Source
Thrown at cmd/bd/swarm_proxied_server.go:154
epic, err = uw.IssueUseCase().GetIssue(ctx, dep.DependsOnID)
if err != nil {
return nil, fmt.Errorf("failed to get linked epic: %v", err)
}
break
}
}
if epic == nil {
return nil, fmt.Errorf("swarm molecule '%s' has no linked epic", issueID)
}
} else if issue.IssueType == types.TypeEpic || issue.IssueType == "molecule" {
epic = issue
} else {
return nil, fmt.Errorf("'%s' is not an epic or swarm molecule (type: %s)", issueID, issue.IssueType)
}
status, err := getSwarmStatus(ctx, r, epic)
if err != nil {
return nil, fmt.Errorf("failed to get swarm status: %v", err)
}
return status, nil
})
if err != nil {
return HandleErrorRespectJSON("%v", err)
}
if jsonOutput {
return outputJSON(status)
}
renderSwarmStatus(status)
return nil
}
View on GitHub (pinned to 71377f2769)
Solutions
- Read the wrapped %v cause and fix the underlying storage error
- Retry after concurrent bd/dolt operations finish
- Run `bd doctor` to validate the local database
- Reduce fan-out by splitting an oversized epic into smaller swarms
Defensive patterns
Strategy: retry
Validate before calling
// ensure no conflicting bd/dolt process is running and DB is healthy bd doctor
Try / catch
status, err := getSwarmStatus(ctx, r, epic)
if err != nil {
if isTransientStorageErr(err) {
// back off and retry once the concurrent operation completes
}
return err
} Prevention
- Don't run `bd sync`/`bd dolt` concurrently with swarm commands on the same DB
- Run `bd doctor` if status queries start failing
- Split oversized epics to keep status queries bounded
When it happens
Trigger: getSwarmStatus(ctx, r, epic) fails because dependency/state queries for the epic's children error out — DB unavailability, context cancellation, or a corrupted dependency graph beneath a valid epic.
Common situations: Large epics whose child queries time out; embedded Dolt DB locked by a concurrent `bd dolt` operation; running the swarm command while a sync merge is mid-flight.
Related errors
- failed to get swarm dependencies: %v
- no store is open for this workspace
- not found
- db: ChildCounterSQLRepository.NextChildID: parentID must not
- db: DependencySQLRepository.Insert: dep must not be nil
AI-assisted analysis of gastownhall/beads@71377f2769 (2026-08-30).
Data as JSON: /api/errors/b62f2f35dc3c490b.
Report an issue: GitHub.