skip to content
Jobs

Restoring a Silently Reverted TUI Layout

Re-applying dropped layout commits by hand, then pinning them with a test the gate never had.

Gantry sprints
Re-applying dropped layout commits by hand, then pinning them with a test the gate never had.

Gantry's terminal interface shows a two-column view: a sidebar of stacked cards on the left, the activity feed on the right. Hand-written commits had built that layout. Then an earlier, long-running build merged the main branch into its own working copy, hit a conflict, and its automatic resolver kept its own side — silently discarding every one of them. The main branch went back to a single flat panel, and nothing complained, because no test ever described what the layout was supposed to be.

This job put the changes back, reconciling them by hand onto code that had moved on in the meantime, and then added a render test that captures the restored structure — so the next time a merge tries to drop it, something fails.

Build

The work split into reinstating the layout and pinning it with a test — the second piece being the actual root-cause fix, since the changes were droppable in the first place only because no test described them.

The reinstatement could not be a mechanical replay. A plain cherry-pick of the original commits conflicted on every one, because the intervening build had shifted the surrounding code — imports, the draw body, the mouse-wheel routing — even where the lines being restored landed on otherwise unchanged code. So the first sprint's brief defined the work as a hand reconciliation guided by the diffs and a file-by-file handover document, not an apply: reproduce the intent of each commit against code that had moved.

The second boundary is where the design actually answers the problem. The changes were dropped because the test suite asserted nothing about the layout — a resolver could discard the sidebar's structure and the gate stayed green. The second sprint adds a render test that pins the reinstated layout, and it had to land after the first because its assertions only pass once the layout is back. Reinstating without that test would have fixed the symptom and left the hole open.

The run never went red. No gate turned a sprint back, and no review forced the plan to change. The reconciliation risk that a mechanical merge had already failed at was handled by carrying the handover's precise, hunk-by-hunk instructions into the sprint brief, so the hard part was described before the agent started rather than discovered when a test failed.

Feature

Before this, the layout lived only as code no test guarded, which is what let an automatic merge quietly revert it; the job rebuilt the stacked cards and the two-column body and added render tests that assert both.

Before this job, the layout existed only as code — nothing in the suite said the sidebar should be stacked cards, or that the body should be two columns rather than one panel. That absence is what let an automatic merge quietly revert it. The answer has two parts: the layout itself, rebuilt as an about card stacked above a sprints-and-milestones card, each with its own band separator, over a body split into a left rail and a right feed with a gutter between; and render tests that drive the app's real draw path and assert both the column split and the stacked-card structure, giving that intent ground truth.

At today's HEAD both touched files are still present and the design is intact in a recognizable form. The sidebar still stacks an about card over a sprints card through a `draw_sidebar_card` helper, the standalone activity label the reinstatement removed is still gone, and the reinstated-layout test module is still there, asserting equal-width columns and the two-card structure.

What has moved is the column arithmetic. The reinstatement fixed the two columns at equal width; that has since been folded into a larger layout model — an adaptive default that caps and centers the columns, plus a user-draggable divider that lets the reader own the ratio, its position tracked so input routing can hit-test the drag. The mouse-wheel edits the job made in the input module were rewritten in that same work. The layout the job restored survives; the mechanism that sizes it has grown around it.

unavailable sessions
unavailable context
36,794 in / 58,824 out tokens
$7.69 cost
0 x 2 milestones x sprints
unavailable edits
unavailable commands
19m duration
unavailable roles
0 x 0 fixes x replans
- harness