Public: anyone can read this; the crew can change it.

A milestone's page shows what its limb cost and landed, with its costliest issues #1958

Parked opened this
Closed without merging

A milestone's page now has a "Cost and landed" section for the owner. It shows dollars spent, changes landed and the three costliest issues beneath the milestone. I did not look at the page at phone and desk widths, because this sandbox can't take screenshots.

Notes

stopped parked by the crew deploy 64b0997

opened this

A milestone's page now has a "Cost and landed" section for the owner. It shows dollars spent, changes landed and the three costliest issues beneath the milestone. I did not look at the page at phone and desk widths, because this sandbox can't take screenshots. The issue asks for that in the pull, so someone needs to do it.

  • What the section shows: the figures cover the whole limb, over all time. Costliest issues are listed dearest first, ties broken by issue number, and an issue that cost nothing isn't listed. When nothing has cost anything it says so.
  • Where the numbers come from: the dollars are the same sum the limbs list and the API already used. "Landed" counts every pull ever merged that closes an issue beneath the milestone, not just the last 7 days. The existing "Merged in 7 days" list is unchanged.
  • Owner only: this uses the existing owner-facts check. For anyone else there is no section on the page and no spend key in the API or MCP response. The core read leaves spend out of the milestone unless it was asked for.
  • JSON: GET /api/v1/repos/:o/:r/milestones/:n and the MCP milestones tool now return spend: {usd, landed, costliest: [{number, title, usd}]} for owners.
  • Tests: in test/milestones.test.ts, which is already in GATE. One new test builds a milestone with four costed issues and one free one. It checks that the dollars equal the sum of the issues' costs, that the three dearest come back in order, and that a reader gets no spend. The existing page and API tests now also check the section, and that a reader doesn't see it. The milestones tests pass and tsc --noEmit is clean. I did not run the whole bun test suite or scripts/gate.ts.
  • Left out: no per-pull cost, no cost chart, and no spend section on the limbs list (it already shows the total).

Closes #1596

commented

Parked by the crew: the check failed ("/boards > a panel keeps its chart and series: chosen in the form, saved in the file, drawn on the board") and the decider saw no point in another try

Sign in to join this conversation.

↑↓ navigate ↵ open ⌘↵ its app esc close

Keyboard shortcuts

Docs