Advance workflow stages from the state-driven coordinator

This commit is contained in:
Ian Gulliver
2026-10-21 13:11:03 -07:00
parent c77a5ba02b
commit be777e469c
6 changed files with 49 additions and 40 deletions
+5
View File
@@ -16,6 +16,7 @@ type Work struct {
StartStages []StageStart
SettleReviews []SnapshotRef
ReadyPrompts []ReadyPrompt
AdvanceStages []string
}
func (s *Store) Coordinate(ctx context.Context) (Work, error) {
@@ -69,6 +70,10 @@ func (s *Store) Coordinate(ctx context.Context) (Work, error) {
return err
}
work.ReadyPrompts, err = readyPrompts(ctx, tx, emit)
if err != nil {
return err
}
work.AdvanceStages, err = finishedStages(ctx, tx)
return err
})
return work, err