Commit 350d4d3
committed
rpc: fix sync-driver build and same-rev pull divergence
The fetch watermark became a rev/path cursor, but reconcileWatermarks
still read remoteWatermarks.fetchRev, a field that no longer exists on
the watermarks() result. The reference broke the type check, failed
the rpc build, and cascaded into every workspace that depends on the
built package. Read the rev off the cursor instead.
The same cursor conversion also widened the pullOnce recovery
predicate. The inline reset path exists to absorb a remote that forgot
what we pushed, which shows up as the remote's applied push cursor rev
regressing below our local pushRev. Comparing the full cursor instead
of its rev folded a second, unrelated case into the recoverable set: a
same-rev partial cursor, where the remote applied part of the rev we
pushed and then tore down mid-apply. That is a genuine cross-side
invariant violation. Resetting and replaying cannot mend lost state
inside a rev the remote claimed to hold, so the predicate is rev-only
again and the assertion surfaces the partial-apply case.
Point the envelope-disposal test at a same-rev partial cursor so it
exercises a real invariant trip rather than the recoverable rev
regression, which the inline reset now swallows by design.1 parent 1127ae2 commit 350d4d3
2 files changed
Lines changed: 31 additions & 18 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | 1 | | |
| 2 | + | |
2 | 3 | | |
3 | 4 | | |
4 | 5 | | |
| |||
58 | 59 | | |
59 | 60 | | |
60 | 61 | | |
61 | | - | |
| 62 | + | |
62 | 63 | | |
63 | 64 | | |
64 | 65 | | |
| |||
68 | 69 | | |
69 | 70 | | |
70 | 71 | | |
71 | | - | |
| 72 | + | |
| 73 | + | |
| 74 | + | |
72 | 75 | | |
73 | 76 | | |
74 | 77 | | |
| |||
460 | 463 | | |
461 | 464 | | |
462 | 465 | | |
463 | | - | |
464 | | - | |
| 466 | + | |
| 467 | + | |
| 468 | + | |
| 469 | + | |
465 | 470 | | |
466 | 471 | | |
467 | 472 | | |
468 | 473 | | |
469 | | - | |
| 474 | + | |
| 475 | + | |
| 476 | + | |
470 | 477 | | |
471 | 478 | | |
472 | 479 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
107 | 107 | | |
108 | 108 | | |
109 | 109 | | |
110 | | - | |
111 | | - | |
112 | | - | |
113 | | - | |
| 110 | + | |
| 111 | + | |
| 112 | + | |
| 113 | + | |
114 | 114 | | |
115 | 115 | | |
116 | 116 | | |
| |||
119 | 119 | | |
120 | 120 | | |
121 | 121 | | |
| 122 | + | |
| 123 | + | |
| 124 | + | |
| 125 | + | |
| 126 | + | |
| 127 | + | |
| 128 | + | |
122 | 129 | | |
123 | 130 | | |
124 | | - | |
125 | | - | |
| 131 | + | |
126 | 132 | | |
127 | 133 | | |
128 | 134 | | |
| |||
410 | 416 | | |
411 | 417 | | |
412 | 418 | | |
413 | | - | |
414 | | - | |
415 | | - | |
416 | | - | |
417 | | - | |
418 | | - | |
| 419 | + | |
| 420 | + | |
| 421 | + | |
| 422 | + | |
| 423 | + | |
| 424 | + | |
419 | 425 | | |
420 | 426 | | |
421 | 427 | | |
422 | 428 | | |
423 | 429 | | |
424 | 430 | | |
425 | 431 | | |
426 | | - | |
| 432 | + | |
427 | 433 | | |
428 | 434 | | |
429 | 435 | | |
| |||
0 commit comments