Repository navigation
fix(agent-crdt): reject updates from replaced document lineage - #16795
christian-byrne wants to merge 14 commits into
Conversation
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Path: .coderabbit.yaml Review profile: ASSERTIVE Plan: Team Run ID: 📒 Files selected for processing (9)
Included review availability: Your plan provides up to 10 included reviews per hour; 2 remain after this review. 📝 WalkthroughWalkthroughThe CRDT frame protocol now carries lineage sequence metadata. The follower bridge validates lineage changes, rejects stale frames, replaces documents for newer lineages, and resubscribes with the known lineage. Tests cover parsing, resets, acknowledgements, catch-up, and integration frames. ChangesCRDT lineage synchronization
Estimated code review effort: 4 (Complex) | ~45 minutes Merge Risk: ⚪ Minimal · up to No confirmed merge-blocking risk remains for the lineage synchronization changes. Sequence Diagram(s)sequenceDiagram
participant DocFrameClient
participant LayoutFollowerBridge
participant FollowerDocument
DocFrameClient->>LayoutFollowerBridge: deliver doc_update with lineageSeq
LayoutFollowerBridge->>LayoutFollowerBridge: compare lineageSeq
LayoutFollowerBridge->>FollowerDocument: replace document for newer lineage
LayoutFollowerBridge->>DocFrameClient: resubscribe with known lineage
Suggested reviewers: Important Pre-merge checks failedPlease resolve all errors before merging. Addressing warnings is optional. ❌ Failed checks (1 inconclusive)
✅ Passed checks (6 passed)
Full details: End-To-End Regression Coverage For FixesExplanation The changed-file list is available, and it shows changes under ✨ Finishing Touches📝 Generate docstrings
🧪 Generate unit tests (beta)
Comment |
🎨 Storybook: ✅ Built — View Storybook🎭 Playwright: ✅ 1907 passed, 0 failed📊 Browser Reports
📦 Bundle: 9.74 MB gzip ⚪ 0 BDetailsSummary
Category Glance App Entry Points — 3.73 kB (baseline 3.73 kB) • ⚪ 0 BMain entry bundles and manifests Status: 1 unchanged Graph Workspace — 1.43 MB (baseline 1.43 MB) • ⚪ 0 BGraph editor runtime, canvas, workflow orchestration Status: 3 unchanged Views & Navigation — 128 kB (baseline 128 kB) • ⚪ 0 BTop-level views, pages, and routed surfaces Status: 18 unchanged Panels & Settings — 621 kB (baseline 621 kB) • ⚪ 0 BConfiguration panels, inspectors, and settings screens Status: 27 unchanged User & Accounts — 28.9 kB (baseline 28.9 kB) • ⚪ 0 BAuthentication, profile, and account management bundles Status: 11 unchanged Editors & Dialogs — 126 kB (baseline 126 kB) • ⚪ 0 BModals, dialogs, drawers, and in-app editors Status: 8 unchanged UI Components — 117 kB (baseline 117 kB) • ⚪ 0 BReusable component library chunks Status: 15 unchanged Data & Services — 3.6 MB (baseline 3.6 MB) • ⚪ 0 BStores, services, APIs, and repositories Status: 16 unchanged Utilities & Hooks — 558 kB (baseline 558 kB) • ⚪ 0 BHelpers, composables, and utility bundles Status: 36 unchanged Vendor & Third-Party — 18.1 MB (baseline 18.1 MB) • ⚪ 0 BExternal libraries and shared vendor chunks Status: 18 unchanged Other — 16.6 MB (baseline 16.6 MB) • ⚪ 0 BBundles that do not match a named category Status: 296 unchanged ⚡ Performance Report
Show regressions
All metrics
Historical variance (last 15 runs)
Trend (last 15 commits on main)
Raw data{
"timestamp": "2026-09-05T20:41:53.654Z",
"gitSha": "a627befc47dd5a9b429f874fdb4a7b32e0b84cea",
"branch": "christian-byrne/ecw154-fe-lineage-rejection",
"measurements": [
{
"name": "canvas-idle",
"durationMs": 2083.266000000094,
"styleRecalcs": 9,
"styleRecalcDurationMs": 7.990999999999998,
"layouts": 0,
"layoutDurationMs": 0,
"taskDurationMs": 502.12999999999994,
"heapDeltaBytes": -13643372,
"heapUsedBytes": 56066744,
"domNodes": -279,
"jsHeapTotalBytes": 4972544,
"scriptDurationMs": 8.953,
"eventListeners": -144,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.666666666666668,
"p95FrameDurationMs": 16.800000000000182
},
{
"name": "canvas-idle",
"durationMs": 2033.2310000000007,
"styleRecalcs": 9,
"styleRecalcDurationMs": 9.234,
"layouts": 0,
"layoutDurationMs": 0,
"taskDurationMs": 506.2549999999999,
"heapDeltaBytes": 8608880,
"heapUsedBytes": 78521076,
"domNodes": -281,
"jsHeapTotalBytes": 5234688,
"scriptDurationMs": 9.852,
"eventListeners": -144,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.666666666666668,
"p95FrameDurationMs": 16.700000000000728
},
{
"name": "canvas-mouse-sweep",
"durationMs": 2053.1220000000303,
"styleRecalcs": 82,
"styleRecalcDurationMs": 46.276,
"layouts": 14,
"layoutDurationMs": 4.8389999999999995,
"taskDurationMs": 1026.2129999999997,
"heapDeltaBytes": -8303168,
"heapUsedBytes": 61829824,
"domNodes": -272,
"jsHeapTotalBytes": 5496832,
"scriptDurationMs": 161.06699999999998,
"eventListeners": -146,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.666666666666668,
"p95FrameDurationMs": 16.700000000000728
},
{
"name": "canvas-mouse-sweep",
"durationMs": 1963.647999999921,
"styleRecalcs": 80,
"styleRecalcDurationMs": 44.18900000000001,
"layouts": 14,
"layoutDurationMs": 4.7749999999999995,
"taskDurationMs": 998.418,
"heapDeltaBytes": 3663960,
"heapUsedBytes": 74538444,
"domNodes": -278,
"jsHeapTotalBytes": 6021120,
"scriptDurationMs": 163.02,
"eventListeners": -174,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.666666666666668,
"p95FrameDurationMs": 16.700000000000728
},
{
"name": "canvas-zoom-sweep",
"durationMs": 1682.3349999999664,
"styleRecalcs": 32,
"styleRecalcDurationMs": 16.294999999999998,
"layouts": 6,
"layoutDurationMs": 1.1090000000000002,
"taskDurationMs": 352.773,
"heapDeltaBytes": 4958664,
"heapUsedBytes": 75651148,
"domNodes": 77,
"jsHeapTotalBytes": 5767168,
"scriptDurationMs": 10.922,
"eventListeners": 19,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.66333333333332,
"p95FrameDurationMs": 16.800000000000182
},
{
"name": "canvas-zoom-sweep",
"durationMs": 1739.0550000000076,
"styleRecalcs": 32,
"styleRecalcDurationMs": 17.951999999999998,
"layouts": 6,
"layoutDurationMs": 1.179,
"taskDurationMs": 364.448,
"heapDeltaBytes": 5078772,
"heapUsedBytes": 75522080,
"domNodes": 78,
"jsHeapTotalBytes": 6291456,
"scriptDurationMs": 11.597999999999997,
"eventListeners": 19,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.66333333333335,
"p95FrameDurationMs": 16.700000000000728
},
{
"name": "dom-widget-clipping",
"durationMs": 671.5060000000221,
"styleRecalcs": 11,
"styleRecalcDurationMs": 7.223999999999999,
"layouts": 0,
"layoutDurationMs": 0,
"taskDurationMs": 448.22799999999995,
"heapDeltaBytes": -7820560,
"heapUsedBytes": 62964688,
"domNodes": 18,
"jsHeapTotalBytes": 6815744,
"scriptDurationMs": 153.28,
"eventListeners": 0,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.666666666666668,
"p95FrameDurationMs": 16.800000000000182
},
{
"name": "dom-widget-clipping",
"durationMs": 720.6180000000586,
"styleRecalcs": 10,
"styleRecalcDurationMs": 8.068999999999999,
"layouts": 0,
"layoutDurationMs": 0,
"taskDurationMs": 482.2629999999999,
"heapDeltaBytes": 18544624,
"heapUsedBytes": 88189812,
"domNodes": 16,
"jsHeapTotalBytes": 4980736,
"scriptDurationMs": 163.64600000000002,
"eventListeners": 2,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.66333333333335,
"p95FrameDurationMs": 16.700000000000728
},
{
"name": "large-graph-idle",
"durationMs": 2040.6960000000254,
"styleRecalcs": 5,
"styleRecalcDurationMs": 4.213999999999999,
"layouts": 0,
"layoutDurationMs": 0,
"taskDurationMs": 593.254,
"heapDeltaBytes": -14536996,
"heapUsedBytes": 87672780,
"domNodes": -267,
"jsHeapTotalBytes": -1114112,
"scriptDurationMs": 33.008,
"eventListeners": -144,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.666666666666668,
"p95FrameDurationMs": 16.799999999999272
},
{
"name": "large-graph-idle",
"durationMs": 2054.09300000008,
"styleRecalcs": 4,
"styleRecalcDurationMs": 3.995000000000002,
"layouts": 0,
"layoutDurationMs": 0,
"taskDurationMs": 602.9,
"heapDeltaBytes": 10985176,
"heapUsedBytes": 87311940,
"domNodes": -272,
"jsHeapTotalBytes": -1937408,
"scriptDurationMs": 35.233,
"eventListeners": -172,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.666666666666668,
"p95FrameDurationMs": 16.700000000000728
},
{
"name": "large-graph-pan",
"durationMs": 2343.8829999998916,
"styleRecalcs": 65,
"styleRecalcDurationMs": 12.309000000000001,
"layouts": 0,
"layoutDurationMs": 0,
"taskDurationMs": 1666.0680000000002,
"heapDeltaBytes": 8026304,
"heapUsedBytes": 85098156,
"domNodes": -273,
"jsHeapTotalBytes": -401408,
"scriptDurationMs": 801.3169999999999,
"eventListeners": -172,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.670000000000012,
"p95FrameDurationMs": 16.800000000000182
},
{
"name": "large-graph-pan",
"durationMs": 2329.2120000000978,
"styleRecalcs": 66,
"styleRecalcDurationMs": 12.593999999999998,
"layouts": 0,
"layoutDurationMs": 0,
"taskDurationMs": 1683.824,
"heapDeltaBytes": 9482152,
"heapUsedBytes": 86196288,
"domNodes": -271,
"jsHeapTotalBytes": -663552,
"scriptDurationMs": 831.643,
"eventListeners": -172,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.666666666666668,
"p95FrameDurationMs": 16.700000000000728
},
{
"name": "large-graph-zoom",
"durationMs": 3537.158999999974,
"styleRecalcs": 60,
"styleRecalcDurationMs": 11.073,
"layouts": 60,
"layoutDurationMs": 13.71,
"taskDurationMs": 1705.7959999999998,
"heapDeltaBytes": 12606716,
"heapUsedBytes": 80095604,
"domNodes": 0,
"jsHeapTotalBytes": 0,
"scriptDurationMs": 784.327,
"eventListeners": 10,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.666666666666668,
"p95FrameDurationMs": 16.700000000000728
},
{
"name": "large-graph-zoom",
"durationMs": 3608.8079999999536,
"styleRecalcs": 60,
"styleRecalcDurationMs": 11.332000000000003,
"layouts": 60,
"layoutDurationMs": 13.644000000000002,
"taskDurationMs": 1743.147,
"heapDeltaBytes": 12357652,
"heapUsedBytes": 80224388,
"domNodes": 0,
"jsHeapTotalBytes": 0,
"scriptDurationMs": 799.949,
"eventListeners": 8,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.666666666666668,
"p95FrameDurationMs": 16.700000000000728
},
{
"name": "legacy-node-drag",
"durationMs": 3146.975999999995,
"styleRecalcs": 40,
"styleRecalcDurationMs": 5.476999999999999,
"layouts": 0,
"layoutDurationMs": 0,
"taskDurationMs": 1909.6770000000004,
"heapDeltaBytes": 21822744,
"heapUsedBytes": 89374020,
"domNodes": -11,
"jsHeapTotalBytes": 1990656,
"scriptDurationMs": 950.112,
"eventListeners": 188,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.66333333333332,
"p95FrameDurationMs": 16.700000000000728
},
{
"name": "legacy-node-drag",
"durationMs": 3171.1600000001,
"styleRecalcs": 40,
"styleRecalcDurationMs": 5.765,
"layouts": 0,
"layoutDurationMs": 0,
"taskDurationMs": 2006.5370000000003,
"heapDeltaBytes": 27023392,
"heapUsedBytes": 94760500,
"domNodes": 0,
"jsHeapTotalBytes": 417792,
"scriptDurationMs": 1013.4430000000001,
"eventListeners": 188,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.66333333333332,
"p95FrameDurationMs": 16.700000000000728
},
{
"name": "minimap-idle",
"durationMs": 2031.0779999999795,
"styleRecalcs": 4,
"styleRecalcDurationMs": 3.7739999999999996,
"layouts": 0,
"layoutDurationMs": 0,
"taskDurationMs": 591.077,
"heapDeltaBytes": -16496460,
"heapUsedBytes": 87350784,
"domNodes": -270,
"jsHeapTotalBytes": -851968,
"scriptDurationMs": 32.14399999999999,
"eventListeners": -144,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.666666666666668,
"p95FrameDurationMs": 16.699999999999818
},
{
"name": "minimap-idle",
"durationMs": 2022.6089999999886,
"styleRecalcs": 4,
"styleRecalcDurationMs": 5.644,
"layouts": 0,
"layoutDurationMs": 0,
"taskDurationMs": 559.8700000000001,
"heapDeltaBytes": 21980352,
"heapUsedBytes": 87549296,
"domNodes": -271,
"jsHeapTotalBytes": 0,
"scriptDurationMs": 34.54900000000001,
"eventListeners": -174,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.666666666666668,
"p95FrameDurationMs": 16.699999999999818
},
{
"name": "subgraph-dom-widget-clipping",
"durationMs": 577.3359999999457,
"styleRecalcs": 48,
"styleRecalcDurationMs": 12.041,
"layouts": 0,
"layoutDurationMs": 0,
"taskDurationMs": 407.24199999999996,
"heapDeltaBytes": 14057732,
"heapUsedBytes": 86132004,
"domNodes": 22,
"jsHeapTotalBytes": 5505024,
"scriptDurationMs": 139.552,
"eventListeners": 8,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.666666666666668,
"p95FrameDurationMs": 16.700000000000728
},
{
"name": "subgraph-dom-widget-clipping",
"durationMs": 665.4119999999466,
"styleRecalcs": 45,
"styleRecalcDurationMs": 9.838,
"layouts": 0,
"layoutDurationMs": 0,
"taskDurationMs": 454.42999999999995,
"heapDeltaBytes": 15194532,
"heapUsedBytes": 87566832,
"domNodes": 16,
"jsHeapTotalBytes": 6291456,
"scriptDurationMs": 157.728,
"eventListeners": 6,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.66333333333332,
"p95FrameDurationMs": 16.700000000000728
},
{
"name": "subgraph-idle",
"durationMs": 2025.3470000000107,
"styleRecalcs": 8,
"styleRecalcDurationMs": 6.838999999999998,
"layouts": 0,
"layoutDurationMs": 0,
"taskDurationMs": 486.378,
"heapDeltaBytes": -7774860,
"heapUsedBytes": 64767668,
"domNodes": -293,
"jsHeapTotalBytes": 5496832,
"scriptDurationMs": 7.893000000000001,
"eventListeners": -190,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.666666666666668,
"p95FrameDurationMs": 16.800000000000182
},
{
"name": "subgraph-idle",
"durationMs": 2034.9410000000034,
"styleRecalcs": 8,
"styleRecalcDurationMs": 7.598000000000001,
"layouts": 0,
"layoutDurationMs": 0,
"taskDurationMs": 536.0310000000001,
"heapDeltaBytes": -7297840,
"heapUsedBytes": 65330112,
"domNodes": -295,
"jsHeapTotalBytes": 5496832,
"scriptDurationMs": 10.419999999999998,
"eventListeners": -190,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.666666666666668,
"p95FrameDurationMs": 16.699999999999818
},
{
"name": "subgraph-mouse-sweep",
"durationMs": 1742.2410000000355,
"styleRecalcs": 77,
"styleRecalcDurationMs": 37.63,
"layouts": 18,
"layoutDurationMs": 5.845,
"taskDurationMs": 821.258,
"heapDeltaBytes": 1270344,
"heapUsedBytes": 72654204,
"domNodes": -295,
"jsHeapTotalBytes": 6021120,
"scriptDurationMs": 108.226,
"eventListeners": -222,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.666666666666668,
"p95FrameDurationMs": 16.700000000000728
},
{
"name": "subgraph-mouse-sweep",
"durationMs": 1774.479000000042,
"styleRecalcs": 77,
"styleRecalcDurationMs": 39.519,
"layouts": 18,
"layoutDurationMs": 6.196,
"taskDurationMs": 850.6339999999999,
"heapDeltaBytes": 1260128,
"heapUsedBytes": 73014384,
"domNodes": -292,
"jsHeapTotalBytes": 6283264,
"scriptDurationMs": 112.749,
"eventListeners": -222,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.666666666666668,
"p95FrameDurationMs": 16.700000000000728
},
{
"name": "subgraph-transition-enter",
"durationMs": 1403.505999999993,
"styleRecalcs": 20,
"styleRecalcDurationMs": 33.86299999999999,
"layouts": 16,
"layoutDurationMs": 16.328000000000003,
"taskDurationMs": 1027.411,
"heapDeltaBytes": 19959280,
"heapUsedBytes": 103893036,
"domNodes": 13751,
"jsHeapTotalBytes": 10485760,
"scriptDurationMs": 35.30100000000001,
"eventListeners": 2387,
"totalBlockingTimeMs": 138,
"frameDurationMs": 16.666666666666668,
"p95FrameDurationMs": 16.700000000000728
},
{
"name": "viewport-pan-sweep",
"durationMs": 8327.893999999902,
"styleRecalcs": 247,
"styleRecalcDurationMs": 40.834999999999994,
"layouts": 0,
"layoutDurationMs": 0,
"taskDurationMs": 5632.298,
"heapDeltaBytes": 8997656,
"heapUsedBytes": 85255520,
"domNodes": -269,
"jsHeapTotalBytes": -401408,
"scriptDurationMs": 2564.612,
"eventListeners": -158,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.66333333333332,
"p95FrameDurationMs": 16.80000000000109
},
{
"name": "viewport-pan-sweep",
"durationMs": 8312.343000000055,
"styleRecalcs": 247,
"styleRecalcDurationMs": 41.135000000000005,
"layouts": 0,
"layoutDurationMs": 0,
"taskDurationMs": 5662.206,
"heapDeltaBytes": -8523680,
"heapUsedBytes": 93350244,
"domNodes": -267,
"jsHeapTotalBytes": -1413120,
"scriptDurationMs": 2585.6879999999996,
"eventListeners": -128,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.666666666666668,
"p95FrameDurationMs": 16.700000000000728
},
{
"name": "vue-large-graph-idle",
"durationMs": 18527.048000000035,
"styleRecalcs": 0,
"styleRecalcDurationMs": 0,
"layouts": 0,
"layoutDurationMs": 0,
"taskDurationMs": 17782.517,
"heapDeltaBytes": -32053348,
"heapUsedBytes": 178981496,
"domNodes": -6548,
"jsHeapTotalBytes": -1200128,
"scriptDurationMs": 332.94,
"eventListeners": -7473,
"totalBlockingTimeMs": 0,
"frameDurationMs": 17.776666666666642,
"p95FrameDurationMs": 16.799999999999272
},
{
"name": "vue-large-graph-idle",
"durationMs": 18642.64000000003,
"styleRecalcs": 0,
"styleRecalcDurationMs": 0,
"layouts": 0,
"layoutDurationMs": 0,
"taskDurationMs": 18179.921,
"heapDeltaBytes": -33551424,
"heapUsedBytes": 177188380,
"domNodes": -6548,
"jsHeapTotalBytes": -987136,
"scriptDurationMs": 312.78799999999995,
"eventListeners": -7473,
"totalBlockingTimeMs": 0,
"frameDurationMs": 17.776666666666642,
"p95FrameDurationMs": 16.799999999999272
},
{
"name": "vue-large-graph-pan",
"durationMs": 23183.33700000005,
"styleRecalcs": 179,
"styleRecalcDurationMs": 25.260000000000005,
"layouts": 0,
"layoutDurationMs": 0,
"taskDurationMs": 22904.811,
"heapDeltaBytes": -23317788,
"heapUsedBytes": 167185920,
"domNodes": -6548,
"jsHeapTotalBytes": 1777664,
"scriptDurationMs": 976.611,
"eventListeners": -7469,
"totalBlockingTimeMs": 190,
"frameDurationMs": 18.333333333333332,
"p95FrameDurationMs": 16.80000000000291
},
{
"name": "vue-large-graph-pan",
"durationMs": 23356.27599999998,
"styleRecalcs": 178,
"styleRecalcDurationMs": 23.214000000000013,
"layouts": 0,
"layoutDurationMs": 0,
"taskDurationMs": 22993.774,
"heapDeltaBytes": -20137584,
"heapUsedBytes": 183013516,
"domNodes": -6548,
"jsHeapTotalBytes": 5230592,
"scriptDurationMs": 928.666,
"eventListeners": -7469,
"totalBlockingTimeMs": 177,
"frameDurationMs": 17.780000000000047,
"p95FrameDurationMs": 16.80000000000291
},
{
"name": "vue-node-resize-workload",
"durationMs": 6620.033000000035,
"styleRecalcs": 20,
"styleRecalcDurationMs": 74.53300000000002,
"layouts": 20,
"layoutDurationMs": 25.540000000000006,
"taskDurationMs": 6548.558000000001,
"heapDeltaBytes": -19535796,
"heapUsedBytes": 177176248,
"domNodes": -6548,
"jsHeapTotalBytes": 13881344,
"scriptDurationMs": 124.32099999999998,
"eventListeners": -7471,
"totalBlockingTimeMs": 496,
"frameDurationMs": 17.779999999999987,
"p95FrameDurationMs": 16.700000000000728
},
{
"name": "vue-node-resize-workload",
"durationMs": 6590.604999999982,
"styleRecalcs": 20,
"styleRecalcDurationMs": 85.98100000000002,
"layouts": 20,
"layoutDurationMs": 35.79700000000001,
"taskDurationMs": 6517.33,
"heapDeltaBytes": -40654788,
"heapUsedBytes": 173433620,
"domNodes": -6548,
"jsHeapTotalBytes": -2138112,
"scriptDurationMs": 148.867,
"eventListeners": -7469,
"totalBlockingTimeMs": 501,
"frameDurationMs": 17.776666666666642,
"p95FrameDurationMs": 16.80000000000291
},
{
"name": "vue-zoom-out-idle",
"durationMs": 9282.908000000021,
"styleRecalcs": 0,
"styleRecalcDurationMs": 0,
"layouts": 0,
"layoutDurationMs": 0,
"taskDurationMs": 9056.310000000001,
"heapDeltaBytes": 6146656,
"heapUsedBytes": 176641368,
"domNodes": 0,
"jsHeapTotalBytes": 3407872,
"scriptDurationMs": 152.63100000000009,
"eventListeners": -12,
"totalBlockingTimeMs": 0,
"frameDurationMs": 17.779999999999927,
"p95FrameDurationMs": 16.80000000000291
},
{
"name": "vue-zoom-out-idle",
"durationMs": 9231.079999999907,
"styleRecalcs": 0,
"styleRecalcDurationMs": 0,
"layouts": 0,
"layoutDurationMs": 0,
"taskDurationMs": 8887.451000000003,
"heapDeltaBytes": 19386000,
"heapUsedBytes": 177061872,
"domNodes": 0,
"jsHeapTotalBytes": 262144,
"scriptDurationMs": 169.71000000000004,
"eventListeners": -14,
"totalBlockingTimeMs": 0,
"frameDurationMs": 17.776666666666642,
"p95FrameDurationMs": 16.80000000000291
},
{
"name": "workflow-execution",
"durationMs": 119.30400000005648,
"styleRecalcs": 7,
"styleRecalcDurationMs": 15.032,
"layouts": 3,
"layoutDurationMs": 1.724,
"taskDurationMs": 84.793,
"heapDeltaBytes": 3028476,
"heapUsedBytes": 70553496,
"domNodes": 125,
"jsHeapTotalBytes": 262144,
"scriptDurationMs": 7.089999999999999,
"eventListeners": 17,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.666666666666668,
"p95FrameDurationMs": 16.700000000000728
},
{
"name": "workflow-execution",
"durationMs": 96.8799999999419,
"styleRecalcs": 7,
"styleRecalcDurationMs": 11.964,
"layouts": 2,
"layoutDurationMs": 0.954,
"taskDurationMs": 68.66500000000002,
"heapDeltaBytes": 3010144,
"heapUsedBytes": 71747460,
"domNodes": 126,
"jsHeapTotalBytes": 524288,
"scriptDurationMs": 4.838,
"eventListeners": 17,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.666666666666668,
"p95FrameDurationMs": 16.699999999999818
}
]
}🔬 E2E Coverage
Top 10 files by uncovered lines
|
Codecov Report✅ All modified and coverable lines are covered by tests. @@ Coverage Diff @@
## main #16795 +/- ##
==========================================
+ Coverage 81.36% 82.91% +1.54%
==========================================
Files 2471 2050 -421
Lines 127186 119603 -7583
Branches 34630 31296 -3334
==========================================
- Hits 103490 99165 -4325
+ Misses 23181 20258 -2923
+ Partials 515 180 -335
Flags with carried forward coverage won't be shown. Click here to find out more.
... and 425 files with indirect coverage changes 🚀 New features to boost your workflow:
|
christian-byrne
left a comment
There was a problem hiding this comment.
- Ack for any pre-#8307 doc (lineage 0) is dropped: cloud omits
lineage_seqondoc_subscribed, FE parser rejects the frame. doc_resetparser drops the frame whenlineage_seq != seqinstead of trustinglineage_seq.- Lineage-stale frames are indistinguishable from seq-stale in
doc_stale; test helper hides the wire contract.
Full context for agent readers
Verified at head 380a6f1: pnpm test:unit src/workbench/extensions/agent/crdt green (27 files, 333 tests). Cross-checked against the cloud counterpart Comfy-Org/cloud#8307 at 853e36f.
The main issue is a contract asymmetry between this PR and #8307. On the cloud side DocUpdateFrame.LineageSeq and DocResetFrame.LineageSeq are serialized unconditionally, but DocSubscribedFrame.LineageSeq is tagged json:"lineage_seq,omitempty". The migration add_workflow_doc_lineage_seq adds the column as NOT NULL DEFAULT 0 and only Init (1) and Reseed (new seq) ever move it, so every workflow doc that exists before the deploy stays at lineage 0 until it is reseeded. For those docs the ack goes out without lineage_seq, this parser requires isNonNegativeInteger(data.lineage_seq) on every ok: true ack, parseServerDocFrame returns null, and DocFrameClient drops the frame without dispatching. Consequences: LayoutFollowerBridge.ackSeq stays null so catchUpPending is never armed and the gap detector only arms after the first live update; useAgentCrdtFollower.onSubscribed never runs, so connected stays false, armStaleProbe() is never called, and persistConfirmedDocId never persists the binding. Meanwhile the catch-up doc_update carries lineage_seq: 0 and is accepted, so the follower renders but the subscribe is never confirmed. The FE should treat a missing lineage_seq on an ok: true ack as 0 (still rejecting a present but non-integer or negative value); the cloud side could also drop omitempty, but the FE tolerance is what protects deploy-order skew either way.
Second, the doc_reset parser requires lineage_seq === seq. The cloud doc comment does say they are always equal, but a mismatch here drops the whole reset frame, which leaves the follower composing onto the old lineage until an implied break arrives via a newer-lineage doc_update. Accepting the frame and using lineage_seq as the lineage identity is fail-safe; dropping is fail-open. Left as a question because DQ-24 is the author's call.
Smaller points: newer-lineage doc_update triggers resubscribe() but newer-lineage ack does not, relying on the server having already sent full state because known_lineage_seq mismatched (confirmed in docwire.Resync); worth a comment since it is a contract dependency. dispatchStale reuses the {workflowId, seq} shape for lineage-stale frames so the dev panel cannot tell the two apart. The deliver() helper injects lineage_seq defaults so existing tests never exercise the real wire shape. The lineageSeq === undefined guard in onDocSubscribed is unreachable given the parser and returns without forwarding the ack event.
Not flagged: cold subscribe() sends known_lineage_seq: 0, which for lineage-0 docs matches and uses the (empty) state vector, and for others mismatches into full state; both paths produce the full doc, which is correct.
| frame.type === 'doc_reset' && | ||
| typeof data.seq === 'number' && | ||
| isNonNegativeInteger(data.lineage_seq) && | ||
| data.lineage_seq === data.seq |
There was a problem hiding this comment.
question: requiring lineage_seq === seq means a reset whose two fields disagree is dropped entirely, and the follower keeps composing onto the old lineage until an implied break shows up on a later doc_update. The cloud comment says they are always equal, so this is a belt-and-braces check, but dropping is the fail-open direction. Is the intent to reject a malformed reset, or would accepting the frame and using lineage_seq as the identity be safer for DQ-24?
There was a problem hiding this comment.
Confirmed: rejection is intentional. Cloud #8307 defines a reset as a mint event whose lineage_seq === seq; accepting disagreement would invent an ambiguous lineage identity. A later update from a newer valid lineage still triggers the implied-reset recovery path.
The server omits lineage_seq from the ack while a doc is still on the migration default lineage 0, so a missing field is lineage 0 rather than a malformed frame. Also carry the rejected frame's lineageSeq on doc_stale so lineage-stale and seq-stale frames stay distinguishable, and set lineage fields explicitly in the subscription test frames.
Full context for agent readersCommit ac6507a on this branch. Verified locally: Cross-repo note, not actioned here: cloud#8307 could drop |
|
Follow-up to the comment above: the first CI run on ac6507a failed typecheck because main had added two |
…4-fe-lineage-rejection # Conflicts: # src/workbench/extensions/agent/crdt/docFrameClient.ts
Keep the lineage identity contract on top of the stricter frame grammar: doc_update/doc_reset require lineage_seq (isSequence), doc_subscribed acks default an absent lineage_seq to the migration lineage 0 and reject a malformed one. Fixtures and grammar/numeric/array tests carry lineage_seq.
There was a problem hiding this comment.
🔍 Cursor Review — Consolidated panel
Triggered by @christian-byrne.
Found 9 finding(s).
| Severity | Count |
|---|---|
| 🟠 High | 2 |
| 🟡 Medium | 3 |
| 🟢 Low | 3 |
| ⚪ Nit | 1 |
Panel: 8/8 reviewers contributed findings.
|
Three-way landing order: smallest contract first, broad lineage hub last.
Full context for agent readersExact-head inspection found overlapping parser and follower-bridge hunks while every pull request still carries distinct behavior:
After each landing, re-read the next residual diff and rerun its focused parser/follower tests. Do not close a smaller pull request unless its live Glossary:
|
…ection Resolves the single conflict in src/workbench/extensions/agent/crdt/layoutFollowerBridge.ts, a comment in onDocUpdate's gap-detector block. Both sides changed the same line for different reasons: main renamed docs/adr/0024 to GRAPH-DOCUMENT-0024-graph-activation-and-document-objects-for-in-app-agent-targets.md and updated the citation to ADR-GRAPH-DOCUMENT-0024, while this branch changed the clause from "Only an explicit doc_reset may replace it" to "Only a newer lineage identity may replace it" because lineage identity is what this PR introduces as a replacement trigger. Taking either side alone is wrong: main's side restates the pre-lineage rule the branch supersedes, and the branch's side leaves ADR-0024 dangling (zero occurrences of that identifier remain anywhere on main). Kept the branch's semantics with main's identifier, wrapped to two lines for width.
|
Note GitHub couldn't provide a complete incremental comparison for this pull request, so CodeRabbit is performing a full review instead. This review may take a little longer. |
|
pr-shepherd stage 2 (conflict fix). This PR had been The conflict was a single line, a comment inside Everything else auto-merged, including Verification at the merged head on Node 25: Not merged, and no reviewer action requested here: |
DrJKL
left a comment
There was a problem hiding this comment.
Verdict: changes requested
I found one blocking integration regression against current main. The lineage behavior on this head is otherwise covered well: old-lineage frames are rejected before Y.Doc mutation and surfaced as doc_stale, malformed wire frames use reportError(), newer lineages replace the follower and cold-sync, and same-lineage gaps retain state-vector replay.
The branch has real conflicts in layoutFollowerBridge.ts and docFrameClient.numeric.test.ts. main added a fail-closed schema latch in the conflicting update path. I merged current main locally and selected the PR side of that conflict; followerSubscription.test.ts -t 'keeps the read gate closed until an explicit reset replaces the doc' failed because the compatible same-lineage update entered the already incompatible Y.Doc. The rebase needs to preserve the schema-error latch before lineage and sequence processing, while still allowing a newer lineage to recover through replacement. The merged reset fixtures also need the required lineage fields.
I ran the 34-file CRDT suite on this head, with 489 tests passing. Typecheck, ESLint on all nine changed files, and oxfmt also passed. All 77 completed non-skipped check runs for this SHA are green; 13 checks are skipped.
| const update = event.detail as DocUpdate | ||
| if (update.workflowId !== this.sentWorkflowId) return | ||
|
|
||
| if (this.lineageSeq !== null && update.lineageSeq < this.lineageSeq) { |
There was a problem hiding this comment.
Blocking: preserve main's if (this.schemaError !== null) return immediately after the workflow filter and before these lineage checks when resolving the current conflict. Without it, another same-lineage update mutates the Y.Doc after an incompatible frame has latched the read gate. I reproduced this by merging current main, taking the PR side here, and running followerSubscription.test.ts -t 'keeps the read gate closed until an explicit reset replaces the doc'; it failed at has('compatible'), receiving true instead of false. A newer valid lineage still recovers because replaceLineage() clears schemaError through dropDocForNewLineage().
|
Re-expressed onto main as #17498; base drift resolved as a graft (both sides kept). This PR can stay open for reference until #17498 lands. Full context for agent readers
|
DrJKL
left a comment
There was a problem hiding this comment.
Verdict: stacked
I confirmed that this work has been re-expressed onto current main as #17498 at c86713ea2f7db52004500021dc6ed514077cc78b. This original head remains conflicted and should stay as historical reference rather than land.
My previous blocker is addressed in the replacement. The graft keeps the schema-error latch after lineage comparison, so a newer lineage can replace the incompatible document while same-lineage updates remain blocked. It also merges cleanly with current main.
The replacement already has an unaddressed review finding for the missing cross-path regression test; I confirmed that finding by moving the latch ahead of lineage handling and observing all 40 follower-subscription tests still pass, so I am not duplicating it. I found no additional blocking behavior defect.
Two non-blocking replacement notes remain: the subscription test asserts a handwritten shape over parsed unknown[], and the #17498 description says every newer-lineage carrier resubscribes even though the newer doc_subscribed path deliberately accepts the full catch-up without another subscription. Its ADR-025, ADR-030, and phs-39 references also need stable links if reviewers are expected to verify them. These belong on #17498 rather than requiring updates to this historical branch.
Verified at the replacement head: 34 CRDT files / 498 tests passed; pnpm typecheck, changed-file ESLint, pnpm adr:check, and git merge-tree --write-tree origin/main c86713e passed. Maintainability finding: none. The original head still has 77 successful and 13 skipped checks, with none pending or failed.
|
Cross-ref: adjudication of the |
DrJKL
left a comment
There was a problem hiding this comment.
Verdict: stacked
I agree with the new sequence ruling that a successful doc_subscribed acknowledgement with absent or zero seq is valid. There is still one mismatch in the claimed baseline semantics. The bridge stores explicit zero as ackSeq = 0, but stores an absent sequence as ackSeq = null. A focused test that delivered an absent-sequence acknowledgement followed by the first update at sequence 2 failed: the bridge projected that update instead of detecting the missing sequence 1 and resubscribing. The two wire forms therefore do not behave as the same baseline 0. PR #17611 pins both forms as valid, but its bridge test only follows them with sequence 1, so it does not catch this case. Please normalize the absent successful acknowledgement to the same internal baseline as explicit zero without treating malformed values as zero, and add the sequence-2 falsifier before this stack lands.
This original head remains conflicted and should stay as historical reference. The replacement in #17498 now addresses the prior schema-latch test gap in 26dfd6d. Its current checks are not all green: 75 passed, 15 skipped, and 3 failed. The original head has 77 passed and 15 skipped checks.
I reran the original head against its frozen dependencies: all 34 CRDT files and 489 tests passed, along with typecheck, changed-file ESLint, and formatting. git merge-tree --write-tree origin/main HEAD still reports conflicts in docFrameClient.numeric.test.ts and layoutFollowerBridge.ts. Maintainability finding: the unchecked handwritten subscription-frame cast remains the previously reported item; I found no additional maintainability issue.
| workflowId: string | ||
| ok: boolean | ||
| seq?: number | ||
| lineageSeq?: number |
There was a problem hiding this comment.
[P2] A successful parsed acknowledgement always has a validated lineageSeq, including the migration default of 0, but this interface makes it optional for both success and failure. That permits successful internal frames the parser can never produce and forces LayoutFollowerBridge to repeat ?? 0. Please model DocSubscribed as a union keyed by ok, with lineageSeq required for ok: true, then use that normalized value directly downstream.
…ne (Comfy-Org#17611) Pins the settled follower contract for `doc_subscribed` acks with a zero or absent `seq`: they are a valid baseline-0 subscription, not a malformed ack. Tests only; no runtime change. Decision (from adjudication on Comfy-Org#16452): `doc_subscribed ok:true` with `seq` absent or `0` means "subscribed at baseline 0". The follower stays subscribed, sends no `doc_unsubscribe`, and issues a single `doc_subscribe`. FEC-1 fail-closed applies to `doc_update` seq gaps only. Why this matters: the cloud relay marshals `DocSubscribedFrame.Seq` with `omitempty`, so a successful seq-0 ack arrives on the wire with `seq` absent. Treating that as malformed (as Comfy-Org#16452 currently does) would make the follower unsubscribe from every freshly created doc. ## Evidence - Cloud `common/websocket/messages/crdt.go:256-265` — `DocSubscribedFrame{Seq int64 \`json:"seq,omitempty"\`}`; seq 0 is dropped from the JSON. - Cloud `services/agent/server/doc_handler.go:111-130,147-159` — unminted doc accepted at seq 0 (intentional). - FE `docFrameClient.ts:198-200,307-320` (main) — `isSequence` accepts 0; parser keeps seq 0 and omits absent seq. - FE `layoutFollowerBridge.ts:365-374` (main) — `ackSeq = subscribed.seq ?? null; catchUpPending = ackSeq !== null`. - Adjudication comment on Comfy-Org#16452: Comfy-Org#16452 (comment) - Cross-reference on Comfy-Org#16795: Comfy-Org#16795 (comment) - Vitest: `docFrameClient.test.ts` + `followerSubscription.test.ts` — 2 files, 43 tests passed. Landing order: Comfy-Org#16452 should adopt this contract (drop the seq-0 strip and the `malformed_ack` retry on absent seq); Comfy-Org#16795 rebases after. <!-- authored-by:agent role-hard-problem --> --------- Co-authored-by: Benjamin Lu <benjaminlu1107@gmail.com>
|
Closing: this branch implements replaced-lineage rejection in the ECS adapter. The ECS materializer / If the behaviour this PR fixed still reproduces against the new applier, it needs a fresh fix against Context: FE-3387 (Agent/CRDT alignment programme) and the open-PR survey of 2026-10-22 (thread). Posted for DrJKL. |
Stale lineages dropped pre-mutation.
Missed resets force cold sync.
Cloud #8307 carries sender contract.
Full context for agent readers
Summary
Implements Christian's selected durable
lineage_seqcontract from blocked-on-christian #236. The follower now binds every accepted update to the active document lineage rather than trusting sequence alone.Changes
doc_update, successfuldoc_subscribed, anddoc_resetknown_lineage_seqon every subscribeReview focus
FollowerDoc.applyRemoteUpdateknown_lineage_seqdiffersEvidence
pnpm test:unit src/workbench/extensions/agent/crdt/followerSubscription.test.ts -t 'rejects a delayed update from the replaced lineage before mutating the fresh doc'— failed withupdatesApplied1, expected 0pnpm test:unit src/workbench/extensions/agent/crdt— 27 files, 333 tests passedpnpm typecheck— passedpnpm knip --cachepassed