Repository navigation
[backport cloud/1.58] fix(agent): empty composer on New Chat, keep the draft across a refresh (#21588, #22821) - #22944
Conversation
New Chat now starts with an empty composer. Before, it retargeted to the tab on screen (PM-1321) but kept the unsent draft, so text written about workflow A followed the user into a new chat on workflow B. **Design call for review:** this reverses one part of #18693, which deliberately carried the draft (and its node references, with their original target) through New Chat. PM-2251 and the original PM-1321 acceptance both ask for an empty composer, so the two cannot both hold. Needs a yes/no from the agent UI owner before merge. Fixes PM-2251 <details><summary>Full context</summary> - `agentComposerStore.clearDraft()` resets text, references (workflow, node, asset, skill), attachments, insertion point and prompt origin. - `AgentPanelRoot.onNewChat()` calls it instead of only clearing workflow references, and always resumes following the visible workflow. The old `retainWorkflowTarget()` branch existed only for node references carried by the draft; none survive now. | Case | Before | After | | --- | --- | --- | | Unsent text, switch tab, New Chat | text kept, now aimed at the new tab | empty composer, follows the new tab | | Unsent text with node references, New Chat | draft and chips kept, target stays on the original workflow | empty composer, follows the visible tab | | Fresh chat, switch tabs (no New Chat) | draft kept while following | unchanged | | Switch chats via history | draft kept | unchanged (not in PM-2251's acceptance; flagged there as worth a separate look) | Three `AgentPanelRoot.test.ts` cases asserted the carry-through; they now assert the empty composer. The node-reference case now asserts the chip is dropped and the target follows the tab on screen. - Browser harness, `agentNewChatTargetWorkflow.spec.ts` PM-1322 case extended to leave an unsent draft before switching tabs: - parent `606fbc634c`: fails at `expect(composer).toHaveText('')`, received `Only edit workflow A`; PM-1415 control passes - this branch: 2/2 pass. The spec attaches before/after New Chat screenshots to the CI report; after shows the placeholder and target `Unsaved Workflow (2)`. - Adjacent agent specs that press New Chat (10 files, 21 tests): all pass locally on cloud distribution. - `vitest run src/workbench/extensions/agent/`: 178 files, 4037 passed. - `pnpm typecheck`, eslint, oxfmt, pre-push knip/fallow: clean. - PM-1321 / PM-1322: same QA case; target half fixed in #18196. - PM-2002 (draft lost on refresh) pulls the other way on the same state. This PR does not add draft persistence. </details> (cherry picked from commit 5d8e08b)
Refreshing the page no longer wipes an unsent Agent chat draft. The draft comes back in the same chat after a reload; New Chat and a successful send still clear it. - Restored: typed text and workflow `@` mentions. - Not restored: attachments (in-memory blobs, they would come back as broken thumbnails), node mentions (tied to a tab instance), and skill mentions (tied to the skill-pack scope loaded at runtime). They are dropped; the text stays. - Keeps #21588: `clearDraft()` on New Chat clears the saved draft, so it does not come back after a reload. Fixes PM-2002 - New black-box spec `browser_tests/tests/agent/agentComposerDraftSurvivesReload.spec.ts`: type a draft, reload, the composer shows it; New Chat, reload, the composer is empty with its placeholder. **Red on `main`** (`Expected: "Make the background a sunset over the ocean"`, `Received: ""`), **green on this branch**. - A version that kept the draft after New Chat fails the spec's second step. - Unit tests in `agentComposerStore.test.ts` cover what the browser case cannot reach: no restore into a different chat, node mentions and attachments dropped, the saved draft forgotten after send and after `clearDraft()`, and a malformed saved draft discarded without breaking the composer. Each one fails against a specific wrong implementation. - Also ran `agentNewChatTargetWorkflow.spec.ts` and `agentChatRefreshPersistence.spec.ts`: green. `pnpm typecheck`, `typecheck:browser` and lint are clean. <details><summary>Full context for agent readers</summary> - `agentComposerStore` keeps the draft in `localStorage` under `StorageKeys.agentComposerDraft(workspaceId)` as `{ threadId, text, workflowReferences }`. It writes `null` once the draft is empty, so a send (`startSubmission`) or New Chat (`clearDraft`) removes it. - Nothing is written until `AgentPanelRoot` reports the open chat through `trackDraftThread(threadId)`. That call is registered right after `useAgentSession.start()`, which has already moved `threadId` to the chat being restored (`Comfy.Agent.ThreadId:*`). This prevents the empty composer on a fresh page load from overwriting the draft before it is restored. - The first `trackDraftThread` call restores the saved draft only if its `threadId` matches the open chat (a new chat with no thread matches `null`) and the composer is empty. Later calls retag the saved draft to whichever chat the composer is in, so it matches what the user sees in memory. - The restore goes through the existing `replaceDraft()` / `snapshotReferences()` path with `attachments: []`. - The saved value is parsed with a zod schema before restoring. A wrong shape (for example `null` text) is removed from localStorage and nothing is restored, so a bad entry cannot throw on every panel start. - `clearAllWorkspaceStorage()` now also clears `Comfy.Agent.ComposerDraft:*`, matching the other per-workspace Agent keys. `src/platform/workflow/persistence/base/storageKeys.ts` and `storageIO.ts` are owned only by `@Comfy-Org/comfy_frontend_devs`, so the program-owned route does not apply. Assigned to @dante01yoon. - A draft that is mid-send when the page reloads is not restored. The send already cleared it, and a failed send restores it in memory only. - If the restored thread fails to hydrate and the session falls back to a new chat, the draft stays in the composer (retagged to the new chat). This matches how the in-memory draft already behaves when you switch chats. </details> (cherry picked from commit 70046f1)
|
Important Review skippedIgnore keyword(s) in the title. ⛔ Ignored keywords: 2
Please check the settings in the CodeRabbit UI or the
|
📦 Bundle: ⏳ Size data collection in progress…⚡ Performance: ❌ 8 below 52 FPS target · ℹ️ No baseline — significance unavailable
DetailsScenario timings
Absolute values
Raw data{
"timestamp": "2026-11-05T01:02:52.775Z",
"gitSha": "5f55732ed72f9764364b32553d26440382f30f4c",
"branch": "backport-21588-to-cloud-1.58",
"measurements": [
{
"name": "canvas-idle",
"durationMs": 2008.2209999999918,
"styleRecalcs": 10,
"styleRecalcDurationMs": 3.0849999999999995,
"layouts": 10,
"layoutDurationMs": 2.6220000000000003,
"taskDurationMs": 283.274,
"heapDeltaBytes": 4953172,
"heapUsedBytes": 92977876,
"domNodes": -180,
"jsHeapTotalBytes": -3506176,
"scriptDurationMs": 7.8820000000000014,
"eventListeners": -130,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.66528925619835,
"p95FrameDurationMs": 16.799999999999727
},
{
"name": "canvas-idle",
"durationMs": 2026.1340000000132,
"styleRecalcs": 10,
"styleRecalcDurationMs": 2.8269999999999995,
"layouts": 9,
"layoutDurationMs": 2.327,
"taskDurationMs": 374.417,
"heapDeltaBytes": -3027472,
"heapUsedBytes": 86071608,
"domNodes": -200,
"jsHeapTotalBytes": 950272,
"scriptDurationMs": 8.258000000000001,
"eventListeners": -130,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.666393442622947,
"p95FrameDurationMs": 16.799999999999272
},
{
"name": "canvas-mouse-sweep",
"durationMs": 1710.6279999999856,
"styleRecalcs": 71,
"styleRecalcDurationMs": 11.999,
"layouts": 10,
"layoutDurationMs": 2.395,
"taskDurationMs": 597.0709999999999,
"heapDeltaBytes": -5500896,
"heapUsedBytes": 83441700,
"domNodes": -201,
"jsHeapTotalBytes": -1671168,
"scriptDurationMs": 103.218,
"eventListeners": -130,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.666019417475727,
"p95FrameDurationMs": 16.700000000000728
},
{
"name": "canvas-mouse-sweep",
"durationMs": 1695.8480000000122,
"styleRecalcs": 71,
"styleRecalcDurationMs": 11.913,
"layouts": 10,
"layoutDurationMs": 2.391,
"taskDurationMs": 528.468,
"heapDeltaBytes": -3269564,
"heapUsedBytes": 86302824,
"domNodes": -201,
"jsHeapTotalBytes": -360448,
"scriptDurationMs": 102.537,
"eventListeners": -130,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.665686274509806,
"p95FrameDurationMs": 16.799999999999727
},
{
"name": "canvas-zoom-sweep",
"durationMs": 1704.823000000033,
"styleRecalcs": 18,
"styleRecalcDurationMs": 4.465,
"layouts": 12,
"layoutDurationMs": 2.7549999999999994,
"taskDurationMs": 191.56700000000004,
"heapDeltaBytes": 21570320,
"heapUsedBytes": 109904792,
"domNodes": 47,
"jsHeapTotalBytes": 2621440,
"scriptDurationMs": 9.37,
"eventListeners": 37,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.666019417475727,
"p95FrameDurationMs": 16.700000000000728
},
{
"name": "canvas-zoom-sweep",
"durationMs": 1709.9249999999984,
"styleRecalcs": 18,
"styleRecalcDurationMs": 4.130999999999999,
"layouts": 12,
"layoutDurationMs": 2.5120000000000005,
"taskDurationMs": 228.223,
"heapDeltaBytes": 22855736,
"heapUsedBytes": 112173400,
"domNodes": 47,
"jsHeapTotalBytes": 3932160,
"scriptDurationMs": 7.248999999999999,
"eventListeners": 37,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.66504854368932,
"p95FrameDurationMs": 16.799999999999727
},
{
"name": "dom-widget-clipping",
"durationMs": 516.0539999999969,
"styleRecalcs": 15,
"styleRecalcDurationMs": 3.2049999999999996,
"layouts": 10,
"layoutDurationMs": 2.7270000000000003,
"taskDurationMs": 327.90200000000004,
"heapDeltaBytes": 2779304,
"heapUsedBytes": 105790712,
"domNodes": 0,
"jsHeapTotalBytes": 3670016,
"scriptDurationMs": 108.571,
"eventListeners": 0,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.664516129032254,
"p95FrameDurationMs": 16.800000000000182
},
{
"name": "dom-widget-clipping",
"durationMs": 433.69200000000774,
"styleRecalcs": 14,
"styleRecalcDurationMs": 3.14,
"layouts": 10,
"layoutDurationMs": 2.5669999999999997,
"taskDurationMs": 279.991,
"heapDeltaBytes": -664776,
"heapUsedBytes": 88205852,
"domNodes": 0,
"jsHeapTotalBytes": 3407872,
"scriptDurationMs": 105.531,
"eventListeners": 0,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.669230769230772,
"p95FrameDurationMs": 16.800000000000182
},
{
"name": "dom-widget-order-dense-n200-w200-i120",
"durationMs": 963.6150000000043,
"styleRecalcs": 0,
"styleRecalcDurationMs": 0,
"layouts": 0,
"layoutDurationMs": 0,
"taskDurationMs": 568.2479999999999,
"heapDeltaBytes": -13822916,
"heapUsedBytes": 102584932,
"domNodes": -230,
"jsHeapTotalBytes": 15376384,
"scriptDurationMs": 42.418,
"eventListeners": -168,
"totalBlockingTimeMs": 318,
"frameDurationMs": 26.852777777777785,
"p95FrameDurationMs": 16.800000000000182
},
{
"name": "dom-widget-order-dense-n200-w200-i120",
"durationMs": 951.4720000000239,
"styleRecalcs": 0,
"styleRecalcDurationMs": 0,
"layouts": 0,
"layoutDurationMs": 0,
"taskDurationMs": 552.056,
"heapDeltaBytes": -13033224,
"heapUsedBytes": 102812568,
"domNodes": -210,
"jsHeapTotalBytes": 16424960,
"scriptDurationMs": 54.994,
"eventListeners": -168,
"totalBlockingTimeMs": 293,
"frameDurationMs": 26.38888888888889,
"p95FrameDurationMs": 16.800000000000182
},
{
"name": "dom-widget-order-sparse-n1000-w20-i120",
"durationMs": 701.9289999999785,
"styleRecalcs": 0,
"styleRecalcDurationMs": 0,
"layouts": 0,
"layoutDurationMs": 0,
"taskDurationMs": 293.66800000000023,
"heapDeltaBytes": -3564192,
"heapUsedBytes": 97953624,
"domNodes": 0,
"jsHeapTotalBytes": 0,
"scriptDurationMs": 92.687,
"eventListeners": 0,
"totalBlockingTimeMs": 86,
"frameDurationMs": 20.58823529411765,
"p95FrameDurationMs": 16.800000000000182
},
{
"name": "dom-widget-order-sparse-n1000-w20-i120",
"durationMs": 687.0499999999993,
"styleRecalcs": 0,
"styleRecalcDurationMs": 0,
"layouts": 0,
"layoutDurationMs": 0,
"taskDurationMs": 272.0259999999999,
"heapDeltaBytes": -4473968,
"heapUsedBytes": 97200952,
"domNodes": 0,
"jsHeapTotalBytes": 0,
"scriptDurationMs": 86.623,
"eventListeners": 0,
"totalBlockingTimeMs": 81,
"frameDurationMs": 20.09411764705882,
"p95FrameDurationMs": 16.800000000000182
},
{
"name": "extension-clean-combined-draw",
"durationMs": 5437.398999999999,
"styleRecalcs": 3,
"styleRecalcDurationMs": 0.758,
"layouts": 3,
"layoutDurationMs": 0.7209999999999999,
"taskDurationMs": 4592.823,
"heapDeltaBytes": 25632736,
"heapUsedBytes": 129563740,
"domNodes": -296,
"jsHeapTotalBytes": 15958016,
"scriptDurationMs": 3604.28,
"eventListeners": -130,
"totalBlockingTimeMs": 0,
"frameDurationMs": 17.414102564102564,
"p95FrameDurationMs": 16.800000000000182
},
{
"name": "extension-clean-combined-draw",
"durationMs": 6440.254999999979,
"styleRecalcs": 3,
"styleRecalcDurationMs": 0.6879999999999994,
"layouts": 3,
"layoutDurationMs": 0.6280000000000001,
"taskDurationMs": 5363.919,
"heapDeltaBytes": 25917724,
"heapUsedBytes": 147319232,
"domNodes": -276,
"jsHeapTotalBytes": 33193984,
"scriptDurationMs": 4055.01,
"eventListeners": -130,
"totalBlockingTimeMs": 36,
"frameDurationMs": 19.025958702064898,
"p95FrameDurationMs": 33.399999999999636
},
{
"name": "extension-rgthree-prototype-draw",
"durationMs": 6074.663000000015,
"styleRecalcs": 3,
"styleRecalcDurationMs": 1.7140000000000002,
"layouts": 3,
"layoutDurationMs": 1.005,
"taskDurationMs": 4955.636,
"heapDeltaBytes": 8148636,
"heapUsedBytes": 129422120,
"domNodes": -276,
"jsHeapTotalBytes": 29523968,
"scriptDurationMs": 3922.293,
"eventListeners": -130,
"totalBlockingTimeMs": 40,
"frameDurationMs": 19.879411764705882,
"p95FrameDurationMs": 33.399999999999636
},
{
"name": "extension-rgthree-prototype-draw",
"durationMs": 6435.153000000014,
"styleRecalcs": 2,
"styleRecalcDurationMs": 0.4550000000000005,
"layouts": 2,
"layoutDurationMs": 0.392,
"taskDurationMs": 5261.292,
"heapDeltaBytes": 37623640,
"heapUsedBytes": 141870836,
"domNodes": -296,
"jsHeapTotalBytes": 29368320,
"scriptDurationMs": 4030.538,
"eventListeners": -130,
"totalBlockingTimeMs": 16,
"frameDurationMs": 20.05125,
"p95FrameDurationMs": 33.399999999999636
},
{
"name": "large-combo-open",
"durationMs": 140.80400000000282,
"styleRecalcs": 21,
"styleRecalcDurationMs": 10.235999999999999,
"layouts": 12,
"layoutDurationMs": 2.68,
"taskDurationMs": 97.71400000000001,
"heapDeltaBytes": 13221916,
"heapUsedBytes": 117994184,
"domNodes": 917,
"jsHeapTotalBytes": 524288,
"scriptDurationMs": 5.587,
"eventListeners": 196,
"totalBlockingTimeMs": 0,
"frameDurationMs": 19.042857142857105,
"p95FrameDurationMs": 33.29999999999973
},
{
"name": "large-combo-open",
"durationMs": 144.08800000001065,
"styleRecalcs": 22,
"styleRecalcDurationMs": 11.498,
"layouts": 11,
"layoutDurationMs": 2.7099999999999995,
"taskDurationMs": 103.46800000000002,
"heapDeltaBytes": 13248312,
"heapUsedBytes": 114690600,
"domNodes": 917,
"jsHeapTotalBytes": 524288,
"scriptDurationMs": 5.923,
"eventListeners": 196,
"totalBlockingTimeMs": 0,
"frameDurationMs": 18.75,
"p95FrameDurationMs": 33.30000000000018
},
{
"name": "large-graph-idle",
"durationMs": 2025.7249999999658,
"styleRecalcs": 10,
"styleRecalcDurationMs": 2.8280000000000007,
"layouts": 9,
"layoutDurationMs": 2.456,
"taskDurationMs": 461.929,
"heapDeltaBytes": -24390908,
"heapUsedBytes": 95734008,
"domNodes": -296,
"jsHeapTotalBytes": -1343488,
"scriptDurationMs": 29.123,
"eventListeners": -130,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.665573770491804,
"p95FrameDurationMs": 16.700000000000728
},
{
"name": "large-graph-idle",
"durationMs": 2025.981999999999,
"styleRecalcs": 9,
"styleRecalcDurationMs": 2.81,
"layouts": 9,
"layoutDurationMs": 2.351,
"taskDurationMs": 396.581,
"heapDeltaBytes": -15140880,
"heapUsedBytes": 90583060,
"domNodes": -296,
"jsHeapTotalBytes": -2392064,
"scriptDurationMs": 21.275000000000002,
"eventListeners": -130,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.665573770491804,
"p95FrameDurationMs": 16.799999999999272
},
{
"name": "large-graph-pan",
"durationMs": 2684.883999999954,
"styleRecalcs": 70,
"styleRecalcDurationMs": 11.100999999999999,
"layouts": 10,
"layoutDurationMs": 2.562,
"taskDurationMs": 1243.0400000000002,
"heapDeltaBytes": -33261128,
"heapUsedBytes": 87962272,
"domNodes": -296,
"jsHeapTotalBytes": 491520,
"scriptDurationMs": 570.4800000000001,
"eventListeners": -128,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.665625,
"p95FrameDurationMs": 16.700000000000728
},
{
"name": "large-graph-pan",
"durationMs": 2130.3100000000086,
"styleRecalcs": 69,
"styleRecalcDurationMs": 9.652000000000001,
"layouts": 9,
"layoutDurationMs": 1.95,
"taskDurationMs": 1033.576,
"heapDeltaBytes": -2644184,
"heapUsedBytes": 99859876,
"domNodes": -297,
"jsHeapTotalBytes": -1708032,
"scriptDurationMs": 494.8429999999999,
"eventListeners": -128,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.66640625,
"p95FrameDurationMs": 16.700000000000273
},
{
"name": "large-graph-zoom",
"durationMs": 3384.2050000000086,
"styleRecalcs": 72,
"styleRecalcDurationMs": 10.729000000000001,
"layouts": 66,
"layoutDurationMs": 11.399,
"taskDurationMs": 1238.206,
"heapDeltaBytes": 10276908,
"heapUsedBytes": 110703140,
"domNodes": -272,
"jsHeapTotalBytes": -1773568,
"scriptDurationMs": 523.933,
"eventListeners": -130,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.66600985221675,
"p95FrameDurationMs": 16.700000000000728
},
{
"name": "large-graph-zoom",
"durationMs": 3172.5000000000136,
"styleRecalcs": 74,
"styleRecalcDurationMs": 11.037,
"layouts": 68,
"layoutDurationMs": 12.026,
"taskDurationMs": 1144.399,
"heapDeltaBytes": -12378048,
"heapUsedBytes": 92700476,
"domNodes": -272,
"jsHeapTotalBytes": -491520,
"scriptDurationMs": 498.463,
"eventListeners": -130,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.665968586387432,
"p95FrameDurationMs": 16.799999999999272
},
{
"name": "legacy-node-drag",
"durationMs": 2313.0390000000034,
"styleRecalcs": 49,
"styleRecalcDurationMs": 6.363,
"layouts": 8,
"layoutDurationMs": 1.9789999999999999,
"taskDurationMs": 1265.439,
"heapDeltaBytes": 18279108,
"heapUsedBytes": 127891208,
"domNodes": 0,
"jsHeapTotalBytes": 6451200,
"scriptDurationMs": 612.854,
"eventListeners": 182,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.666906474820145,
"p95FrameDurationMs": 16.700000000000728
},
{
"name": "legacy-node-drag",
"durationMs": 2204.9260000000004,
"styleRecalcs": 45,
"styleRecalcDurationMs": 5.787,
"layouts": 6,
"layoutDurationMs": 1.408,
"taskDurationMs": 1205.1319999999998,
"heapDeltaBytes": 36817732,
"heapUsedBytes": 146576236,
"domNodes": 0,
"jsHeapTotalBytes": 25587712,
"scriptDurationMs": 595.828,
"eventListeners": 182,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.66666666666667,
"p95FrameDurationMs": 16.700000000000728
},
{
"name": "minimap-idle",
"durationMs": 2036.9289999999864,
"styleRecalcs": 9,
"styleRecalcDurationMs": 2.92,
"layouts": 9,
"layoutDurationMs": 2.471,
"taskDurationMs": 434.18,
"heapDeltaBytes": -1922452,
"heapUsedBytes": 106188888,
"domNodes": -297,
"jsHeapTotalBytes": -2195456,
"scriptDurationMs": 26.443999999999996,
"eventListeners": -130,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.66639344262295,
"p95FrameDurationMs": 16.700000000000728
},
{
"name": "minimap-idle",
"durationMs": 2037.243999999987,
"styleRecalcs": 8,
"styleRecalcDurationMs": 1.8000000000000005,
"layouts": 8,
"layoutDurationMs": 1.6589999999999998,
"taskDurationMs": 357.99699999999996,
"heapDeltaBytes": 2290280,
"heapUsedBytes": 110312000,
"domNodes": -296,
"jsHeapTotalBytes": -3137536,
"scriptDurationMs": 19.391000000000005,
"eventListeners": -130,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.66639344262295,
"p95FrameDurationMs": 16.700000000000728
},
{
"name": "subgraph-dom-widget-clipping",
"durationMs": 414.56099999999196,
"styleRecalcs": 49,
"styleRecalcDurationMs": 5.363999999999999,
"layouts": 11,
"layoutDurationMs": 2.6749999999999994,
"taskDurationMs": 291.69800000000004,
"heapDeltaBytes": 2854804,
"heapUsedBytes": 101411616,
"domNodes": 0,
"jsHeapTotalBytes": 10223616,
"scriptDurationMs": 93.845,
"eventListeners": 46,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.667999999999992,
"p95FrameDurationMs": 16.700000000000273
},
{
"name": "subgraph-dom-widget-clipping",
"durationMs": 414.53200000000834,
"styleRecalcs": 47,
"styleRecalcDurationMs": 4.509000000000001,
"layouts": 9,
"layoutDurationMs": 2.018,
"taskDurationMs": 263.411,
"heapDeltaBytes": 22484892,
"heapUsedBytes": 112952524,
"domNodes": 0,
"jsHeapTotalBytes": 2621440,
"scriptDurationMs": 91.538,
"eventListeners": 46,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.663999999999998,
"p95FrameDurationMs": 16.799999999999727
},
{
"name": "subgraph-idle",
"durationMs": 2026.0590000000036,
"styleRecalcs": 9,
"styleRecalcDurationMs": 2.795000000000001,
"layouts": 9,
"layoutDurationMs": 2.261,
"taskDurationMs": 419.51500000000004,
"heapDeltaBytes": -3993920,
"heapUsedBytes": 85996252,
"domNodes": -218,
"jsHeapTotalBytes": -98304,
"scriptDurationMs": 9.73,
"eventListeners": -176,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.665573770491804,
"p95FrameDurationMs": 16.800000000000182
},
{
"name": "subgraph-idle",
"durationMs": 2010.0950000000353,
"styleRecalcs": 10,
"styleRecalcDurationMs": 2.611,
"layouts": 10,
"layoutDurationMs": 2.2950000000000004,
"taskDurationMs": 337.771,
"heapDeltaBytes": -18095212,
"heapUsedBytes": 81220628,
"domNodes": -218,
"jsHeapTotalBytes": 3862528,
"scriptDurationMs": 5.611,
"eventListeners": -176,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.66611570247934,
"p95FrameDurationMs": 16.799999999999727
},
{
"name": "subgraph-mouse-sweep",
"durationMs": 1691.7819999999892,
"styleRecalcs": 75,
"styleRecalcDurationMs": 14.48,
"layouts": 11,
"layoutDurationMs": 2.6980000000000004,
"taskDurationMs": 667.601,
"heapDeltaBytes": -4079388,
"heapUsedBytes": 95581792,
"domNodes": 0,
"jsHeapTotalBytes": 11272192,
"scriptDurationMs": 95.86,
"eventListeners": 6,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.6656862745098,
"p95FrameDurationMs": 16.700000000000728
},
{
"name": "subgraph-mouse-sweep",
"durationMs": 1695.6390000000283,
"styleRecalcs": 75,
"styleRecalcDurationMs": 11.001999999999999,
"layouts": 10,
"layoutDurationMs": 2.0039999999999996,
"taskDurationMs": 456.039,
"heapDeltaBytes": -3119604,
"heapUsedBytes": 86910408,
"domNodes": -211,
"jsHeapTotalBytes": -98304,
"scriptDurationMs": 70.87199999999999,
"eventListeners": -174,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.666666666666668,
"p95FrameDurationMs": 16.700000000000273
},
{
"name": "subgraph-transition-enter",
"durationMs": 767.1100000000024,
"styleRecalcs": 19,
"styleRecalcDurationMs": 15.583,
"layouts": 5,
"layoutDurationMs": 9.598999999999998,
"taskDurationMs": 499.10999999999996,
"heapDeltaBytes": 37898824,
"heapUsedBytes": 137099244,
"domNodes": 16030,
"jsHeapTotalBytes": 16392192,
"scriptDurationMs": 18.196000000000005,
"eventListeners": 3244,
"totalBlockingTimeMs": 63,
"frameDurationMs": 19.656410256410254,
"p95FrameDurationMs": 33.399999999999636
},
{
"name": "viewport-pan-sweep",
"durationMs": 8459.811000000002,
"styleRecalcs": 251,
"styleRecalcDurationMs": 34.182,
"layouts": 10,
"layoutDurationMs": 2.253,
"taskDurationMs": 3951.0209999999997,
"heapDeltaBytes": -27627804,
"heapUsedBytes": 92755228,
"domNodes": -296,
"jsHeapTotalBytes": 753664,
"scriptDurationMs": 1893.741,
"eventListeners": -128,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.666141732283464,
"p95FrameDurationMs": 16.799999999999272
},
{
"name": "viewport-pan-sweep",
"durationMs": 8203.74899999996,
"styleRecalcs": 251,
"styleRecalcDurationMs": 31.958000000000002,
"layouts": 9,
"layoutDurationMs": 2.0989999999999998,
"taskDurationMs": 3623.592,
"heapDeltaBytes": -29378584,
"heapUsedBytes": 90404792,
"domNodes": -296,
"jsHeapTotalBytes": 753664,
"scriptDurationMs": 1750.284,
"eventListeners": -128,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.666260162601624,
"p95FrameDurationMs": 16.799999999999272
},
{
"name": "vue-large-graph-idle",
"durationMs": 14972.617000000013,
"styleRecalcs": 0,
"styleRecalcDurationMs": 0,
"layouts": 0,
"layoutDurationMs": 0,
"taskDurationMs": 14284.179000000002,
"heapDeltaBytes": -47814360,
"heapUsedBytes": 272545760,
"domNodes": -3344,
"jsHeapTotalBytes": 20172800,
"scriptDurationMs": 188.626,
"eventListeners": -653,
"totalBlockingTimeMs": 0,
"frameDurationMs": 26.011631944444442,
"p95FrameDurationMs": 50
},
{
"name": "vue-large-graph-idle",
"durationMs": 10631.958999999995,
"styleRecalcs": 0,
"styleRecalcDurationMs": 0,
"layouts": 0,
"layoutDurationMs": 0,
"taskDurationMs": 9797.293,
"heapDeltaBytes": -33741032,
"heapUsedBytes": 286220432,
"domNodes": -3344,
"jsHeapTotalBytes": 35377152,
"scriptDurationMs": 129.526,
"eventListeners": -653,
"totalBlockingTimeMs": 0,
"frameDurationMs": 18.114139693356048,
"p95FrameDurationMs": 33.29999999999927
},
{
"name": "vue-large-graph-pan",
"durationMs": 16680.305999999975,
"styleRecalcs": 122,
"styleRecalcDurationMs": 14.475999999999988,
"layouts": 0,
"layoutDurationMs": 0,
"taskDurationMs": 16377.523,
"heapDeltaBytes": -15168072,
"heapUsedBytes": 304503444,
"domNodes": -3344,
"jsHeapTotalBytes": 24633344,
"scriptDurationMs": 572.033,
"eventListeners": -651,
"totalBlockingTimeMs": 0,
"frameDurationMs": 31.358458646616544,
"p95FrameDurationMs": 66.70000000000073
},
{
"name": "vue-large-graph-pan",
"durationMs": 17638.90500000002,
"styleRecalcs": 140,
"styleRecalcDurationMs": 14.961000000000002,
"layouts": 0,
"layoutDurationMs": 0,
"taskDurationMs": 17279.25,
"heapDeltaBytes": -38357652,
"heapUsedBytes": 293190428,
"domNodes": -3344,
"jsHeapTotalBytes": 16502784,
"scriptDurationMs": 595.081,
"eventListeners": -651,
"totalBlockingTimeMs": 0,
"frameDurationMs": 32.98934579439253,
"p95FrameDurationMs": 66.70000000000073
},
{
"name": "vue-node-resize-workload",
"durationMs": 5167.498999999963,
"styleRecalcs": 20,
"styleRecalcDurationMs": 39.52900000000001,
"layouts": 20,
"layoutDurationMs": 19.121,
"taskDurationMs": 5073.004,
"heapDeltaBytes": -27668600,
"heapUsedBytes": 297849484,
"domNodes": -3344,
"jsHeapTotalBytes": 28823552,
"scriptDurationMs": 73.765,
"eventListeners": -653,
"totalBlockingTimeMs": 0,
"frameDurationMs": 30.75238095238095,
"p95FrameDurationMs": 50.100000000000364
},
{
"name": "vue-node-resize-workload",
"durationMs": 5320.251999999982,
"styleRecalcs": 20,
"styleRecalcDurationMs": 40.43100000000001,
"layouts": 20,
"layoutDurationMs": 19.274,
"taskDurationMs": 5256.659,
"heapDeltaBytes": -14608100,
"heapUsedBytes": 310171892,
"domNodes": -3344,
"jsHeapTotalBytes": 26988544,
"scriptDurationMs": 75.569,
"eventListeners": -653,
"totalBlockingTimeMs": 0,
"frameDurationMs": 32.718404907975454,
"p95FrameDurationMs": 66.60000000000036
},
{
"name": "vue-zoom-out-idle",
"durationMs": 6977.976000000012,
"styleRecalcs": 0,
"styleRecalcDurationMs": 0,
"layouts": 0,
"layoutDurationMs": 0,
"taskDurationMs": 6552.517,
"heapDeltaBytes": 19831104,
"heapUsedBytes": 302982548,
"domNodes": 0,
"jsHeapTotalBytes": 0,
"scriptDurationMs": 76.60700000000004,
"eventListeners": 0,
"totalBlockingTimeMs": 0,
"frameDurationMs": 23.51178451178452,
"p95FrameDurationMs": 33.400000000001455
},
{
"name": "vue-zoom-out-idle",
"durationMs": 6729.6349999999165,
"styleRecalcs": 0,
"styleRecalcDurationMs": 0,
"layouts": 0,
"layoutDurationMs": 0,
"taskDurationMs": 6427.88,
"heapDeltaBytes": 23358668,
"heapUsedBytes": 296045088,
"domNodes": 0,
"jsHeapTotalBytes": 0,
"scriptDurationMs": 73.992,
"eventListeners": 0,
"totalBlockingTimeMs": 0,
"frameDurationMs": 22.690540540540532,
"p95FrameDurationMs": 49.89999999999782
},
{
"name": "workflow-execution",
"durationMs": 88.04099999997561,
"styleRecalcs": 7,
"styleRecalcDurationMs": 7.137000000000001,
"layouts": 7,
"layoutDurationMs": 2.491,
"taskDurationMs": 60.74,
"heapDeltaBytes": 4798292,
"heapUsedBytes": 98686924,
"domNodes": 97,
"jsHeapTotalBytes": 524288,
"scriptDurationMs": 5.992000000000001,
"eventListeners": 1,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.680000000000017,
"p95FrameDurationMs": 16.700000000000273
},
{
"name": "workflow-execution",
"durationMs": 440.53100000007817,
"styleRecalcs": 20,
"styleRecalcDurationMs": 9.790000000000001,
"layouts": 13,
"layoutDurationMs": 3.622,
"taskDurationMs": 85.451,
"heapDeltaBytes": 6904316,
"heapUsedBytes": 101537716,
"domNodes": 121,
"jsHeapTotalBytes": 0,
"scriptDurationMs": 8.158999999999999,
"eventListeners": 1,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.661538461538456,
"p95FrameDurationMs": 16.800000000000182
},
{
"name": "agent-composer-empty-conversation-typing",
"durationMs": 194.75999999997384,
"styleRecalcs": 5,
"styleRecalcDurationMs": 0.5730000000000001,
"layouts": 76,
"layoutDurationMs": 9.629999999999999,
"taskDurationMs": 162.45399999999998,
"heapDeltaBytes": 9756436,
"heapUsedBytes": 97754616,
"domNodes": 4,
"jsHeapTotalBytes": 9699328,
"scriptDurationMs": 66.807,
"eventListeners": 292,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.666666666666703,
"p95FrameDurationMs": 16.700000000000728
},
{
"name": "agent-composer-empty-conversation-typing",
"durationMs": 193.17200000000412,
"styleRecalcs": 5,
"styleRecalcDurationMs": 0.609,
"layouts": 76,
"layoutDurationMs": 9.452,
"taskDurationMs": 156.89399999999998,
"heapDeltaBytes": 9637616,
"heapUsedBytes": 97530324,
"domNodes": 4,
"jsHeapTotalBytes": 9699328,
"scriptDurationMs": 64.396,
"eventListeners": 292,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.666666666666668,
"p95FrameDurationMs": 16.800000000000182
},
{
"name": "agent-composer-long-conversation-typing",
"durationMs": 243.93799999995736,
"styleRecalcs": 5,
"styleRecalcDurationMs": 1.1540000000000001,
"layouts": 76,
"layoutDurationMs": 9.099,
"taskDurationMs": 205.934,
"heapDeltaBytes": -1191372,
"heapUsedBytes": 115835284,
"domNodes": 4,
"jsHeapTotalBytes": 2748416,
"scriptDurationMs": 67.987,
"eventListeners": 292,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.673333333333296,
"p95FrameDurationMs": 16.800000000000182
},
{
"name": "agent-composer-long-conversation-typing",
"durationMs": 232.55300000005263,
"styleRecalcs": 5,
"styleRecalcDurationMs": 1.1689999999999998,
"layouts": 76,
"layoutDurationMs": 9.053,
"taskDurationMs": 198.552,
"heapDeltaBytes": -6422808,
"heapUsedBytes": 101188648,
"domNodes": 4,
"jsHeapTotalBytes": 0,
"scriptDurationMs": 65.414,
"eventListeners": 292,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.67142857142861,
"p95FrameDurationMs": 16.800000000000182
}
]
}🎭 Playwright: ✅ 2996 passed, 0 failed · 4 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 459f2866be801b26ce2580e9da613e8b786c8e8b
Full docs: ADR-DEVEX-LINT-0015 🏛️ Architecture: ✅ PassedFindings and check detailsWarnings (146)
Reproduce locallypnpm architecture:checkFull docs: Frontend domain catalog |
Swarmhost agentic reviewThe detailed evaluation is available to employees in the internal Slack review thread. Evaluation failed to run ( Evaluation budget remaining for this pull request: 98 automatic and 99 manual. Updated by Swarmhost's agentic review process. |
Codecov Report✅ All modified and coverable lines are covered by tests. @@ Coverage Diff @@
## cloud/1.58 #22944 +/- ##
=============================================
Coverage ? 84.46%
=============================================
Files ? 3171
Lines ? 165537
Branches ? 41672
=============================================
Hits ? 139829
Misses ? 25317
Partials ? 391
Flags with carried forward coverage won't be shown. Click here to find out more.
🚀 New features to boost your workflow:
|
dante01yoon
left a comment
There was a problem hiding this comment.
Reviewed b674bb4 against cloud/1.58, including the manual conflict resolutions, carried tests and branch-specific session/history callers. The added hasDraft prerequisite matches the newer trains; unavailable follow/retry helpers are correctly omitted. New Chat clears and cancels the old draft, history Back preserves text, and reload restoration validates saved text/workflow references. No code blockers found.
The upstream author's red/green evidence and carried regressions cover the change. Exact-head unit shards (8/8), package tests, unit aggregate, lint and both type checks passed. Broader E2E jobs remain pending, not claimed as passed. Reviewer execution of tests, builds, type checks, mutations, browser QA and live-backend checks: NOT_RUN.
Backport of #21588
Backport of #22821
Two fixes to the Agent chat composer, in source order:
Switching between existing chats through history still keeps the draft (unchanged, intended).
Conflicts, resolved by hand:
AgentPanelRoot.vue/AgentPanel.vue: this train has noretireFollow(), noretry-syncevent and still namesonSelectHistory; thehistory_backbranch ofonNewChatis ported without them, so Back from history to a fresh chat keeps the draft, same as main.agentComposerStore.ts: this train has nohasDraft. Added the same computed as main (text, attachments or references present) and exported it, becausetrackDraftThread()and the PM-2002 tests use it. Helpers from newer main commits are not carried.agentComposerStore.test.ts: the "composer draft presence" block from an unrelated main commit is not carried; only the PM-2002 block is added.Tests carried:
AgentPanelRoot.test.ts,AgentPanel.test.ts,agentComposerStore.test.ts(PM-2002 cases), and the browser specsagentNewChatTargetWorkflow.spec.ts,agentAttachmentUpload.spec.ts,agentComposerDraftSurvivesReload.spec.ts.