Wire Run orchestrator for sequential Ticket Iterations#23
Merged
Conversation
Add run.Orchestrator to drive the Run loop over the ticket, agent, and gitops ports. An empty Ready for Agent queue reports and exits without touching the branch; otherwise the branch is prepared and Tickets are processed one Iteration each (Claim, Implement Phase, Review Phase, Done) up to the max-iterations limit, stopping when the queue drains or the limit is hit. The Implement Phase must produce commit(s) since a recorded restore point (new gitops HasCommitsSince); the Review Phase may be commitless. A failed Phase or missing side effect stops the Run. The Final Phase is a clean stop-point stub, wired in a later Ticket. Wire the orchestrator into cmd/ship, replacing the standalone branch preparation. Cover the loop with fake ticket and agent ports over a temp git repo.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
run.Orchestratorthat drives the Run loop: empty Ready for Agent queue exits cleanly with no branch work; otherwise prepare the Run branch and process Tickets one Iteration each (Claim → Implement → Review → Done) up to max iterations.gitops.HasCommitsSince); Review may be commitless; Final is a stop-point stub (full Final/PR and Abort polish are follow-up Tickets).cmd/shipand cover the highest test seam with fake Ticket + Agent ports over a temp git repo. Also includes the built-in phase prompts commits not yet onmain(prerequisite for the loop).Closes #10
Test plan
go test ./...Made with Cursor