Repository navigation
[backport cloud/1.58] fix(agent): gate canvas-affecting claims on observed canvas state (PM-1343, PM-1996, PM-1586) - #21966
Conversation
Consumes PM-1637 terminal tool-call correlation to keep an agent tool row in its visible syncing state until every named graph operation has applied to the matching workflow. Uncorrelated frames retain the existing bounded fallback for a rolling cloud/frontend deployment. A matching doc update that arrives before the terminal frame still settles immediately. - `pnpm exec vitest run src/workbench/extensions/agent/schemas/agentApiSchema.test.ts src/workbench/extensions/agent/services/agent/agentEventTransport.test.ts src/workbench/extensions/agent/crdt/useAgentCrdtFollower.test.ts` - `pnpm typecheck:browser` - `PLAYWRIGHT_SETUP_API_URL=https://testcloud.comfy.org DISTRIBUTION=cloud PLAYWRIGHT_TEST_URL=http://localhost:5173 pnpm test:browser:local browser_tests/tests/agent/agentCanvasLagsToolCallCompletion.spec.ts --project=cloud` (4 passed) Cloud producer: Comfy-Org/cloud@main...oploop-802b:oploop-802b/pm1637-tool-call-scope Resolves PM-1637 (cherry picked from commit 454b1cd)
…-1343, PM-1996, PM-1586) (#20741) PM-1343, PM-1996, and PM-1586 share one user-visible failure: the agent reports successful canvas work while the canvas is empty or unchanged. This PR makes the browser enforce two claims independently: - A successful canvas-mutating tool reads as confirmed only when the operations it names are observed on that workflow through the follower path. - When a completed turn claims canvas content but the active bound canvas is still empty, the panel says so explicitly. The server result and browser observation remain separate. A tool can report success while its canvas effect is still pending or cannot be confirmed. Built on main's op-id correlation for terminal tool frames (#21369, cloud producer Comfy-Org/cloud#14329): - **Correlated frames** (`workflow_id` + `op_ids`): confirmed only when every named op has applied to that workflow; a timeout or a canvas that cannot observe the write reads "not confirmed". - **Uncorrelated frames** (rolling deploy, `doc_reset`): released by any live frame applied since the turn started, **without a claim**, because the follower's `appliedLive` counter cannot say which workflow or which write a frame belonged to. Denied ("not confirmed") only when no live frame arrives within the 30 s bound. The shared count is never consumed by one write, so a frame that carried two writes releases both. - **Unavailable canvas** (follower refused or terminal, bound tab not active, or the frame names another workflow): reads "not confirmed" immediately. - The canvas gate returns `none | awaiting | unavailable`; follower refusal uses its typed terminal state. - The empty-canvas notice reads node count from `graphChanged` events, so it follows the rendered graph rather than a stale snapshot. - Successful pending and hydrated mutating calls stay out of the plain "Worked" state. - Canvas tool classification and the unconfirmed-write predicate are shared across the summary, trace, glyph, and transcript paths. - Browser proof uses the real agent event socket and the shared `AgentRemoteApplyHarness`. - Agent unit suites (`src/workbench/extensions/agent`, 176 files): 4,004 pass; one unrelated `useAgentSession` backoff-timer test failed while Playwright ran alongside and passed 3/3 on its own. - New transport regressions for the two reopened findings fail on `b655b3c` and pass here: a live frame of another workflow no longer confirms an uncorrelated write, and one frame carrying two uncorrelated writes no longer denies the second. - Black-box (`--project=cloud`, local backend): `agentCanvasClaimNeedsObservation` 2/2, `agentCanvasLagsToolCallCompletion` 5/5, `agentRefusedDocSubscribe` 2/2, plus `agentGraphOpLostOnDisconnect`, `agentSchemaSkewTellsTheUser`, `agentZeroNodesOnUnreadableSchema`, `agentToolCallHistoryPersistence` 4/4. - `pnpm typecheck:browser`, commit hooks (oxlint type-aware, ESLint, server-facts, `typecheck:app`), and pre-push gates (dependency-cruiser, knip, fallow) pass. - An uncorrelated write that never lands still reads as plain "Worked" when some other live frame arrived during the turn. The empty-canvas notice still catches the empty-tab case. This path shrinks as the cloud producer's correlated frames roll out; `doc_reset` stays uncorrelated by design. - A `get_template` or `generate_workflow` call that leaves the workflow unchanged still reports `success`, but cloud mints no op for it (`commitSkippedNoWrite`), so its frame carries no `op_ids` and is handled as uncorrelated. With no other live frame in the turn, it reads "Changes not confirmed on your canvas" after the 30 s bound. This errs toward not claiming a write. - No changed spec takes an element screenshot of the new visual states. This does not repair a failed delivery path or change the semantic document protocol. It makes an unobserved canvas write honest in the UI and preserves the browser-observable invariant while delivery remains a separate investigation. Five files sit outside the Agent review globs (`src/locales/en/main.json`, `oxlint-suppressions.json`, and three `browser_tests/fixtures/` harness files), so this needs one `comfy_frontend_devs` approval in addition to the Agent-path owners. --------- Co-authored-by: Alexander Brown <drjkl@comfy.org> (cherry picked from commit 08b4792)
|
Important Review skippedIgnore keyword(s) in the title. ⛔ Ignored keywords: 2
Please check the settings in the CodeRabbit UI or the
|
📦 Bundle Size
⚡ Performance Report
Scenario timings
Absolute values
Raw data{
"timestamp": "2026-10-26T09:32:57.016Z",
"gitSha": "10354ea956110a3e8fe1a1fb2f2657350d28deaf",
"branch": "backport-20741-to-cloud-1.58",
"measurements": [
{
"name": "canvas-idle",
"durationMs": 2027.557999999999,
"styleRecalcs": 11,
"styleRecalcDurationMs": 2.676,
"layouts": 10,
"layoutDurationMs": 2.2680000000000002,
"taskDurationMs": 264.007,
"heapDeltaBytes": 2277464,
"heapUsedBytes": 93382212,
"domNodes": -200,
"jsHeapTotalBytes": 1368064,
"scriptDurationMs": 7.458000000000001,
"eventListeners": -130,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.666393442622947,
"p95FrameDurationMs": 16.700000000000728
},
{
"name": "canvas-idle",
"durationMs": 2025.594999999953,
"styleRecalcs": 10,
"styleRecalcDurationMs": 2.7860000000000005,
"layouts": 9,
"layoutDurationMs": 2.3939999999999992,
"taskDurationMs": 411.00800000000004,
"heapDeltaBytes": 1513728,
"heapUsedBytes": 92023196,
"domNodes": -200,
"jsHeapTotalBytes": 2678784,
"scriptDurationMs": 10.451,
"eventListeners": -130,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.664754098360653,
"p95FrameDurationMs": 16.799999999999727
},
{
"name": "canvas-mouse-sweep",
"durationMs": 1693.915000000004,
"styleRecalcs": 71,
"styleRecalcDurationMs": 13.152000000000001,
"layouts": 10,
"layoutDurationMs": 2.4389999999999996,
"taskDurationMs": 636.807,
"heapDeltaBytes": -23776364,
"heapUsedBytes": 80989344,
"domNodes": -200,
"jsHeapTotalBytes": 2428928,
"scriptDurationMs": 111.604,
"eventListeners": -130,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.665686274509806,
"p95FrameDurationMs": 16.700000000000273
},
{
"name": "canvas-mouse-sweep",
"durationMs": 1709.713000000022,
"styleRecalcs": 71,
"styleRecalcDurationMs": 14.305000000000001,
"layouts": 11,
"layoutDurationMs": 2.884,
"taskDurationMs": 736.2620000000001,
"heapDeltaBytes": -18037460,
"heapUsedBytes": 86342508,
"domNodes": -180,
"jsHeapTotalBytes": 2428928,
"scriptDurationMs": 125.01399999999998,
"eventListeners": -130,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.665048543689316,
"p95FrameDurationMs": 16.700000000000273
},
{
"name": "canvas-zoom-sweep",
"durationMs": 1708.202999999969,
"styleRecalcs": 18,
"styleRecalcDurationMs": 4.106,
"layouts": 12,
"layoutDurationMs": 2.5820000000000003,
"taskDurationMs": 257.988,
"heapDeltaBytes": -560352,
"heapUsedBytes": 98114768,
"domNodes": 47,
"jsHeapTotalBytes": 7602176,
"scriptDurationMs": 9.021,
"eventListeners": 37,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.666019417475727,
"p95FrameDurationMs": 16.799999999999272
},
{
"name": "canvas-zoom-sweep",
"durationMs": 1708.6790000000178,
"styleRecalcs": 18,
"styleRecalcDurationMs": 4.015000000000001,
"layouts": 11,
"layoutDurationMs": 2.367,
"taskDurationMs": 240.838,
"heapDeltaBytes": -1250164,
"heapUsedBytes": 89016192,
"domNodes": 47,
"jsHeapTotalBytes": 7864320,
"scriptDurationMs": 8.908,
"eventListeners": 37,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.666990291262135,
"p95FrameDurationMs": 16.700000000000273
},
{
"name": "dom-widget-clipping",
"durationMs": 532.7310000000125,
"styleRecalcs": 13,
"styleRecalcDurationMs": 2.759,
"layouts": 9,
"layoutDurationMs": 2.2709999999999995,
"taskDurationMs": 339.343,
"heapDeltaBytes": 6958164,
"heapUsedBytes": 111579988,
"domNodes": 0,
"jsHeapTotalBytes": 7864320,
"scriptDurationMs": 110.845,
"eventListeners": 0,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.665625000000006,
"p95FrameDurationMs": 16.700000000000273
},
{
"name": "dom-widget-clipping",
"durationMs": 583.389000000011,
"styleRecalcs": 15,
"styleRecalcDurationMs": 3.297,
"layouts": 11,
"layoutDurationMs": 2.9819999999999993,
"taskDurationMs": 395.932,
"heapDeltaBytes": 8528092,
"heapUsedBytes": 108710532,
"domNodes": 0,
"jsHeapTotalBytes": 11534336,
"scriptDurationMs": 115.081,
"eventListeners": 0,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.665714285714277,
"p95FrameDurationMs": 16.799999999999727
},
{
"name": "dom-widget-order-dense-n200-w200-i120",
"durationMs": 936.7249999999956,
"styleRecalcs": 0,
"styleRecalcDurationMs": 0,
"layouts": 0,
"layoutDurationMs": 0,
"taskDurationMs": 584.018,
"heapDeltaBytes": 1673052,
"heapUsedBytes": 102440016,
"domNodes": -231,
"jsHeapTotalBytes": 9502720,
"scriptDurationMs": 39.394999999999996,
"eventListeners": -168,
"totalBlockingTimeMs": 284,
"frameDurationMs": 25.922222222222217,
"p95FrameDurationMs": 16.800000000000182
},
{
"name": "dom-widget-order-dense-n200-w200-i120",
"durationMs": 926.7449999999826,
"styleRecalcs": 0,
"styleRecalcDurationMs": 0,
"layouts": 0,
"layoutDurationMs": 0,
"taskDurationMs": 555.096,
"heapDeltaBytes": -15203140,
"heapUsedBytes": 102407172,
"domNodes": -230,
"jsHeapTotalBytes": 15269888,
"scriptDurationMs": 40.514,
"eventListeners": -168,
"totalBlockingTimeMs": 295,
"frameDurationMs": 26.665714285714277,
"p95FrameDurationMs": 16.800000000000182
},
{
"name": "dom-widget-order-sparse-n1000-w20-i120",
"durationMs": 703.2739999999933,
"styleRecalcs": 0,
"styleRecalcDurationMs": 0,
"layouts": 0,
"layoutDurationMs": 0,
"taskDurationMs": 267.7369999999999,
"heapDeltaBytes": -2802408,
"heapUsedBytes": 98012260,
"domNodes": 0,
"jsHeapTotalBytes": 0,
"scriptDurationMs": 95.96100000000001,
"eventListeners": 0,
"totalBlockingTimeMs": 92,
"frameDurationMs": 20.591176470588245,
"p95FrameDurationMs": 16.800000000000182
},
{
"name": "dom-widget-order-sparse-n1000-w20-i120",
"durationMs": 717.6389999999628,
"styleRecalcs": 0,
"styleRecalcDurationMs": 0,
"layouts": 0,
"layoutDurationMs": 0,
"taskDurationMs": 300.5809999999998,
"heapDeltaBytes": -4903712,
"heapUsedBytes": 97126728,
"domNodes": 0,
"jsHeapTotalBytes": 0,
"scriptDurationMs": 99.49200000000002,
"eventListeners": 0,
"totalBlockingTimeMs": 97,
"frameDurationMs": 21.079411764705878,
"p95FrameDurationMs": 16.800000000000182
},
{
"name": "extension-clean-combined-draw",
"durationMs": 7171.143000000001,
"styleRecalcs": 4,
"styleRecalcDurationMs": 1.2799999999999998,
"layouts": 4,
"layoutDurationMs": 1.0969999999999995,
"taskDurationMs": 6171.958,
"heapDeltaBytes": 26872048,
"heapUsedBytes": 140311140,
"domNodes": -276,
"jsHeapTotalBytes": 17715200,
"scriptDurationMs": 4581.34,
"eventListeners": -130,
"totalBlockingTimeMs": 175,
"frameDurationMs": 22.186687306501547,
"p95FrameDurationMs": 33.400000000000546
},
{
"name": "extension-clean-combined-draw",
"durationMs": 6396.40300000002,
"styleRecalcs": 2,
"styleRecalcDurationMs": 0.6830000000000005,
"layouts": 2,
"layoutDurationMs": 0.6079999999999997,
"taskDurationMs": 5144.021000000001,
"heapDeltaBytes": 35798988,
"heapUsedBytes": 144884164,
"domNodes": -296,
"jsHeapTotalBytes": 31252480,
"scriptDurationMs": 4037.973,
"eventListeners": -130,
"totalBlockingTimeMs": 24,
"frameDurationMs": 19.874844720496895,
"p95FrameDurationMs": 33.30000000000109
},
{
"name": "extension-rgthree-prototype-draw",
"durationMs": 6576.107000000007,
"styleRecalcs": 3,
"styleRecalcDurationMs": 0.8510000000000002,
"layouts": 3,
"layoutDurationMs": 0.8109999999999996,
"taskDurationMs": 5545.818,
"heapDeltaBytes": 9082996,
"heapUsedBytes": 132855048,
"domNodes": -276,
"jsHeapTotalBytes": 22183936,
"scriptDurationMs": 4174.757,
"eventListeners": -130,
"totalBlockingTimeMs": 100,
"frameDurationMs": 20.204615384615384,
"p95FrameDurationMs": 33.399999999999636
},
{
"name": "extension-rgthree-prototype-draw",
"durationMs": 6485.503999999992,
"styleRecalcs": 4,
"styleRecalcDurationMs": 1.2530000000000006,
"layouts": 4,
"layoutDurationMs": 1.0579999999999998,
"taskDurationMs": 5607.358,
"heapDeltaBytes": 16460936,
"heapUsedBytes": 139356744,
"domNodes": -296,
"jsHeapTotalBytes": 29167616,
"scriptDurationMs": 4230.956,
"eventListeners": -130,
"totalBlockingTimeMs": 33,
"frameDurationMs": 21.201311475409838,
"p95FrameDurationMs": 33.399999999999636
},
{
"name": "large-combo-open",
"durationMs": 163.1919999999809,
"styleRecalcs": 22,
"styleRecalcDurationMs": 12.493999999999998,
"layouts": 13,
"layoutDurationMs": 3.45,
"taskDurationMs": 119.16499999999999,
"heapDeltaBytes": -3741620,
"heapUsedBytes": 101866172,
"domNodes": 917,
"jsHeapTotalBytes": 6029312,
"scriptDurationMs": 6.103000000000001,
"eventListeners": 196,
"totalBlockingTimeMs": 0,
"frameDurationMs": 21.428571428571427,
"p95FrameDurationMs": 33.30000000000018
},
{
"name": "large-combo-open",
"durationMs": 136.8669999999952,
"styleRecalcs": 21,
"styleRecalcDurationMs": 12.326,
"layouts": 12,
"layoutDurationMs": 3.0949999999999998,
"taskDurationMs": 102.30200000000002,
"heapDeltaBytes": 13330984,
"heapUsedBytes": 118810996,
"domNodes": 917,
"jsHeapTotalBytes": 786432,
"scriptDurationMs": 6.144,
"eventListeners": 196,
"totalBlockingTimeMs": 0,
"frameDurationMs": 18.762500000000045,
"p95FrameDurationMs": 33.29999999999973
},
{
"name": "large-graph-idle",
"durationMs": 2042.061000000018,
"styleRecalcs": 9,
"styleRecalcDurationMs": 2.6570000000000005,
"layouts": 9,
"layoutDurationMs": 2.4139999999999997,
"taskDurationMs": 438.37,
"heapDeltaBytes": -910948,
"heapUsedBytes": 102046012,
"domNodes": -296,
"jsHeapTotalBytes": -2813952,
"scriptDurationMs": 27.253,
"eventListeners": -130,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.665853658536587,
"p95FrameDurationMs": 16.700000000000728
},
{
"name": "large-graph-idle",
"durationMs": 2025.686999999948,
"styleRecalcs": 10,
"styleRecalcDurationMs": 2.798,
"layouts": 9,
"layoutDurationMs": 2.2189999999999994,
"taskDurationMs": 413.49600000000004,
"heapDeltaBytes": -21453972,
"heapUsedBytes": 90968560,
"domNodes": -296,
"jsHeapTotalBytes": -2195456,
"scriptDurationMs": 26.701000000000004,
"eventListeners": -130,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.6655737704918,
"p95FrameDurationMs": 16.700000000000728
},
{
"name": "large-graph-pan",
"durationMs": 2228.4720000000107,
"styleRecalcs": 69,
"styleRecalcDurationMs": 10.485999999999999,
"layouts": 8,
"layoutDurationMs": 1.9819999999999998,
"taskDurationMs": 1159.9569999999999,
"heapDeltaBytes": -2433632,
"heapUsedBytes": 108670420,
"domNodes": -297,
"jsHeapTotalBytes": -503808,
"scriptDurationMs": 539.378,
"eventListeners": -128,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.665671641791043,
"p95FrameDurationMs": 16.700000000000728
},
{
"name": "large-graph-pan",
"durationMs": 2100.1549999999725,
"styleRecalcs": 69,
"styleRecalcDurationMs": 10.593,
"layouts": 9,
"layoutDurationMs": 2.433,
"taskDurationMs": 1036.4170000000001,
"heapDeltaBytes": 1875700,
"heapUsedBytes": 113523100,
"domNodes": -296,
"jsHeapTotalBytes": 20480,
"scriptDurationMs": 567.601,
"eventListeners": -128,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.665873015873014,
"p95FrameDurationMs": 16.700000000000273
},
{
"name": "large-graph-zoom",
"durationMs": 3256.110000000007,
"styleRecalcs": 74,
"styleRecalcDurationMs": 12.517999999999997,
"layouts": 68,
"layoutDurationMs": 12.767000000000001,
"taskDurationMs": 1274.6109999999999,
"heapDeltaBytes": -16425380,
"heapUsedBytes": 96473192,
"domNodes": -272,
"jsHeapTotalBytes": 188416,
"scriptDurationMs": 554.152,
"eventListeners": -130,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.66581632653061,
"p95FrameDurationMs": 16.799999999999272
},
{
"name": "large-graph-zoom",
"durationMs": 3336.312000000021,
"styleRecalcs": 73,
"styleRecalcDurationMs": 10.936000000000002,
"layouts": 66,
"layoutDurationMs": 11.054000000000002,
"taskDurationMs": 1241.4040000000002,
"heapDeltaBytes": -1881244,
"heapUsedBytes": 104268396,
"domNodes": -272,
"jsHeapTotalBytes": -1110016,
"scriptDurationMs": 520.64,
"eventListeners": -130,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.665499999999998,
"p95FrameDurationMs": 16.799999999999272
},
{
"name": "legacy-node-drag",
"durationMs": 3059.4179999999938,
"styleRecalcs": 47,
"styleRecalcDurationMs": 7.007999999999999,
"layouts": 7,
"layoutDurationMs": 1.7409999999999994,
"taskDurationMs": 1558.848,
"heapDeltaBytes": -9886908,
"heapUsedBytes": 104615476,
"domNodes": 0,
"jsHeapTotalBytes": 7081984,
"scriptDurationMs": 745.8489999999999,
"eventListeners": 182,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.756830601092897,
"p95FrameDurationMs": 16.799999999999272
},
{
"name": "legacy-node-drag",
"durationMs": 2238.0599999999617,
"styleRecalcs": 47,
"styleRecalcDurationMs": 6.090000000000001,
"layouts": 7,
"layoutDurationMs": 1.601,
"taskDurationMs": 1193.363,
"heapDeltaBytes": -11621460,
"heapUsedBytes": 102447200,
"domNodes": 0,
"jsHeapTotalBytes": 6819840,
"scriptDurationMs": 604.81,
"eventListeners": 182,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.665925925925922,
"p95FrameDurationMs": 16.700000000000728
},
{
"name": "minimap-idle",
"durationMs": 2037.7200000000357,
"styleRecalcs": 9,
"styleRecalcDurationMs": 2.001,
"layouts": 9,
"layoutDurationMs": 1.78,
"taskDurationMs": 407.63899999999995,
"heapDeltaBytes": -727348,
"heapUsedBytes": 103679520,
"domNodes": -296,
"jsHeapTotalBytes": -2551808,
"scriptDurationMs": 20.535,
"eventListeners": -130,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.6655737704918,
"p95FrameDurationMs": 16.799999999999727
},
{
"name": "minimap-idle",
"durationMs": 2052.5900000000092,
"styleRecalcs": 10,
"styleRecalcDurationMs": 2.038,
"layouts": 10,
"layoutDurationMs": 1.9300000000000002,
"taskDurationMs": 390.3430000000001,
"heapDeltaBytes": 299392,
"heapUsedBytes": 113031420,
"domNodes": -296,
"jsHeapTotalBytes": -1253376,
"scriptDurationMs": 23.782999999999994,
"eventListeners": -130,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.665853658536587,
"p95FrameDurationMs": 16.799999999999272
},
{
"name": "subgraph-dom-widget-clipping",
"durationMs": 412.59600000000773,
"styleRecalcs": 47,
"styleRecalcDurationMs": 5.303000000000001,
"layouts": 10,
"layoutDurationMs": 2.5300000000000002,
"taskDurationMs": 283.947,
"heapDeltaBytes": 21157536,
"heapUsedBytes": 111549500,
"domNodes": 0,
"jsHeapTotalBytes": 3670016,
"scriptDurationMs": 96.842,
"eventListeners": 46,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.667999999999992,
"p95FrameDurationMs": 16.799999999999727
},
{
"name": "subgraph-dom-widget-clipping",
"durationMs": 415.9440000000245,
"styleRecalcs": 48,
"styleRecalcDurationMs": 5.397000000000001,
"layouts": 10,
"layoutDurationMs": 2.3629999999999995,
"taskDurationMs": 256.14300000000003,
"heapDeltaBytes": -1476828,
"heapUsedBytes": 89856932,
"domNodes": 0,
"jsHeapTotalBytes": 7077888,
"scriptDurationMs": 94.774,
"eventListeners": 46,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.667999999999992,
"p95FrameDurationMs": 16.700000000000273
},
{
"name": "subgraph-idle",
"durationMs": 2026.046000000008,
"styleRecalcs": 10,
"styleRecalcDurationMs": 2.903,
"layouts": 10,
"layoutDurationMs": 2.574,
"taskDurationMs": 356.114,
"heapDeltaBytes": 2672268,
"heapUsedBytes": 93990260,
"domNodes": -222,
"jsHeapTotalBytes": 1536000,
"scriptDurationMs": 6.565000000000001,
"eventListeners": -176,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.665573770491804,
"p95FrameDurationMs": 16.700000000000273
},
{
"name": "subgraph-idle",
"durationMs": 2008.9039999999727,
"styleRecalcs": 11,
"styleRecalcDurationMs": 3.769999999999999,
"layouts": 11,
"layoutDurationMs": 3.1249999999999996,
"taskDurationMs": 402.13500000000005,
"heapDeltaBytes": 4471228,
"heapUsedBytes": 106354464,
"domNodes": 0,
"jsHeapTotalBytes": 7602176,
"scriptDurationMs": 10.327000000000002,
"eventListeners": 0,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.66611570247934,
"p95FrameDurationMs": 16.700000000000273
},
{
"name": "subgraph-mouse-sweep",
"durationMs": 1694.184000000007,
"styleRecalcs": 75,
"styleRecalcDurationMs": 12.326000000000002,
"layouts": 10,
"layoutDurationMs": 2.3199999999999994,
"taskDurationMs": 578.495,
"heapDeltaBytes": -22793132,
"heapUsedBytes": 83813380,
"domNodes": -210,
"jsHeapTotalBytes": 2166784,
"scriptDurationMs": 78.821,
"eventListeners": -174,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.66666666666667,
"p95FrameDurationMs": 16.799999999999727
},
{
"name": "subgraph-mouse-sweep",
"durationMs": 1694.2589999999882,
"styleRecalcs": 75,
"styleRecalcDurationMs": 12.216999999999999,
"layouts": 9,
"layoutDurationMs": 1.917,
"taskDurationMs": 487.82399999999996,
"heapDeltaBytes": 217668,
"heapUsedBytes": 91362652,
"domNodes": -210,
"jsHeapTotalBytes": 2416640,
"scriptDurationMs": 77.40499999999999,
"eventListeners": -174,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.66666666666666,
"p95FrameDurationMs": 16.799999999999727
},
{
"name": "subgraph-transition-enter",
"durationMs": 882.2969999999941,
"styleRecalcs": 19,
"styleRecalcDurationMs": 17.496,
"layouts": 5,
"layoutDurationMs": 10.326,
"taskDurationMs": 676.3019999999999,
"heapDeltaBytes": 7126376,
"heapUsedBytes": 120349108,
"domNodes": 16030,
"jsHeapTotalBytes": 17702912,
"scriptDurationMs": 21.418000000000006,
"eventListeners": 3244,
"totalBlockingTimeMs": 90,
"frameDurationMs": 20.075000000000003,
"p95FrameDurationMs": 33.30000000000018
},
{
"name": "viewport-pan-sweep",
"durationMs": 8754.176000000001,
"styleRecalcs": 250,
"styleRecalcDurationMs": 37.691,
"layouts": 9,
"layoutDurationMs": 2.485,
"taskDurationMs": 4241.426,
"heapDeltaBytes": -33052900,
"heapUsedBytes": 89096180,
"domNodes": -297,
"jsHeapTotalBytes": -585728,
"scriptDurationMs": 1960.143,
"eventListeners": -128,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.666095238095235,
"p95FrameDurationMs": 16.700000000000728
},
{
"name": "viewport-pan-sweep",
"durationMs": 8152.76399999999,
"styleRecalcs": 251,
"styleRecalcDurationMs": 34.26,
"layouts": 10,
"layoutDurationMs": 5.3629999999999995,
"taskDurationMs": 3260.57,
"heapDeltaBytes": 2377984,
"heapUsedBytes": 112608448,
"domNodes": -296,
"jsHeapTotalBytes": -503808,
"scriptDurationMs": 1736.37,
"eventListeners": -128,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.700204918032785,
"p95FrameDurationMs": 16.799999999999272
},
{
"name": "vue-large-graph-idle",
"durationMs": 14737.432000000012,
"styleRecalcs": 0,
"styleRecalcDurationMs": 0,
"layouts": 0,
"layoutDurationMs": 0,
"taskDurationMs": 13874.775000000001,
"heapDeltaBytes": -11464624,
"heapUsedBytes": 298716968,
"domNodes": -3344,
"jsHeapTotalBytes": 19124224,
"scriptDurationMs": 170.70300000000003,
"eventListeners": -653,
"totalBlockingTimeMs": 0,
"frameDurationMs": 24.844350758853288,
"p95FrameDurationMs": 50
},
{
"name": "vue-large-graph-idle",
"durationMs": 15443.302000000018,
"styleRecalcs": 0,
"styleRecalcDurationMs": 0,
"layouts": 0,
"layoutDurationMs": 0,
"taskDurationMs": 14623.881000000001,
"heapDeltaBytes": -44552652,
"heapUsedBytes": 285916308,
"domNodes": -3344,
"jsHeapTotalBytes": 27250688,
"scriptDurationMs": 191.919,
"eventListeners": -653,
"totalBlockingTimeMs": 0,
"frameDurationMs": 26.052951096121415,
"p95FrameDurationMs": 50
},
{
"name": "vue-large-graph-pan",
"durationMs": 18012.021000000004,
"styleRecalcs": 141,
"styleRecalcDurationMs": 17.063000000000024,
"layouts": 0,
"layoutDurationMs": 0,
"taskDurationMs": 17658.96,
"heapDeltaBytes": -24636292,
"heapUsedBytes": 281502968,
"domNodes": -3344,
"jsHeapTotalBytes": 6017024,
"scriptDurationMs": 644.133,
"eventListeners": -651,
"totalBlockingTimeMs": 0,
"frameDurationMs": 33.83245778611633,
"p95FrameDurationMs": 66.70000000000073
},
{
"name": "vue-large-graph-pan",
"durationMs": 17552.497000000018,
"styleRecalcs": 150,
"styleRecalcDurationMs": 15.470999999999998,
"layouts": 0,
"layoutDurationMs": 0,
"taskDurationMs": 17160.043,
"heapDeltaBytes": 5134124,
"heapUsedBytes": 315984776,
"domNodes": -3344,
"jsHeapTotalBytes": 35377152,
"scriptDurationMs": 602.791,
"eventListeners": -651,
"totalBlockingTimeMs": 0,
"frameDurationMs": 32.34972375690608,
"p95FrameDurationMs": 66.70000000000073
},
{
"name": "vue-node-resize-workload",
"durationMs": 4451.13200000003,
"styleRecalcs": 20,
"styleRecalcDurationMs": 43.92299999999999,
"layouts": 20,
"layoutDurationMs": 21.33299999999999,
"taskDurationMs": 4309.259,
"heapDeltaBytes": 14903952,
"heapUsedBytes": 316859540,
"domNodes": -3344,
"jsHeapTotalBytes": 35115008,
"scriptDurationMs": 73.406,
"eventListeners": -653,
"totalBlockingTimeMs": 0,
"frameDurationMs": 26.175882352941173,
"p95FrameDurationMs": 50.100000000000364
},
{
"name": "vue-node-resize-workload",
"durationMs": 5284.279999999967,
"styleRecalcs": 20,
"styleRecalcDurationMs": 42.45399999999999,
"layouts": 20,
"layoutDurationMs": 18.11900000000001,
"taskDurationMs": 5166.741999999999,
"heapDeltaBytes": -30776452,
"heapUsedBytes": 280126348,
"domNodes": -307,
"jsHeapTotalBytes": 24891392,
"scriptDurationMs": 71.72300000000001,
"eventListeners": -7,
"totalBlockingTimeMs": 0,
"frameDurationMs": 32.019393939393936,
"p95FrameDurationMs": 66.60000000000036
},
{
"name": "vue-zoom-out-idle",
"durationMs": 8113.047999999992,
"styleRecalcs": 0,
"styleRecalcDurationMs": 0,
"layouts": 0,
"layoutDurationMs": 0,
"taskDurationMs": 7638.045000000002,
"heapDeltaBytes": -11354940,
"heapUsedBytes": 286868836,
"domNodes": 0,
"jsHeapTotalBytes": 0,
"scriptDurationMs": 103.41899999999998,
"eventListeners": 0,
"totalBlockingTimeMs": 0,
"frameDurationMs": 28.12395833333333,
"p95FrameDurationMs": 50.100000000000364
},
{
"name": "vue-zoom-out-idle",
"durationMs": 7599.671999999941,
"styleRecalcs": 0,
"styleRecalcDurationMs": 0,
"layouts": 0,
"layoutDurationMs": 0,
"taskDurationMs": 7247.167000000001,
"heapDeltaBytes": 76668,
"heapUsedBytes": 272954428,
"domNodes": 0,
"jsHeapTotalBytes": 0,
"scriptDurationMs": 92.169,
"eventListeners": 0,
"totalBlockingTimeMs": 0,
"frameDurationMs": 26.387847222222224,
"p95FrameDurationMs": 50
},
{
"name": "workflow-execution",
"durationMs": 92.158999999981,
"styleRecalcs": 8,
"styleRecalcDurationMs": 8.413,
"layouts": 6,
"layoutDurationMs": 2.4450000000000003,
"taskDurationMs": 71.09800000000001,
"heapDeltaBytes": 4977160,
"heapUsedBytes": 107282984,
"domNodes": 124,
"jsHeapTotalBytes": 524288,
"scriptDurationMs": 9.426999999999998,
"eventListeners": 1,
"totalBlockingTimeMs": 0,
"frameDurationMs": 20,
"p95FrameDurationMs": 33.29999999999973
},
{
"name": "workflow-execution",
"durationMs": 90.3409999999667,
"styleRecalcs": 8,
"styleRecalcDurationMs": 6.485,
"layouts": 6,
"layoutDurationMs": 1.9389999999999998,
"taskDurationMs": 51.759,
"heapDeltaBytes": 4650576,
"heapUsedBytes": 97401436,
"domNodes": 117,
"jsHeapTotalBytes": 0,
"scriptDurationMs": 4.151000000000001,
"eventListeners": 1,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.666666666666668,
"p95FrameDurationMs": 16.799999999999727
},
{
"name": "agent-composer-empty-conversation-typing",
"durationMs": 203.4320000000207,
"styleRecalcs": 5,
"styleRecalcDurationMs": 0.637,
"layouts": 76,
"layoutDurationMs": 9.754000000000001,
"taskDurationMs": 161.51399999999998,
"heapDeltaBytes": 9454892,
"heapUsedBytes": 97601148,
"domNodes": 4,
"jsHeapTotalBytes": 9437184,
"scriptDurationMs": 68.511,
"eventListeners": 292,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.669230769230754,
"p95FrameDurationMs": 16.700000000000273
},
{
"name": "agent-composer-empty-conversation-typing",
"durationMs": 198.8020000000006,
"styleRecalcs": 5,
"styleRecalcDurationMs": 0.593,
"layouts": 76,
"layoutDurationMs": 9.709000000000001,
"taskDurationMs": 157.012,
"heapDeltaBytes": 9265920,
"heapUsedBytes": 96812464,
"domNodes": 4,
"jsHeapTotalBytes": 8912896,
"scriptDurationMs": 66.60199999999999,
"eventListeners": 292,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.658333333333342,
"p95FrameDurationMs": 16.699999999999818
},
{
"name": "agent-composer-long-conversation-typing",
"durationMs": 224.0399999999454,
"styleRecalcs": 5,
"styleRecalcDurationMs": 1.274,
"layouts": 76,
"layoutDurationMs": 9.341999999999999,
"taskDurationMs": 192.373,
"heapDeltaBytes": -2304464,
"heapUsedBytes": 114406612,
"domNodes": 4,
"jsHeapTotalBytes": 1048576,
"scriptDurationMs": 62.242,
"eventListeners": 292,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.666666666666696,
"p95FrameDurationMs": 16.800000000000182
},
{
"name": "agent-composer-long-conversation-typing",
"durationMs": 229.50299999990875,
"styleRecalcs": 5,
"styleRecalcDurationMs": 1.238,
"layouts": 76,
"layoutDurationMs": 9.565000000000001,
"taskDurationMs": 194.743,
"heapDeltaBytes": -2290260,
"heapUsedBytes": 114521204,
"domNodes": 4,
"jsHeapTotalBytes": 1572864,
"scriptDurationMs": 64.301,
"eventListeners": 292,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.659999999999975,
"p95FrameDurationMs": 16.700000000000273
}
]
}🔬 E2E Coverage
🎭 Playwright: ✅ 2976 passed, 0 failed · 1 flaky📊 Browser Reports
🎨 Storybook: ✅ Built — View Storybook🧩 Custom Nodes Ecosystem Matrix: 🟡 Withheld — could not measureExecutes the frontend JS of every registry pack that ships any, against this change, in both renderers. The eight
Findings and check detailsThe matrix runs on same-repository version-bump PRs with relevant changes, main-branch pushes, and manual dispatches. This candidate does not qualify, so every expensive stage was skipped. Reproduce locally# build one shard's fixture, then run it
python3 scripts/registry-census/build_matrix.py --shard 1/4
MATRIX_RENDERER=vue MATRIX_VUE=1 \
npx vitest run --config vitest.matrix.config.mts
Full docs: scripts/registry-census/README.md 🌾 Fallow: ✅ PassedFallow audits the diff for duplication, complexity and dead code. It gates on new findings only, so when the audit completes, a red is something this PR introduced or moved — never inherited backlog. A red can also mean the audit itself did not finish; the details below say which happened. Findings and check detailsNo new findings in the changed files. Reproduce locally# the base the gate compared against
npx fallow audit --root . --quiet --format json \
--changed-since 19113ee5d36f3c21f384d090e1391f4cbe34ab02
Full docs: ADR-DEVEX-LINT-0015 🏛️ Architecture: ✅ PassedFindings and check detailsWarnings (122)
Reproduce locallypnpm architecture:checkFull docs: Frontend domain catalog |
Codecov Report❌ Patch coverage is @@ Coverage Diff @@
## cloud/1.58 #21966 +/- ##
=============================================
Coverage ? 85.79%
=============================================
Files ? 2590
Lines ? 134983
Branches ? 38790
=============================================
Hits ? 115814
Misses ? 18752
Partials ? 417
Flags with carried forward coverage won't be shown. Click here to find out more.
🚀 New features to boost your workflow:
|
This comment has been minimized.
This comment has been minimized.
christian-byrne
left a comment
There was a problem hiding this comment.
Release-backport review at exact head 8f50e96c7e900d9c09a9a1d77ec498bbf071b24d, base cloud/1.58@19113ee5d36f.
- Diff matches its
mainsources; only import paths and the three stated 1.58 adaptations differ. - Required checks green. The one shard-6 failure was an unrelated mask-editor screenshot; it passed on rerun.
- Merging under the release-backport grant. GitHub does not let an author approve their own PR, so this is a COMMENT review.
Full context for agent readers
Authority. This merge is covered by the Agent release-backport grant for cloud/1.58, recorded in program/active-authority.md and program/release-backport-authority.md of christian-byrne/in-app-agent-program. Under that grant, a REVIEW_REQUIRED status does not by itself require a human approval. An unresolved human objection would still block the merge, and there are none.
Diff review. I ran git range-diff for each carrier commit against its main squash source:
b869476a30against454b1cd71e(#21369): the only differences are relative import paths and diff context.8f50e96c7eagainst08b4792346(#20741): the differences are import paths plus three adaptations, each stated in the PR body:RunNoticeBannergets only theemptyCanvascontext, becausegenericNoticeReadydoes not exist on 1.58.- The
AgentPaneltest carries only #20741's own empty-canvas case. agentToolCallHistoryPersistenceuses a two-rowTRACE, because this branch's trace has no thinking rows.
I also checked the follower's terminal state, which was the release-resolution defect found on the 1.57 carrier #21917. It is present here:
SubscribeGiveUpReason = 'refused' | 'timeout'.- The lifecycle give-up callback sets
terminalto that reason. canvasConfirmationState()returnsunavailablefor any non-null terminal state.useAgentCrdtFollower.test.tsassertsterminal === 'timeout'.
So when subscribe acknowledgements time out, a successful mutating tool call cannot settle as plain "Worked".
Black-box proof is not weakened. This head adds agentCanvasClaimNeedsObservation.spec.ts. In agentRefusedDocSubscribe, agentZeroNodesOnUnreadableSchema and agentGraphOpLostOnDisconnect, the old "the node shows up" assertions become "the change is reported unconfirmed". On the unfixed source (src/ reset to origin/cloud/1.58), the same specs failed 7 of 10, with the visible text reading "Worked" where it should read "Changes not confirmed on your canvas". At this head they pass 13 of 13 locally and in hosted playwright-tests (cloud).
Hosted CI at this head.
lint-and-format,testande2e-status(all required) passed.- The first attempt of run 40299144845 failed
playwright-tests-chromium-sharded (6, 16)on one test,maskEditor.spec.ts:142(mask-editor-dialog-from-context-menu.png, a 40-pixel difference, all retries). This PR does not touch the mask editor. The rerun (attempt 2, job 121536131184) passed all 143 tests with 0 flaky. upload-e2e-coverage / packageis red. It is not a required check. The cause is lcov rejecting a duplicateinner_clickedrecord insrc/lib/litegraph/src/LGraphCanvas.ts, a file this PR does not touch. The same failure appears on mergedcloud/1.58carriers #21895 and #21872, and #21879 is the open fix for it on this branch.
Gate state. MERGEABLE, base unchanged, no review threads, no human objections.
…rved canvas state (PM-1343, PM-1996, PM-1586) (#22062) ## ELI5 Adds the "don't say Worked unless the canvas shows it" check to the core 1.58 line. Cloud 1.57, Cloud 1.58 and core 1.57 already have it; core 1.58 was missed. ## Summary Clean cherry-pick of the cloud/1.58 carrier #21966 (`f6994bfd0d`), itself a backport of #21369 and #20741. No conflicts; `core/1.58` and `cloud/1.58` share this code. - Ticket: PM-2072 (also PM-1343, PM-1996, PM-1586) - Siblings: #21917 (cloud/1.57), #21918 (core/1.57), #21966 (cloud/1.58) <details><summary>Full context for agent readers</summary> - `core/1.58` vs `main` merge `08b4792346` (#20741): diverged, not contained. Without this PR the next core 1.58 patch ships the panel without the observed-canvas gate. - Local at this head (Node 26.12.1): `pnpm typecheck` green; `vitest run src/workbench/extensions/agent` 175 files, 4019 passed, 1 expected fail. - Runnable proof travels with it: `browser_tests/tests/agent/agentCanvasClaimNeedsObservation.spec.ts` (CI E2E). </details> Co-authored-by: Alexander Brown <drjkl@comfy.org>
…Comfy-Org#22791) ## Summary After a reload or reopening a chat from history, every finished Agent turn read "Changes not confirmed on your canvas", although the same turn read "Worked" live and its edits are on the canvas. Restored turns now read "Worked" again, as on 1.59.0.dev2. Fixes [FRONT-3803](https://linear.app/comfyorg/issue/FRONT-3803). <details><summary>Full context for agent readers</summary> **Cause.** Comfy-Org#20741 (`08b4792346`, the only canvas-claim change between 1.59.0.dev2 `864bfc939e` and 1.60.0.dev1 `9b73bee0a5`) made `parseToolCallEntry` in `agentTranscript.ts` set `canvasConfirmed: false` on every successful canvas-mutating call read from a stored row. A stored row carries no browser observation, so after a reload nothing could ever confirm those calls. `preserveCanvasConfirmation` upgraded them back only for calls the same page session had confirmed live, which is why in-session turns kept "Worked" until the reload. Comfy-Org#20741 flipped `agentToolCallHistoryPersistence.spec.ts` to expect the unconfirmed label; this PR flips it back. **Fix.** - `agentTranscript.ts`: a stored row makes no canvas claim (no `canvasConfirmed`). - `agentConversationStore.ts`: when a turn settles in the session that ran it, the verdict its live calls reached carries onto the stored row, **true or false** (previously true only, because stored rows defaulted to false). Applied on both settle paths: the socket reconcile (`reconcileSettledTurn`) and the recovery read (`settleTurn`). Without the second one, a live denial settled by the recovery read would now drop to "Worked". This is the canvas half of [FRONT-3757](https://linear.app/comfyorg/issue/FRONT-3757); its tab-link half is unchanged. - A call still waiting for canvas catch-up when its turn settles is stored as not confirmed, which is the same verdict the transport's flush records. A verdict moves onto a stored tool only when the tool names match (review round 1). - Live behaviour from Comfy-Org#20741 is unchanged: unobserved, timed-out or unavailable-canvas writes still read "not confirmed" live and after settle in that session. Only a restored row, which never had an observation, stops claiming one. No reconcile pass, no new store writes; this is display state on the message parts only (KEEP-ALIVE Comfy-Org#14 untouched). **Backport.** Comfy-Org#20741 is on `core/1.60`, `cloud/1.60`, `core/1.59`, `cloud/1.59` natively and was backported to `core/1.58` (Comfy-Org#22062) and `cloud/1.58` (Comfy-Org#21966). The frontend pin decision needs `core/1.60`; labels are set for all six lines. </details> ## Verification - Black-box: `browser_tests/tests/agent/agentToolCallHistoryPersistence.spec.ts` (reload, then reopen from history) restored to expect "Worked" with no unconfirmed marker. **Red on parent `a8c2ace17f`** (summary reads "Changes not confirmed on your canvas"), **green on this branch** (rerun at `2d96033bfc`). - Related canvas-claim specs, `--project=cloud`, local backend: `agentCanvasClaimNeedsObservation`, `agentCanvasLagsToolCallCompletion`, `agentRefusedDocSubscribe`, `agentGraphOpLostOnDisconnect`, `agentSchemaSkewTellsTheUser`, `agentZeroNodesOnUnreadableSchema`, `agentToolCallHistoryPersistence`: 15/15 pass. - Unit: store cases cover the live verdict (confirmed, denied, still pending) through both settle paths, plus a name-mismatch guard; each fails without the change that it covers. Agent suites: 194 files, 4914 pass. `pnpm typecheck`, `typecheck:browser`, oxlint, eslint, oxfmt pass via hooks.
Backport of #21369 and #20741 to
cloud/1.58, the declared Cloud release line (frontend-version.jsonreleaseBranch). Same paircloud/1.57already carries as #21917 (merge1f0d5e900a).Why
PM-2072: the panel can say Worked while the canvas stays empty. The fix is on
cloud/1.57but not oncloud/1.58, so a canvas cut from the release line would ship without it.How it was built
Cherry-picks of the
mainsquash merges454b1cd71eand08b4792346(not the 1.57 carrier). That bringsmain's full terminal follower state, includingtimeout, which #21917 and #21918 had to restore after review. Conflicts were import paths, plus three adaptations to this branch:RunNoticeBanner.vue: added only theemptyCanvascontext. This branch has nogenericNoticeReady.AgentPanel.test.ts: added only fix(agent): gate canvas-affecting claims on observed canvas state (PM-1343, PM-1996, PM-1586) #20741's empty-canvas test. The other conflicting tests belong to a run-notice feature that is not on this branch.agentToolCallHistoryPersistence.spec.ts: this branch's trace has no thinking rows, soTRACEis the two tool rows. Same adaptation as [backport cloud/1.57] fix(agent): gate canvas-affecting claims on observed canvas state (PM-1343, PM-1996, PM-1586) #21917.Verification
api.logs.test.ts: 176 files, 4,021 passed, 1 expected fail.typecheck:appandtypecheck:browserclean.--project=cloud, local backend: six changed Agent specs, 13/13 pass at this head.cloud/1.58source, using this branch's specs and locale strings: 7 failed.agentRefusedDocSubscribe"reports a canvas edit as unconfirmed" received "Worked".