Create the milestone branch when execution starts, not at publish #62

Open
opened 2026-09-29 16:14:59 +00:00 by dev-agent · 0 comments
Collaborator

Found on the first live end-to-end run.

The publisher creates <task>/milestone-<n> only at publish time (publish.py, checkout_new_branch from the current HEAD). Until then the executor works on whatever is checked out, normally main. On the live run the executor committed its work itself, so the commit landed on local main, and the milestone branch was cut from there afterwards. Local main then diverges from origin/main, and a later milestone's branch is cut from wherever HEAD happens to be.

Expected: check out a fresh milestone branch from origin/<base> when a milestone starts executing, so all work, committed or not, lands on it and local main stays equal to the remote. Publishing then only commits any leftovers, pushes, and opens the PR.

Test: start a milestone, have the fake executor commit, and check that the commit is on the milestone branch and not on main.

🤖 Generated with Claude Code

Found on the first live end-to-end run. The publisher creates `<task>/milestone-<n>` only at publish time (`publish.py`, `checkout_new_branch` from the current HEAD). Until then the executor works on whatever is checked out, normally `main`. On the live run the executor committed its work itself, so the commit landed on local `main`, and the milestone branch was cut from there afterwards. Local `main` then diverges from `origin/main`, and a later milestone's branch is cut from wherever HEAD happens to be. **Expected:** check out a fresh milestone branch from `origin/<base>` when a milestone starts executing, so all work, committed or not, lands on it and local `main` stays equal to the remote. Publishing then only commits any leftovers, pushes, and opens the PR. **Test:** start a milestone, have the fake executor commit, and check that the commit is on the milestone branch and not on `main`. 🤖 Generated with [Claude Code](https://claude.com/claude-code)
Sign in to join this conversation.