I2474 — The drain draws its merge throughput: each day's merges over the fortnight its trail ends on
Draw on the PR Drain how many pull requests the executor merged on each of the fourteen days that end on the day of its trail's newest event, as a chart whose counts are written in its label and in a table beside it.
DONE wave 4 · p1 · implementation profile · runs alone
Part of development-runtime — The runtime has a development surface.
Objective
Draw on the PR Drain how many pull requests the executor merged on each of the fourteen days that end on the day of its trail's newest event, as a chart whose counts are written in its label and in a table beside it.
Why
The owner asked on 2026-10-11 to implement every view of the UI screenshots (reference 03-pr-drain shows a merge throughput chart; pack v3 M04-03, measured time series). The executor's trail records every merge_succeeded with its time, and the queue already folds a seven-day merge count, but nothing showed the series.
Current state
The drain shows merges in seven days and merges per day as two numbers.
Desired state
The drain panel, which asks integration.events, draws 'Merge throughput': the fourteen days ending on the trail's newest event's day (the record's end, not the reader's clock), each with its count of merge_succeeded events, as a server-side SVG chart labelled with every day's count and a table of the same numbers. An attempt is no merge, a merge outside the window is not drawn, and a trail with no merge in the window says so and draws no chart.
Scope
- apps/majordomus-cli/src/ui/prs.rs
- .ai/repo/project/issues/I2474.yaml
- docs/MAJORDOMUS_UI.md
- test/cases/1079_the_drain_draws_its_throughput.sh
Dependencies
Acceptance criteria
- the chart covers fourteen days ending on the trail's newest event's day
- each day counts merge_succeeded events only, and the counts are in the chart's label and a table
- a trail with no merge in the window draws no chart and says so
Validation
- cargo test --lib ui::prs
- test/run.sh 1079_the_drain_draws_its_throughput
Evidence required
- ui_throughput_unit_test
- ui_throughput_case_1079
Evidence
| covers | type | command | result | at commit |
|---|---|---|---|---|
| ui_throughput_unit_test | ci | cargo test --lib ui::prs (validate run 38223440282 on 722228ef3c, the v0.21.0 top) | merges_are_counted_per_day_over_the_days_the_trail_ends_on ok | 722228e |
| ui_throughput_case_1079 | ci | test/run.sh 1079_the_drain_draws_its_throughput (validate run 38223440282 on 722228ef3c, the v0.21.0 top) | case 1079_the_drain_draws_its_throughput ok | 722228e |
Timeline
- started
- 2026-10-12T11:03:47Z
- verified
- 2026-10-12T11:03:54Z
- completed
- 2026-10-12T11:04:08Z
Those three fields, the evidence above and the state of the dependencies are all the status is made of. There is no status field to disagree with them.
Canonical record: .ai/repo/project/issues/I2474.yaml. Read it back with majordomus plan show I2474.