From 8a7f92fd5d96012e5657514724cb8bca96bae2bd Mon Sep 17 00:00:00 2001 From: gastown/crew/mel Date: Wed, 18 Feb 2026 21:18:32 -0800 Subject: [PATCH] feat: add GetDependentsWithMetadata, GetIssuesByIDs, GetAllEventsSince to Storage interface Exposes 4 DoltStore methods on the Storage interface so SDK consumers (e.g. gastown daemon convoy manager) can use them without type-asserting to the concrete type. Also exports IssueWithDependencyMetadata type. Co-Authored-By: Claude Opus 4.6 --- beads.go | 7 ++++--- internal/storage/storage.go | 4 ++++ 2 files changed, 8 insertions(+), 3 deletions(-) diff --git a/beads.go b/beads.go index 5e42d1c74..bfd3e8e40 100644 --- a/beads.go +++ b/beads.go @@ -87,9 +87,10 @@ type ( WorkFilter = types.WorkFilter StaleFilter = types.StaleFilter DependencyCounts = types.DependencyCounts - IssueWithCounts = types.IssueWithCounts - SortPolicy = types.SortPolicy - EpicStatus = types.EpicStatus + IssueWithCounts = types.IssueWithCounts + IssueWithDependencyMetadata = types.IssueWithDependencyMetadata + SortPolicy = types.SortPolicy + EpicStatus = types.EpicStatus ) // Status constants diff --git a/internal/storage/storage.go b/internal/storage/storage.go index 30e937556..ae34141b0 100644 --- a/internal/storage/storage.go +++ b/internal/storage/storage.go @@ -26,6 +26,7 @@ type Storage interface { CreateIssues(ctx context.Context, issues []*types.Issue, actor string) error GetIssue(ctx context.Context, id string) (*types.Issue, error) GetIssueByExternalRef(ctx context.Context, externalRef string) (*types.Issue, error) + GetIssuesByIDs(ctx context.Context, ids []string) ([]*types.Issue, error) UpdateIssue(ctx context.Context, id string, updates map[string]interface{}, actor string) error CloseIssue(ctx context.Context, id string, reason string, actor string, session string) error DeleteIssue(ctx context.Context, id string) error @@ -36,6 +37,8 @@ type Storage interface { RemoveDependency(ctx context.Context, issueID, dependsOnID string, actor string) error GetDependencies(ctx context.Context, issueID string) ([]*types.Issue, error) GetDependents(ctx context.Context, issueID string) ([]*types.Issue, error) + GetDependenciesWithMetadata(ctx context.Context, issueID string) ([]*types.IssueWithDependencyMetadata, error) + GetDependentsWithMetadata(ctx context.Context, issueID string) ([]*types.IssueWithDependencyMetadata, error) GetDependencyTree(ctx context.Context, issueID string, maxDepth int, showAllPaths bool, reverse bool) ([]*types.TreeNode, error) // Labels @@ -53,6 +56,7 @@ type Storage interface { AddIssueComment(ctx context.Context, issueID, author, text string) (*types.Comment, error) GetIssueComments(ctx context.Context, issueID string) ([]*types.Comment, error) GetEvents(ctx context.Context, issueID string, limit int) ([]*types.Event, error) + GetAllEventsSince(ctx context.Context, sinceID int64) ([]*types.Event, error) // Statistics GetStatistics(ctx context.Context) (*types.Statistics, error)