Commit e2a2bdf
committed
fix(watch): complete RPC builds independently
Introduce build requests with hidden completion ivars in the build system.
The watch build loop can still batch RPC build requests together, but each
request now reports success as soon as its own action builder and per-request
finalization complete instead of waiting for the entire batch.
Complete any unfinished RPC requests with the batch outcome when a build
iteration ends, so requests cancelled by --stop-on-first-error do not hang.
Update the concurrent RPC build cram test to expect the fast request to finish
before the slow target is released.
Signed-off-by: Rudi Grinberg <me@rgrinberg.com>
refactor(watch): narrow RPC request completion hook
Signed-off-by: Rudi Grinberg <me@rgrinberg.com>
refactor(watch): use input generation for RPC completion
Signed-off-by: Rudi Grinberg <me@rgrinberg.com>
fix(watch): defer diff-promotion output and finish to batch end
Per-request finalization now only saves the diff-promotion database
without promoting files, so promotion output stays ordered after
diff and error messages.
When per-request completion triggers a restart signal but all RPC
requests have already finished, treat the iteration as Done so that
the watch status line is still emitted.
Signed-off-by: Rudi Grinberg <me@rgrinberg.com>
refactor(watch): split RPC request checkpointing from completion
Checkpoint request side effects before completing RPC requests, but keep build-wide diff-promotion finalization at the end of the build iteration.
Defer request completion under --auto-promote after a checkpoint saves diff promotions, so watch mode can still restart after the final auto-promotion.
This restores ordinary auto-promote output ordering while keeping saved promotions visible to RPC promotion requests.
Signed-off-by: Rudi Grinberg <me@rgrinberg.com>1 parent e3fa370 commit e2a2bdf
8 files changed
Lines changed: 299 additions & 71 deletions
File tree
- bin
- src/dune_engine
- test/blackbox-tests/test-cases/watching
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
6 | 6 | | |
7 | 7 | | |
8 | 8 | | |
9 | | - | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
10 | 13 | | |
11 | 14 | | |
12 | 15 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
43 | 43 | | |
44 | 44 | | |
45 | 45 | | |
46 | | - | |
47 | | - | |
48 | | - | |
49 | | - | |
50 | | - | |
51 | 46 | | |
52 | 47 | | |
53 | 48 | | |
| |||
58 | 53 | | |
59 | 54 | | |
60 | 55 | | |
61 | | - | |
| 56 | + | |
62 | 57 | | |
63 | 58 | | |
64 | 59 | | |
| |||
221 | 216 | | |
222 | 217 | | |
223 | 218 | | |
| 219 | + | |
| 220 | + | |
| 221 | + | |
| 222 | + | |
| 223 | + | |
224 | 224 | | |
225 | 225 | | |
226 | 226 | | |
227 | 227 | | |
228 | 228 | | |
229 | 229 | | |
230 | 230 | | |
231 | | - | |
| 231 | + | |
| 232 | + | |
232 | 233 | | |
233 | 234 | | |
234 | 235 | | |
| |||
237 | 238 | | |
238 | 239 | | |
239 | 240 | | |
240 | | - | |
| 241 | + | |
241 | 242 | | |
242 | 243 | | |
243 | 244 | | |
| 245 | + | |
| 246 | + | |
| 247 | + | |
| 248 | + | |
| 249 | + | |
244 | 250 | | |
245 | 251 | | |
246 | 252 | | |
| |||
260 | 266 | | |
261 | 267 | | |
262 | 268 | | |
| 269 | + | |
| 270 | + | |
| 271 | + | |
| 272 | + | |
| 273 | + | |
| 274 | + | |
| 275 | + | |
263 | 276 | | |
264 | 277 | | |
265 | 278 | | |
| |||
270 | 283 | | |
271 | 284 | | |
272 | 285 | | |
| 286 | + | |
| 287 | + | |
| 288 | + | |
| 289 | + | |
273 | 290 | | |
274 | | - | |
275 | | - | |
| 291 | + | |
| 292 | + | |
276 | 293 | | |
277 | | - | |
| 294 | + | |
| 295 | + | |
| 296 | + | |
278 | 297 | | |
279 | 298 | | |
280 | 299 | | |
| |||
285 | 304 | | |
286 | 305 | | |
287 | 306 | | |
288 | | - | |
| 307 | + | |
289 | 308 | | |
290 | 309 | | |
291 | 310 | | |
292 | 311 | | |
293 | 312 | | |
294 | 313 | | |
295 | 314 | | |
296 | | - | |
297 | | - | |
| 315 | + | |
298 | 316 | | |
299 | | - | |
| 317 | + | |
| 318 | + | |
| 319 | + | |
300 | 320 | | |
301 | 321 | | |
302 | 322 | | |
| |||
306 | 326 | | |
307 | 327 | | |
308 | 328 | | |
| 329 | + | |
309 | 330 | | |
310 | 331 | | |
311 | 332 | | |
| |||
329 | 350 | | |
330 | 351 | | |
331 | 352 | | |
332 | | - | |
333 | | - | |
| 353 | + | |
| 354 | + | |
334 | 355 | | |
335 | | - | |
336 | | - | |
| 356 | + | |
| 357 | + | |
| 358 | + | |
337 | 359 | | |
338 | 360 | | |
339 | 361 | | |
| |||
347 | 369 | | |
348 | 370 | | |
349 | 371 | | |
350 | | - | |
| 372 | + | |
| 373 | + | |
| 374 | + | |
| 375 | + | |
| 376 | + | |
| 377 | + | |
| 378 | + | |
| 379 | + | |
| 380 | + | |
| 381 | + | |
| 382 | + | |
| 383 | + | |
| 384 | + | |
351 | 385 | | |
352 | 386 | | |
353 | 387 | | |
| |||
358 | 392 | | |
359 | 393 | | |
360 | 394 | | |
361 | | - | |
362 | | - | |
363 | | - | |
364 | | - | |
365 | | - | |
366 | | - | |
367 | | - | |
| 395 | + | |
| 396 | + | |
| 397 | + | |
| 398 | + | |
368 | 399 | | |
369 | | - | |
| 400 | + | |
| 401 | + | |
370 | 402 | | |
371 | 403 | | |
372 | 404 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1121 | 1121 | | |
1122 | 1122 | | |
1123 | 1123 | | |
1124 | | - | |
1125 | | - | |
1126 | | - | |
1127 | | - | |
| 1124 | + | |
| 1125 | + | |
| 1126 | + | |
| 1127 | + | |
| 1128 | + | |
| 1129 | + | |
| 1130 | + | |
| 1131 | + | |
| 1132 | + | |
| 1133 | + | |
| 1134 | + | |
| 1135 | + | |
| 1136 | + | |
1128 | 1137 | | |
1129 | 1138 | | |
1130 | 1139 | | |
| |||
1144 | 1153 | | |
1145 | 1154 | | |
1146 | 1155 | | |
1147 | | - | |
1148 | | - | |
1149 | | - | |
1150 | | - | |
| 1156 | + | |
1151 | 1157 | | |
1152 | 1158 | | |
1153 | 1159 | | |
| |||
1193 | 1199 | | |
1194 | 1200 | | |
1195 | 1201 | | |
| 1202 | + | |
| 1203 | + | |
| 1204 | + | |
| 1205 | + | |
| 1206 | + | |
| 1207 | + | |
1196 | 1208 | | |
1197 | 1209 | | |
1198 | 1210 | | |
| |||
1201 | 1213 | | |
1202 | 1214 | | |
1203 | 1215 | | |
1204 | | - | |
1205 | | - | |
1206 | | - | |
1207 | | - | |
1208 | | - | |
1209 | | - | |
| 1216 | + | |
| 1217 | + | |
| 1218 | + | |
| 1219 | + | |
| 1220 | + | |
| 1221 | + | |
| 1222 | + | |
| 1223 | + | |
| 1224 | + | |
| 1225 | + | |
| 1226 | + | |
| 1227 | + | |
| 1228 | + | |
| 1229 | + | |
| 1230 | + | |
| 1231 | + | |
| 1232 | + | |
| 1233 | + | |
| 1234 | + | |
| 1235 | + | |
| 1236 | + | |
| 1237 | + | |
| 1238 | + | |
| 1239 | + | |
| 1240 | + | |
| 1241 | + | |
| 1242 | + | |
| 1243 | + | |
| 1244 | + | |
| 1245 | + | |
| 1246 | + | |
| 1247 | + | |
| 1248 | + | |
| 1249 | + | |
| 1250 | + | |
| 1251 | + | |
| 1252 | + | |
| 1253 | + | |
| 1254 | + | |
| 1255 | + | |
| 1256 | + | |
| 1257 | + | |
| 1258 | + | |
| 1259 | + | |
| 1260 | + | |
| 1261 | + | |
| 1262 | + | |
| 1263 | + | |
| 1264 | + | |
| 1265 | + | |
| 1266 | + | |
| 1267 | + | |
| 1268 | + | |
| 1269 | + | |
| 1270 | + | |
| 1271 | + | |
| 1272 | + | |
| 1273 | + | |
| 1274 | + | |
| 1275 | + | |
| 1276 | + | |
| 1277 | + | |
| 1278 | + | |
| 1279 | + | |
| 1280 | + | |
| 1281 | + | |
| 1282 | + | |
| 1283 | + | |
| 1284 | + | |
| 1285 | + | |
| 1286 | + | |
| 1287 | + | |
| 1288 | + | |
| 1289 | + | |
| 1290 | + | |
| 1291 | + | |
| 1292 | + | |
| 1293 | + | |
1210 | 1294 | | |
1211 | 1295 | | |
1212 | 1296 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
60 | 60 | | |
61 | 61 | | |
62 | 62 | | |
63 | | - | |
| 63 | + | |
| 64 | + | |
| 65 | + | |
| 66 | + | |
| 67 | + | |
| 68 | + | |
| 69 | + | |
| 70 | + | |
| 71 | + | |
| 72 | + | |
64 | 73 | | |
65 | 74 | | |
66 | | - | |
| 75 | + | |
| 76 | + | |
67 | 77 | | |
68 | 78 | | |
69 | 79 | | |
| |||
0 commit comments