Repository navigation
Commit ce18d85
committed
Plan check before the first PR; each fix round gets its own budget and never fails an open PR
A complex ticket's plan listed several new files. The first implement pass
changed one, the proof check listed the rest as "gaps under Open items" and
the PR opened anyway. CoderHelm's reviewer then asked for changes three
times; each round re-entered implement inside what was left of one worker
invocation, the third was killed mid-way, the stuck-run sweep marked the run
failed while its PR was open and green, and nothing said what the round had
pushed.
Plan coverage (plan_coverage.rs):
- The plan's task checklist is compared with the branch's diff, task by
task. Missing tasks get up to two implement rounds aimed at exactly them,
then a continuation in a fresh invocation (bounded); a continuation keeps
its branch and is told what is left.
- Planned work still missing stops the run before any PR, with a plain
status naming the tasks; the branch is copied to <branch>-wip so a later
run's reset can't lose it. Only tasks the plan marks optional may be left
out, and the PR names them under Open items with the reason.
- The proof judge sees the checklist and reports planned_work; it gets a fix
round and is never downgraded to Open items.
- tasks.md marks only the tasks the branch did.
- A continuation no longer resets its own branch to base.
Fix rounds (common::run_round, passes/round.rs):
- CI fix, review fix and feedback rounds each run with their own deadline,
measured from the invocation they run in, recorded on the run as `round`.
A round with too little of its invocation left is parked and runs first in
a fresh one; a round that uses its budget with work left continues there
(up to three steps).
- A round that can't finish leaves the run completed with
`round_incomplete` (why, the commits it pushed, the files): "Pull request
open; the last fix round didn't finish: <reason>". Feedback and resume
errors on a run with an open PR end the same way instead of failed.
- The stuck-run sweep waits for a round's own deadline, and a stuck run
with an open PR becomes completed with round_incomplete, never failed.
No lost work: every coder write is already its own commit on the branch;
the coder is told to write each task's files as soon as the task is done,
the deadline note asks it to write any finished file before stopping, and
an unfinished round records the commits it pushed.
API: Run.round_incomplete (OpenAPI), and POST /api/runs/{id}/retry resumes
the unfinished round on the same run ("resuming"), giving one automated-fix
slot back.1 parent f1633c8 commit ce18d85
19 files changed
Lines changed: 3443 additions & 204 deletions
File tree
- docs/api
- lambda
- stuck-run-cleanup
- tests
- services
- common/src
- gateway/src/routes
- worker/src
- agent
- passes
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1977 | 1977 | | |
1978 | 1978 | | |
1979 | 1979 | | |
| 1980 | + | |
| 1981 | + | |
| 1982 | + | |
| 1983 | + | |
| 1984 | + | |
| 1985 | + | |
| 1986 | + | |
| 1987 | + | |
| 1988 | + | |
| 1989 | + | |
| 1990 | + | |
| 1991 | + | |
| 1992 | + | |
| 1993 | + | |
| 1994 | + | |
| 1995 | + | |
| 1996 | + | |
| 1997 | + | |
| 1998 | + | |
| 1999 | + | |
| 2000 | + | |
| 2001 | + | |
| 2002 | + | |
| 2003 | + | |
1980 | 2004 | | |
1981 | 2005 | | |
1982 | 2006 | | |
| |||
2657 | 2681 | | |
2658 | 2682 | | |
2659 | 2683 | | |
| 2684 | + | |
| 2685 | + | |
| 2686 | + | |
| 2687 | + | |
| 2688 | + | |
| 2689 | + | |
| 2690 | + | |
| 2691 | + | |
| 2692 | + | |
| 2693 | + | |
| 2694 | + | |
| 2695 | + | |
| 2696 | + | |
| 2697 | + | |
| 2698 | + | |
| 2699 | + | |
| 2700 | + | |
| 2701 | + | |
| 2702 | + | |
| 2703 | + | |
| 2704 | + | |
| 2705 | + | |
| 2706 | + | |
| 2707 | + | |
| 2708 | + | |
| 2709 | + | |
| 2710 | + | |
| 2711 | + | |
| 2712 | + | |
| 2713 | + | |
| 2714 | + | |
| 2715 | + | |
| 2716 | + | |
| 2717 | + | |
| 2718 | + | |
| 2719 | + | |
| 2720 | + | |
| 2721 | + | |
| 2722 | + | |
| 2723 | + | |
| 2724 | + | |
| 2725 | + | |
| 2726 | + | |
| 2727 | + | |
| 2728 | + | |
| 2729 | + | |
| 2730 | + | |
| 2731 | + | |
| 2732 | + | |
| 2733 | + | |
| 2734 | + | |
| 2735 | + | |
| 2736 | + | |
| 2737 | + | |
| 2738 | + | |
| 2739 | + | |
| 2740 | + | |
| 2741 | + | |
| 2742 | + | |
| 2743 | + | |
| 2744 | + | |
| 2745 | + | |
| 2746 | + | |
| 2747 | + | |
| 2748 | + | |
| 2749 | + | |
| 2750 | + | |
| 2751 | + | |
| 2752 | + | |
| 2753 | + | |
| 2754 | + | |
| 2755 | + | |
| 2756 | + | |
| 2757 | + | |
| 2758 | + | |
| 2759 | + | |
| 2760 | + | |
| 2761 | + | |
| 2762 | + | |
| 2763 | + | |
| 2764 | + | |
2660 | 2765 | | |
2661 | 2766 | | |
2662 | 2767 | | |
| |||
3036 | 3141 | | |
3037 | 3142 | | |
3038 | 3143 | | |
| 3144 | + | |
| 3145 | + | |
| 3146 | + | |
| 3147 | + | |
| 3148 | + | |
| 3149 | + | |
| 3150 | + | |
| 3151 | + | |
| 3152 | + | |
| 3153 | + | |
| 3154 | + | |
3039 | 3155 | | |
3040 | 3156 | | |
3041 | 3157 | | |
| |||
3140 | 3256 | | |
3141 | 3257 | | |
3142 | 3258 | | |
3143 | | - | |
| 3259 | + | |
3144 | 3260 | | |
3145 | 3261 | | |
3146 | 3262 | | |
| |||
6347 | 6463 | | |
6348 | 6464 | | |
6349 | 6465 | | |
6350 | | - | |
| 6466 | + | |
6351 | 6467 | | |
6352 | 6468 | | |
6353 | 6469 | | |
| |||
6373 | 6489 | | |
6374 | 6490 | | |
6375 | 6491 | | |
6376 | | - | |
| 6492 | + | |
6377 | 6493 | | |
6378 | 6494 | | |
6379 | 6495 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
12 | 12 | | |
13 | 13 | | |
14 | 14 | | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
| 21 | + | |
| 22 | + | |
| 23 | + | |
15 | 24 | | |
16 | 25 | | |
17 | 26 | | |
| |||
37 | 46 | | |
38 | 47 | | |
39 | 48 | | |
| 49 | + | |
| 50 | + | |
| 51 | + | |
| 52 | + | |
| 53 | + | |
| 54 | + | |
| 55 | + | |
| 56 | + | |
| 57 | + | |
| 58 | + | |
| 59 | + | |
40 | 60 | | |
41 | 61 | | |
42 | 62 | | |
| |||
76 | 96 | | |
77 | 97 | | |
78 | 98 | | |
| 99 | + | |
| 100 | + | |
| 101 | + | |
| 102 | + | |
| 103 | + | |
| 104 | + | |
| 105 | + | |
| 106 | + | |
| 107 | + | |
| 108 | + | |
| 109 | + | |
| 110 | + | |
| 111 | + | |
| 112 | + | |
| 113 | + | |
| 114 | + | |
| 115 | + | |
| 116 | + | |
| 117 | + | |
| 118 | + | |
| 119 | + | |
| 120 | + | |
| 121 | + | |
| 122 | + | |
| 123 | + | |
| 124 | + | |
| 125 | + | |
| 126 | + | |
| 127 | + | |
| 128 | + | |
| 129 | + | |
| 130 | + | |
| 131 | + | |
| 132 | + | |
| 133 | + | |
| 134 | + | |
| 135 | + | |
| 136 | + | |
| 137 | + | |
| 138 | + | |
| 139 | + | |
| 140 | + | |
| 141 | + | |
| 142 | + | |
| 143 | + | |
| 144 | + | |
| 145 | + | |
| 146 | + | |
| 147 | + | |
| 148 | + | |
| 149 | + | |
| 150 | + | |
| 151 | + | |
| 152 | + | |
| 153 | + | |
| 154 | + | |
| 155 | + | |
| 156 | + | |
| 157 | + | |
| 158 | + | |
| 159 | + | |
| 160 | + | |
| 161 | + | |
| 162 | + | |
| 163 | + | |
| 164 | + | |
| 165 | + | |
| 166 | + | |
| 167 | + | |
| 168 | + | |
| 169 | + | |
| 170 | + | |
| 171 | + | |
| 172 | + | |
| 173 | + | |
| 174 | + | |
| 175 | + | |
79 | 176 | | |
80 | 177 | | |
81 | 178 | | |
| |||
137 | 234 | | |
138 | 235 | | |
139 | 236 | | |
140 | | - | |
| 237 | + | |
| 238 | + | |
141 | 239 | | |
142 | 240 | | |
| 241 | + | |
143 | 242 | | |
144 | 243 | | |
145 | 244 | | |
146 | 245 | | |
147 | 246 | | |
148 | 247 | | |
149 | 248 | | |
| 249 | + | |
| 250 | + | |
| 251 | + | |
150 | 252 | | |
151 | 253 | | |
152 | 254 | | |
| |||
179 | 281 | | |
180 | 282 | | |
181 | 283 | | |
182 | | - | |
183 | | - | |
184 | | - | |
| 284 | + | |
| 285 | + | |
| 286 | + | |
| 287 | + | |
| 288 | + | |
| 289 | + | |
| 290 | + | |
| 291 | + | |
| 292 | + | |
| 293 | + | |
| 294 | + | |
| 295 | + | |
| 296 | + | |
| 297 | + | |
| 298 | + | |
| 299 | + | |
| 300 | + | |
| 301 | + | |
| 302 | + | |
| 303 | + | |
| 304 | + | |
| 305 | + | |
| 306 | + | |
185 | 307 | | |
186 | 308 | | |
187 | 309 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
59 | 59 | | |
60 | 60 | | |
61 | 61 | | |
| 62 | + | |
| 63 | + | |
| 64 | + | |
| 65 | + | |
| 66 | + | |
| 67 | + | |
| 68 | + | |
| 69 | + | |
| 70 | + | |
| 71 | + | |
| 72 | + | |
| 73 | + | |
| 74 | + | |
| 75 | + | |
| 76 | + | |
| 77 | + | |
| 78 | + | |
| 79 | + | |
| 80 | + | |
| 81 | + | |
| 82 | + | |
| 83 | + | |
| 84 | + | |
| 85 | + | |
| 86 | + | |
| 87 | + | |
| 88 | + | |
| 89 | + | |
| 90 | + | |
| 91 | + | |
| 92 | + | |
| 93 | + | |
| 94 | + | |
| 95 | + | |
| 96 | + | |
| 97 | + | |
| 98 | + | |
| 99 | + | |
| 100 | + | |
| 101 | + | |
| 102 | + | |
| 103 | + | |
| 104 | + | |
| 105 | + | |
| 106 | + | |
| 107 | + | |
| 108 | + | |
| 109 | + | |
| 110 | + | |
62 | 111 | | |
63 | 112 | | |
0 commit comments