Repository navigation
Conversation
|
✅ All contributors have signed the CLA. Thank you! This PR is ready to be merged. |
|
Note Reviews pausedIt looks like this branch is under active development. To avoid overwhelming you with review comments due to an influx of new commits, CodeRabbit has automatically paused this review. You can configure this behavior by changing the Use the following commands to manage reviews:
Use the checkboxes below for quick actions:
Important Approval pendingCodeRabbit has no unresolved comments, but it has not reviewed the latest commit. Use the checkbox below to review the latest commit. CodeRabbit will approve the changes if it finds no blocking issues.
📝 WalkthroughWalkthroughAdds COMFY_DYNAMICGROUP_V3 schema parsing, dynamic type resolution, runtime row management, Vue widget registration, localization strings, and tests. ChangesDynamic group widget support
Estimated code review effort: 4 (Complex) | ~45 minutes Suggested reviewers: Important Pre-merge checks failedPlease resolve all errors before merging. Addressing warnings is optional. ❌ Failed checks (1 inconclusive)
✅ Passed checks (5 passed)
✨ Finishing Touches🧪 Generate unit tests (beta)
Comment |
🌐 Website E2ETip All tests passed.
|
🎨 Storybook: ✅ Built — View Storybook🎭 Playwright: ❌ 1692 passed, 1 failed · 2 flaky❌ Failed Tests📊 Browser Reports
📦 Bundle: 7.83 MB gzip 🔴 +5.09 kBDetailsSummary
Category Glance App Entry Points — 53.2 kB (baseline 53.2 kB) • ⚪ 0 BMain entry bundles and manifests
Status: 1 added / 1 removed Graph Workspace — 1.27 MB (baseline 1.27 MB) • ⚪ 0 BGraph editor runtime, canvas, workflow orchestration
Status: 1 added / 1 removed Views & Navigation — 110 kB (baseline 110 kB) • ⚪ 0 BTop-level views, pages, and routed surfaces
Status: 11 added / 11 removed / 3 unchanged Panels & Settings — 550 kB (baseline 550 kB) • ⚪ 0 BConfiguration panels, inspectors, and settings screens
Status: 11 added / 11 removed / 16 unchanged User & Accounts — 29.1 kB (baseline 29.1 kB) • ⚪ 0 BAuthentication, profile, and account management bundles
Status: 7 added / 7 removed / 3 unchanged Editors & Dialogs — 117 kB (baseline 117 kB) • ⚪ 0 BModals, dialogs, drawers, and in-app editors
Status: 4 added / 4 removed / 1 unchanged UI Components — 57.5 kB (baseline 57.5 kB) • ⚪ 0 BReusable component library chunks
Status: 5 added / 5 removed / 8 unchanged Data & Services — 270 kB (baseline 269 kB) • 🔴 +502 BStores, services, APIs, and repositories
Status: 13 added / 13 removed / 3 unchanged Utilities & Hooks — 3.41 MB (baseline 3.4 MB) • 🔴 +8.03 kBHelpers, composables, and utility bundles
Status: 20 added / 20 removed / 15 unchanged Vendor & Third-Party — 15.3 MB (baseline 15.3 MB) • ⚪ 0 BExternal libraries and shared vendor chunks Status: 16 unchanged Other — 11.8 MB (baseline 11.8 MB) • 🔴 +8.65 kBBundles that do not match a named category
Status: 81 added / 80 removed / 85 unchanged ⚡ Performance Report
Show regressions
All metrics
Historical variance (last 15 runs)
Trend (last 15 commits on main)
Raw data{
"timestamp": "2026-07-12T19:59:32.545Z",
"gitSha": "9615b5d820e41c36f8da9c81d2da46329d87fc6a",
"branch": "DynamicGroupSupport",
"measurements": [
{
"name": "canvas-idle",
"durationMs": 2023.6969999999985,
"styleRecalcs": 9,
"styleRecalcDurationMs": 8.758,
"layouts": 0,
"layoutDurationMs": 0,
"taskDurationMs": 386.18600000000004,
"heapDeltaBytes": 2157708,
"heapUsedBytes": 58421184,
"domNodes": 18,
"jsHeapTotalBytes": 18087936,
"scriptDurationMs": 18.540999999999997,
"eventListeners": 6,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.666666666666668,
"p95FrameDurationMs": 16.800000000000182
},
{
"name": "canvas-idle",
"durationMs": 2054.337999999973,
"styleRecalcs": 11,
"styleRecalcDurationMs": 13.322000000000001,
"layouts": 0,
"layoutDurationMs": 0,
"taskDurationMs": 422.76700000000005,
"heapDeltaBytes": -7424592,
"heapUsedBytes": 62462120,
"domNodes": -275,
"jsHeapTotalBytes": 19546112,
"scriptDurationMs": 15.915,
"eventListeners": -199,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.666666666666668,
"p95FrameDurationMs": 16.700000000000728
},
{
"name": "canvas-mouse-sweep",
"durationMs": 1955.0629999999956,
"styleRecalcs": 76,
"styleRecalcDurationMs": 43.714,
"layouts": 12,
"layoutDurationMs": 3.3030000000000004,
"taskDurationMs": 873.0570000000001,
"heapDeltaBytes": -6314000,
"heapUsedBytes": 52574984,
"domNodes": 58,
"jsHeapTotalBytes": 24641536,
"scriptDurationMs": 139.11599999999999,
"eventListeners": 6,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.670000000000012,
"p95FrameDurationMs": 16.800000000000182
},
{
"name": "canvas-mouse-sweep",
"durationMs": 1819.5360000000278,
"styleRecalcs": 71,
"styleRecalcDurationMs": 37.19799999999999,
"layouts": 12,
"layoutDurationMs": 3.502,
"taskDurationMs": 799.2549999999999,
"heapDeltaBytes": -4280004,
"heapUsedBytes": 48197364,
"domNodes": -270,
"jsHeapTotalBytes": 16117760,
"scriptDurationMs": 124.426,
"eventListeners": -199,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.666666666666668,
"p95FrameDurationMs": 16.700000000000728
},
{
"name": "canvas-zoom-sweep",
"durationMs": 1788.43999999998,
"styleRecalcs": 32,
"styleRecalcDurationMs": 21.313000000000002,
"layouts": 6,
"layoutDurationMs": 0.6300000000000001,
"taskDurationMs": 403.7289999999999,
"heapDeltaBytes": -3645908,
"heapUsedBytes": 66319784,
"domNodes": -229,
"jsHeapTotalBytes": 12468224,
"scriptDurationMs": 23.36,
"eventListeners": -184,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.666666666666668,
"p95FrameDurationMs": 16.799999999999272
},
{
"name": "canvas-zoom-sweep",
"durationMs": 1707.638999999972,
"styleRecalcs": 31,
"styleRecalcDurationMs": 16.94,
"layouts": 6,
"layoutDurationMs": 0.576,
"taskDurationMs": 307.90299999999996,
"heapDeltaBytes": 2486364,
"heapUsedBytes": 66824252,
"domNodes": 77,
"jsHeapTotalBytes": 22827008,
"scriptDurationMs": 18.328,
"eventListeners": 19,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.66999999999998,
"p95FrameDurationMs": 16.800000000000182
},
{
"name": "dom-widget-clipping",
"durationMs": 563.3940000000166,
"styleRecalcs": 11,
"styleRecalcDurationMs": 8.736999999999998,
"layouts": 0,
"layoutDurationMs": 0,
"taskDurationMs": 359.37,
"heapDeltaBytes": 7066388,
"heapUsedBytes": 66080676,
"domNodes": 18,
"jsHeapTotalBytes": 19398656,
"scriptDurationMs": 61.545,
"eventListeners": 2,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.666666666666668,
"p95FrameDurationMs": 16.699999999999818
},
{
"name": "dom-widget-clipping",
"durationMs": 579.8409999999876,
"styleRecalcs": 11,
"styleRecalcDurationMs": 7.817000000000001,
"layouts": 0,
"layoutDurationMs": 0,
"taskDurationMs": 342.422,
"heapDeltaBytes": 7126144,
"heapUsedBytes": 66115968,
"domNodes": 18,
"jsHeapTotalBytes": 17825792,
"scriptDurationMs": 57.471999999999994,
"eventListeners": 2,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.666666666666668,
"p95FrameDurationMs": 16.700000000000728
},
{
"name": "large-graph-idle",
"durationMs": 2037.608999999975,
"styleRecalcs": 10,
"styleRecalcDurationMs": 9.208999999999998,
"layouts": 0,
"layoutDurationMs": 0,
"taskDurationMs": 558.4780000000001,
"heapDeltaBytes": -11487848,
"heapUsedBytes": 62137700,
"domNodes": 20,
"jsHeapTotalBytes": 7196672,
"scriptDurationMs": 103.91300000000001,
"eventListeners": 6,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.666666666666668,
"p95FrameDurationMs": 16.700000000000728
},
{
"name": "large-graph-idle",
"durationMs": 2046.5050000000247,
"styleRecalcs": 8,
"styleRecalcDurationMs": 7.924999999999998,
"layouts": 0,
"layoutDurationMs": 0,
"taskDurationMs": 565.616,
"heapDeltaBytes": -9496812,
"heapUsedBytes": 58728032,
"domNodes": -272,
"jsHeapTotalBytes": -1323008,
"scriptDurationMs": 97.96000000000001,
"eventListeners": -197,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.666666666666668,
"p95FrameDurationMs": 16.800000000000182
},
{
"name": "large-graph-pan",
"durationMs": 2100.6679999999847,
"styleRecalcs": 68,
"styleRecalcDurationMs": 19.46,
"layouts": 0,
"layoutDurationMs": 0,
"taskDurationMs": 1086.865,
"heapDeltaBytes": 1286708,
"heapUsedBytes": 59656456,
"domNodes": 16,
"jsHeapTotalBytes": 8126464,
"scriptDurationMs": 396.01000000000005,
"eventListeners": 6,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.666666666666668,
"p95FrameDurationMs": 16.799999999999272
},
{
"name": "large-graph-pan",
"durationMs": 2130.8879999999704,
"styleRecalcs": 68,
"styleRecalcDurationMs": 17.489,
"layouts": 0,
"layoutDurationMs": 0,
"taskDurationMs": 1126.11,
"heapDeltaBytes": 13044140,
"heapUsedBytes": 82421040,
"domNodes": -277,
"jsHeapTotalBytes": -2428928,
"scriptDurationMs": 392.334,
"eventListeners": -197,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.670000000000012,
"p95FrameDurationMs": 16.800000000000182
},
{
"name": "large-graph-zoom",
"durationMs": 3077.1930000000225,
"styleRecalcs": 62,
"styleRecalcDurationMs": 16.382,
"layouts": 60,
"layoutDurationMs": 7.513,
"taskDurationMs": 1276.924,
"heapDeltaBytes": 14239460,
"heapUsedBytes": 68810412,
"domNodes": 6,
"jsHeapTotalBytes": 0,
"scriptDurationMs": 483.63500000000005,
"eventListeners": 6,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.666666666666668,
"p95FrameDurationMs": 16.699999999999818
},
{
"name": "large-graph-zoom",
"durationMs": 3131.325000000004,
"styleRecalcs": 63,
"styleRecalcDurationMs": 17.052999999999997,
"layouts": 60,
"layoutDurationMs": 7.484,
"taskDurationMs": 1301.1509999999998,
"heapDeltaBytes": 14554900,
"heapUsedBytes": 70298036,
"domNodes": 8,
"jsHeapTotalBytes": 0,
"scriptDurationMs": 491.046,
"eventListeners": 8,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.66333333333332,
"p95FrameDurationMs": 16.700000000000728
},
{
"name": "minimap-idle",
"durationMs": 2037.491999999986,
"styleRecalcs": 9,
"styleRecalcDurationMs": 9.765,
"layouts": 0,
"layoutDurationMs": 0,
"taskDurationMs": 507.818,
"heapDeltaBytes": -10390224,
"heapUsedBytes": 67640716,
"domNodes": 18,
"jsHeapTotalBytes": 7745536,
"scriptDurationMs": 95.60300000000001,
"eventListeners": 6,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.666666666666668,
"p95FrameDurationMs": 16.800000000000182
},
{
"name": "minimap-idle",
"durationMs": 2009.4950000000154,
"styleRecalcs": 9,
"styleRecalcDurationMs": 8.533000000000003,
"layouts": 0,
"layoutDurationMs": 0,
"taskDurationMs": 545.037,
"heapDeltaBytes": 8262264,
"heapUsedBytes": 71374360,
"domNodes": -263,
"jsHeapTotalBytes": 4468736,
"scriptDurationMs": 96.59400000000001,
"eventListeners": -130,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.66333333333335,
"p95FrameDurationMs": 16.700000000000728
},
{
"name": "subgraph-dom-widget-clipping",
"durationMs": 553.1839999999875,
"styleRecalcs": 46,
"styleRecalcDurationMs": 11.354000000000001,
"layouts": 0,
"layoutDurationMs": 0,
"taskDurationMs": 372.7,
"heapDeltaBytes": -12196276,
"heapUsedBytes": 53962556,
"domNodes": 18,
"jsHeapTotalBytes": 20467712,
"scriptDurationMs": 127.11500000000001,
"eventListeners": 6,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.666666666666668,
"p95FrameDurationMs": 16.700000000000273
},
{
"name": "subgraph-dom-widget-clipping",
"durationMs": 612.2080000000096,
"styleRecalcs": 46,
"styleRecalcDurationMs": 13.141,
"layouts": 0,
"layoutDurationMs": 0,
"taskDurationMs": 424.82200000000006,
"heapDeltaBytes": -21959544,
"heapUsedBytes": 48156248,
"domNodes": -277,
"jsHeapTotalBytes": 5652480,
"scriptDurationMs": 126.14599999999999,
"eventListeners": -195,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.666666666666668,
"p95FrameDurationMs": 16.799999999999272
},
{
"name": "subgraph-idle",
"durationMs": 2020.747,
"styleRecalcs": 9,
"styleRecalcDurationMs": 8.781999999999998,
"layouts": 0,
"layoutDurationMs": 0,
"taskDurationMs": 396.886,
"heapDeltaBytes": -197984,
"heapUsedBytes": 52150664,
"domNodes": -290,
"jsHeapTotalBytes": 17690624,
"scriptDurationMs": 13.923000000000002,
"eventListeners": -199,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.666666666666668,
"p95FrameDurationMs": 16.700000000000728
},
{
"name": "subgraph-idle",
"durationMs": 2008.0350000000067,
"styleRecalcs": 10,
"styleRecalcDurationMs": 10.400000000000002,
"layouts": 0,
"layoutDurationMs": 0,
"taskDurationMs": 408.461,
"heapDeltaBytes": -1790788,
"heapUsedBytes": 56809588,
"domNodes": 20,
"jsHeapTotalBytes": 25690112,
"scriptDurationMs": 20.118,
"eventListeners": 4,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.66333333333335,
"p95FrameDurationMs": 16.800000000000182
},
{
"name": "subgraph-mouse-sweep",
"durationMs": 1742.8230000000156,
"styleRecalcs": 75,
"styleRecalcDurationMs": 45.398,
"layouts": 16,
"layoutDurationMs": 4.51,
"taskDurationMs": 742.9870000000001,
"heapDeltaBytes": 17575480,
"heapUsedBytes": 69973820,
"domNodes": -272,
"jsHeapTotalBytes": 15855616,
"scriptDurationMs": 95.487,
"eventListeners": -199,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.66333333333335,
"p95FrameDurationMs": 16.799999999999272
},
{
"name": "subgraph-mouse-sweep",
"durationMs": 1740.733999999975,
"styleRecalcs": 75,
"styleRecalcDurationMs": 38.525999999999996,
"layouts": 16,
"layoutDurationMs": 4.755,
"taskDurationMs": 740.443,
"heapDeltaBytes": 17526820,
"heapUsedBytes": 69909076,
"domNodes": -270,
"jsHeapTotalBytes": 14282752,
"scriptDurationMs": 98.251,
"eventListeners": -199,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.670000000000012,
"p95FrameDurationMs": 16.800000000000182
},
{
"name": "subgraph-transition-enter",
"durationMs": 984.2949999999746,
"styleRecalcs": 20,
"styleRecalcDurationMs": 33.94799999999999,
"layouts": 16,
"layoutDurationMs": 16.662,
"taskDurationMs": 777.8940000000001,
"heapDeltaBytes": 29948948,
"heapUsedBytes": 101577652,
"domNodes": 13673,
"jsHeapTotalBytes": 17039360,
"scriptDurationMs": 30.39,
"eventListeners": 2535,
"totalBlockingTimeMs": 172,
"frameDurationMs": 16.666666666666668,
"p95FrameDurationMs": 16.800000000000182
},
{
"name": "viewport-pan-sweep",
"durationMs": 8130.138999999986,
"styleRecalcs": 251,
"styleRecalcDurationMs": 56.784000000000006,
"layouts": 0,
"layoutDurationMs": 0,
"taskDurationMs": 3709.9020000000005,
"heapDeltaBytes": -859820,
"heapUsedBytes": 71545244,
"domNodes": 20,
"jsHeapTotalBytes": 17358848,
"scriptDurationMs": 1259.995,
"eventListeners": 20,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.666666666666668,
"p95FrameDurationMs": 16.799999999999272
},
{
"name": "viewport-pan-sweep",
"durationMs": 8191.124000000002,
"styleRecalcs": 251,
"styleRecalcDurationMs": 56.33,
"layouts": 0,
"layoutDurationMs": 0,
"taskDurationMs": 3786.3459999999995,
"heapDeltaBytes": 953020,
"heapUsedBytes": 69024792,
"domNodes": -271,
"jsHeapTotalBytes": 454656,
"scriptDurationMs": 1256.416,
"eventListeners": -183,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.66333333333338,
"p95FrameDurationMs": 16.700000000000728
},
{
"name": "vue-large-graph-idle",
"durationMs": 12630.063000000007,
"styleRecalcs": 0,
"styleRecalcDurationMs": 0,
"layouts": 0,
"layoutDurationMs": 0,
"taskDurationMs": 12609.242999999999,
"heapDeltaBytes": -9707156,
"heapUsedBytes": 168796280,
"domNodes": -3291,
"jsHeapTotalBytes": 16252928,
"scriptDurationMs": 564.746,
"eventListeners": -16366,
"totalBlockingTimeMs": 0,
"frameDurationMs": 17.220000000000073,
"p95FrameDurationMs": 16.799999999999272
},
{
"name": "vue-large-graph-idle",
"durationMs": 12649.326999999972,
"styleRecalcs": 0,
"styleRecalcDurationMs": 0,
"layouts": 0,
"layoutDurationMs": 0,
"taskDurationMs": 12635.627,
"heapDeltaBytes": -47160108,
"heapUsedBytes": 166302808,
"domNodes": -3300,
"jsHeapTotalBytes": 1544192,
"scriptDurationMs": 554.6759999999999,
"eventListeners": -16374,
"totalBlockingTimeMs": 0,
"frameDurationMs": 17.220000000000073,
"p95FrameDurationMs": 16.799999999999272
},
{
"name": "vue-large-graph-pan",
"durationMs": 15450.198999999997,
"styleRecalcs": 79,
"styleRecalcDurationMs": 18.57799999999998,
"layouts": 0,
"layoutDurationMs": 0,
"taskDurationMs": 15425.967,
"heapDeltaBytes": -39803252,
"heapUsedBytes": 176328328,
"domNodes": -8311,
"jsHeapTotalBytes": 25755648,
"scriptDurationMs": 815.3439999999999,
"eventListeners": -16364,
"totalBlockingTimeMs": 114,
"frameDurationMs": 17.219999999999953,
"p95FrameDurationMs": 16.799999999999272
},
{
"name": "vue-large-graph-pan",
"durationMs": 15353.255999999987,
"styleRecalcs": 76,
"styleRecalcDurationMs": 18.71199999999995,
"layouts": 0,
"layoutDurationMs": 0,
"taskDurationMs": 15328.015,
"heapDeltaBytes": -59793404,
"heapUsedBytes": 169286092,
"domNodes": -3300,
"jsHeapTotalBytes": 233472,
"scriptDurationMs": 843.3470000000001,
"eventListeners": -16376,
"totalBlockingTimeMs": 7,
"frameDurationMs": 17.223333333333358,
"p95FrameDurationMs": 16.80000000000291
},
{
"name": "workflow-execution",
"durationMs": 482.3790000000372,
"styleRecalcs": 16,
"styleRecalcDurationMs": 25.867,
"layouts": 2,
"layoutDurationMs": 1.048,
"taskDurationMs": 128.79200000000003,
"heapDeltaBytes": 5004036,
"heapUsedBytes": 67712832,
"domNodes": 150,
"jsHeapTotalBytes": 4980736,
"scriptDurationMs": 9.877,
"eventListeners": 65,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.66666666666665,
"p95FrameDurationMs": 16.800000000000182
},
{
"name": "workflow-execution",
"durationMs": 448.62799999998515,
"styleRecalcs": 13,
"styleRecalcDurationMs": 18.783,
"layouts": 2,
"layoutDurationMs": 0.37800000000000006,
"taskDurationMs": 97.91,
"heapDeltaBytes": 4883152,
"heapUsedBytes": 63342980,
"domNodes": 119,
"jsHeapTotalBytes": 1572864,
"scriptDurationMs": 9.302,
"eventListeners": 67,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.666666666666668,
"p95FrameDurationMs": 16.800000000000182
}
]
} |
There was a problem hiding this comment.
Actionable comments posted: 3
🧹 Nitpick comments (1)
src/core/graph/widgets/dynamicWidgets.test.ts (1)
344-367: 📐 Maintainability & Code Quality | 🔵 Trivial | ⚡ Quick winConsider adding a regression test for removing a connected row input.
The current suite validates naming/index bookkeeping but never wires a link into a dynamic row input before removal, so it would not catch the dangling-link / stale-
target_slotissue flagged indynamicWidgets.ts(removeRow). A test that connects an output intog.0.a, removes row 0, and asserts the link is gone and remaining inputs keep correct slot indices would guard against that regression.Want me to draft this regression test?
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the rest with a brief reason, keep changes minimal, and validate. In `@src/core/graph/widgets/dynamicWidgets.test.ts` around lines 344 - 367, Add a regression test in dynamicWidgets.test.ts for the removeRow path in dynamicWidgets.ts: wire an output into a dynamic row input such as g.0.a, then remove that row through the row delete widget/callback. Assert the link is removed and the surviving row inputs are renumbered correctly, with their target_slot/index bookkeeping updated. Use the existing helpers addDynamicGroup, widgetNamed, inputNames, and widgetNames to locate and validate the state after removal.
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
Inline comments:
In `@packages/object-info-parser/src/schemas/nodeDefSchema.ts`:
- Around line 347-354: Add a cross-field validation to zDynamicGroupInputSpec so
the parsed object enforces min <= max, since min and max are currently only
checked independently. Update the zBaseInputOptions.extend schema inside
zDynamicGroupInputSpec with a refinement/superRefine that rejects invalid
combinations like min: 60 and max: 50, and keep the check localized to this
schema so callers using zDynamicGroupInputSpec get the constraint automatically.
In `@src/core/graph/widgets/dynamicWidgets.ts`:
- Around line 521-533: Clamp the deserialized row count before rebuilding rows
in dynamicWidgets.ts: the controller.value setter currently passes count
directly into rebuildRows, which can create out-of-range row counts. Update the
setter near Object.defineProperty(controller, 'value', ...) to normalize the
incoming number to the [min, max] bounds before calling rebuildRows and
syncController, so external/restored values cannot violate the group invariants
or trigger excessive row creation.
- Around line 418-440: The row-socket cleanup in dynamicWidgets.ts is removing
entries from node.inputs directly, which leaves linked sockets connected and
skips target_slot reindexing. Update removeRow()/rebuildRows() to use the node
API’s removeInput() path for each affected input, or mirror its disconnect and
slot reindex logic before renaming the remaining inputs and widgets in the
row-shift loops (including the node.inputs / inp.widget.name handling).
---
Nitpick comments:
In `@src/core/graph/widgets/dynamicWidgets.test.ts`:
- Around line 344-367: Add a regression test in dynamicWidgets.test.ts for the
removeRow path in dynamicWidgets.ts: wire an output into a dynamic row input
such as g.0.a, then remove that row through the row delete widget/callback.
Assert the link is removed and the surviving row inputs are renumbered
correctly, with their target_slot/index bookkeeping updated. Use the existing
helpers addDynamicGroup, widgetNamed, inputNames, and widgetNames to locate and
validate the state after removal.
🪄 Autofix (Beta)
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: Path: .coderabbit.yaml
Review profile: CHILL
Plan: Pro Plus
Run ID: 6b588070-7627-4516-994d-91e242fbefcb
📒 Files selected for processing (10)
packages/object-info-parser/src/schemas/nodeDefSchema.tssrc/composables/graph/useGraphNodeManager.tssrc/core/graph/widgets/dynamicTypes.tssrc/core/graph/widgets/dynamicWidgets.test.tssrc/core/graph/widgets/dynamicWidgets.tssrc/lib/litegraph/src/types/widgets.tssrc/locales/en/main.jsonsrc/renderer/extensions/vueNodes/widgets/components/WidgetDynamicGroupAdd.vuesrc/renderer/extensions/vueNodes/widgets/components/WidgetDynamicGroupRow.vuesrc/renderer/extensions/vueNodes/widgets/registry/widgetRegistry.ts
Codecov Report❌ Patch coverage is
@@ Coverage Diff @@
## main #13115 +/- ##
==========================================
+ Coverage 77.80% 77.86% +0.06%
==========================================
Files 1658 1659 +1
Lines 95859 96104 +245
Branches 34095 34147 +52
==========================================
+ Hits 74584 74835 +251
+ Misses 20598 20593 -5
+ Partials 677 676 -1
Flags with carried forward coverage won't be shown. Click here to find out more.
... and 3 files with indirect coverage changes 🚀 New features to boost your workflow:
|
|
recheck |
There was a problem hiding this comment.
Actionable comments posted: 2
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
Inline comments:
In `@src/core/graph/widgets/dynamicWidgets.ts`:
- Around line 117-120: The child-widget cleanup in remove(node.widgets,
isInGroup) is deleting persisted state too early, before the combo selection has
been validated and resolved by the logic around the !newSpec bailout in
dynamicWidgets; move the deleteWidget(widget.widgetId) call so it only runs
after a real option is found and the replacement widgets are successfully
rebuilt, using the same widget/onRemove flow in dynamicWidgets to preserve
restored sub-widget state for stale combo values.
In `@src/locales/en/main.json`:
- Around line 898-899: Remove the hidden hyphen/formatting characters from the
locale strings so the values are plain text in the main JSON file. Update the
affected entries for the workflow/template labels and the Shortcuts label using
the locale keys in the JSON, keeping the text as normal “Workflows”,
“Templates”, and “Shortcuts” with any wrapping handled outside the content.
🪄 Autofix (Beta)
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: Path: .coderabbit.yaml
Review profile: ASSERTIVE
Plan: Pro Plus
Run ID: 017faf4b-e091-48c8-aca7-ab700899352c
📒 Files selected for processing (2)
src/core/graph/widgets/dynamicWidgets.tssrc/locales/en/main.json
There was a problem hiding this comment.
Caution
Inline review comments failed to post. This is likely due to GitHub's internal server error or limits when posting large numbers of comments. If you are seeing this consistently it is likely a permissions issue. Please check "Moderation" -> "Code review limits" under your organization settings.
Actionable comments posted: 2
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
Inline comments:
In `@src/core/graph/widgets/dynamicWidgets.ts`:
- Around line 117-120: The child-widget cleanup in remove(node.widgets,
isInGroup) is deleting persisted state too early, before the combo selection has
been validated and resolved by the logic around the !newSpec bailout in
dynamicWidgets; move the deleteWidget(widget.widgetId) call so it only runs
after a real option is found and the replacement widgets are successfully
rebuilt, using the same widget/onRemove flow in dynamicWidgets to preserve
restored sub-widget state for stale combo values.
In `@src/locales/en/main.json`:
- Around line 898-899: Remove the hidden hyphen/formatting characters from the
locale strings so the values are plain text in the main JSON file. Update the
affected entries for the workflow/template labels and the Shortcuts label using
the locale keys in the JSON, keeping the text as normal “Workflows”,
“Templates”, and “Shortcuts” with any wrapping handled outside the content.
🪄 Autofix (Beta)
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: Path: .coderabbit.yaml
Review profile: ASSERTIVE
Plan: Pro Plus
Run ID: 017faf4b-e091-48c8-aca7-ab700899352c
📒 Files selected for processing (2)
src/core/graph/widgets/dynamicWidgets.tssrc/locales/en/main.json
🛑 Comments failed to post (2)
src/core/graph/widgets/dynamicWidgets.ts (1)
117-120: 🗄️ Data Integrity & Integration | 🟠 Major | ⚡ Quick win
Defer
deleteWidget()until the combo value resolves to a real option.Line 119 now purges the persisted child-widget state before the
!newSpecbailout below. A stale/restored combo value that no longer exists inoptionswill wipe those stored values and exit without recreating replacements, so the user's sub-widget input is lost on the next valid selection.🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the rest with a brief reason, keep changes minimal, and validate. In `@src/core/graph/widgets/dynamicWidgets.ts` around lines 117 - 120, The child-widget cleanup in remove(node.widgets, isInGroup) is deleting persisted state too early, before the combo selection has been validated and resolved by the logic around the !newSpec bailout in dynamicWidgets; move the deleteWidget(widget.widgetId) call so it only runs after a real option is found and the replacement widgets are successfully rebuilt, using the same widget/onRemove flow in dynamicWidgets to preserve restored sub-widget state for stale combo values.src/locales/en/main.json (1)
898-899: 🎯 Functional Correctness | 🟡 Minor | ⚡ Quick win
Keep these labels as plain text.
Lines 898-899 and 3077 contain hidden hyphen/formatting characters inside
"Workflows","Templates", and"Shortcuts". That changes the actual locale value, which can break exact-text matching and leak odd characters into copy/paste or assistive output. If the goal is wrapping, handle it in CSS instead.Also applies to: 3077-3077
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the rest with a brief reason, keep changes minimal, and validate. In `@src/locales/en/main.json` around lines 898 - 899, Remove the hidden hyphen/formatting characters from the locale strings so the values are plain text in the main JSON file. Update the affected entries for the workflow/template labels and the Shortcuts label using the locale keys in the JSON, keeping the text as normal “Workflows”, “Templates”, and “Shortcuts” with any wrapping handled outside the content.
a16d488 to
10d2030
Compare
There was a problem hiding this comment.
Actionable comments posted: 1
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
Inline comments:
In `@src/core/graph/widgets/dynamicWidgets.ts`:
- Around line 264-275: The row counting logic in countGroupRows only looks at
node.widgets, so input-only members created through addNodeInput in createRow
can be missed and cause row index reuse and state drift. Update countGroupRows
to also inspect the node’s inputs/row members (including forceInput or
widget-less cases) using the same group/name pattern so it counts every existing
row before addRow assigns a new index.
🪄 Autofix (Beta)
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: Path: .coderabbit.yaml
Review profile: ASSERTIVE
Plan: Pro Plus
Run ID: c4a1ce4b-d5ab-47bb-a980-02a659a6dc7e
📒 Files selected for processing (5)
packages/object-info-parser/src/schemas/nodeDefSchema.tssrc/composables/graph/useGraphNodeManager.tssrc/core/graph/widgets/dynamicTypes.tssrc/core/graph/widgets/dynamicWidgets.test.tssrc/core/graph/widgets/dynamicWidgets.ts
10d2030 to
83ec625
Compare
There was a problem hiding this comment.
Actionable comments posted: 3
Caution
Some comments are outside the diff and can’t be posted inline due to platform limitations.
⚠️ Outside diff range comments (1)
src/core/graph/widgets/dynamicTypes.ts (1)
28-55: 📐 Maintainability & Code Quality | 🔵 Trivial | ⚡ Quick winDuplicate flattening logic between
resolveDynamicGroupTypeandresolveAutogrowType.Both functions build the same
inputTypesarray andflatMap/transformInputSpecV1ToV2/resolveInputTypepipeline, differing only in whererequired/optionalcome from. Consider extracting a shared helper, e.g.flattenTemplateInputTypes(required, optional), to avoid duplication.🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the rest with a brief reason, keep changes minimal, and validate. In `@src/core/graph/widgets/dynamicTypes.ts` around lines 28 - 55, The flattening pipeline in resolveDynamicGroupType and resolveAutogrowType is duplicated: both create the same required/optional array and run the same Object.entries -> transformInputSpecV1ToV2 -> resolveInputType flow. Extract that shared logic into a helper such as flattenTemplateInputTypes(required, optional) and have both functions call it, while keeping only the source of required/optional different in each function.
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
Inline comments:
In `@src/core/graph/widgets/dynamicTypes.ts`:
- Around line 28-41: resolveDynamicGroupType currently swallows invalid
DynamicGroup specs by using zDynamicGroupInputSpec.safeParse and returning []
when parsing fails, which hides schema errors and conflicts with
dynamicGroupWidget’s invalid DynamicGroup spec handling. Update
resolveDynamicGroupType to fail fast by checking the parse result and throwing
the same invalid DynamicGroup spec error (or equivalent) before accessing parsed
data, so bad InputSpecV2 inputs do not produce incomplete type resolution.
In `@src/core/graph/widgets/dynamicWidgets.test.ts`:
- Around line 357-369: The test setup in the dynamicWidgets tests is redefining
an inline structural type for accessing comfyDynamic.dynamicGroup instead of
reusing the imported DynamicGroupNode type. Update the affected state casts in
the remove-row and related test blocks to use the existing
DynamicGroupNode-based access pattern already used later in the file, so there
is a single source of truth for node state typing.
In `@src/core/graph/widgets/dynamicWidgets.ts`:
- Around line 392-393: The parse failure in the DynamicGroup spec check is too
generic; update the error thrown after
zDynamicGroupInputSpec.safeParse(untypedInputData) in dynamicWidgets to include
the offending inputName and, if available, the Zod validation issue details.
Keep the location anchored around the parseResult.success check so malformed
node definitions surface with actionable context instead of a bare invalid
DynamicGroup spec message.
---
Outside diff comments:
In `@src/core/graph/widgets/dynamicTypes.ts`:
- Around line 28-55: The flattening pipeline in resolveDynamicGroupType and
resolveAutogrowType is duplicated: both create the same required/optional array
and run the same Object.entries -> transformInputSpecV1ToV2 -> resolveInputType
flow. Extract that shared logic into a helper such as
flattenTemplateInputTypes(required, optional) and have both functions call it,
while keeping only the source of required/optional different in each function.
🪄 Autofix (Beta)
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: Path: .coderabbit.yaml
Review profile: ASSERTIVE
Plan: Pro Plus
Run ID: a658aadd-351d-4b7d-ba06-0416ac03abf5
📒 Files selected for processing (7)
packages/object-info-parser/src/__tests__/nodeDefSchema.test.tspackages/object-info-parser/src/schemas/nodeDefSchema.tssrc/composables/graph/useGraphNodeManager.tssrc/core/graph/widgets/dynamicTypes.test.tssrc/core/graph/widgets/dynamicTypes.tssrc/core/graph/widgets/dynamicWidgets.test.tssrc/core/graph/widgets/dynamicWidgets.ts
|
I have read and agree to the Contributor License Agreement |
|
@Talmaj found one bug, pressing the key "r" to refresh the list of LoRA models in the node does not work. You might want to check how it's done in other nodes that have a files combo. |
…mum eing respected, widget input support for DynamicGroup.
fd943d5 to
9cc39e4
Compare
christian-byrne
left a comment
There was a problem hiding this comment.
Lint preflight: comfy/no-new-error-throw in src/core/graph/widgets/dynamicWidgets.ts:96
The PR head 9cc39e44b0 still contains throw new Error('invalid DynamicCombo spec') at line 96. Per ADR 0019, replace with assert() from @/base/assert:
--- a/src/core/graph/widgets/dynamicWidgets.ts
+++ b/src/core/graph/widgets/dynamicWidgets.ts
@@ -1,5 +1,6 @@
import { remove } from 'es-toolkit'
import { shallowReactive } from 'vue'
+import { assert } from '@/base/assert'
// ...existing code...
@@ -93,7 +94,7 @@
const parseResult = zDynamicComboInputSpec.safeParse(untypedInputData)
- if (!parseResult.success) throw new Error('invalid DynamicCombo spec')
+ assert(parseResult.success, 'invalid DynamicCombo spec')
const inputData = parseResult.dataassert() centralizes invariant failures — throws in DEV, delegates to the registered reporter (Sentry/toast) in production. The message must remain a static description (no interpolated user data).
Cannot push directly because PR author Talmaj is outside fleet push authority (FLEET_AUTHORS={christian-byrne}). Please apply and rebase; the merged-tree lint will re-run on the fresh head.
…gets safeParse failures
## ELI5 With Modern Node Design (Node 2.0), a node can offer an expandable list of controls, such as a file and strength for each LoRA. Users can add or remove rows, and saved workflows restore those rows and their values before execution. ## Motivation The generic frontend support needs to work independently of the native LoRA nodes. This implements the widget-template contract from the companion backend and supplies a small development node that echoes the received rows, so storage and execution can be exercised without loading models. ## Reviewer context - **Type:** feature — generic DynamicGroup widget support for Node 2.0. - **Companion:** [Comfy-Org/ComfyUI#16260 — feat: add DynamicGroup widget input](Comfy-Org/ComfyUI#16260). - **Design reference:** Talmaj's [Comfy-Org#13115 — feat: DynamicGroupSupport (CORE-186)](Comfy-Org#13115); retains the row dividers, labels and add/remove controls. ## Summary - Parse `COMFY_DYNAMICGROUP_V3` and resolve each repeated field from its template, including groups inside DynamicCombo options and refreshed combo choices. - Use ordinary field widgets and the existing value store, error handling and prompt serializer. A hidden count widget recreates rows before subsequent workflow values are restored; the count and presentation controls are excluded from the prompt. - Keep template `required`/`optional` flags independent of `min`. Apply `min`/`max` to add/remove controls, preserve imported overflow rows, and renumber surviving fields, auxiliary controls and input slots after removal. - Preserve the values of ordinary widgets before and after a group, saved input links, and undo/redo. Reuse saved input slots during restoration instead of adding duplicate slots. Restore populated rows during detached cloning, which clipboard copy/paste and Convert to Subgraph use, without accessing graph links before attachment. - Remove remote COMBO auxiliary controls and execution-success subscriptions with their owning row; ignore responses arriving after removal. - Expose each repeated row as a named accessible group and restore keyboard focus after deletion, skipping disabled controls. Show short field labels inside a row while retaining row-qualified accessible and promoted labels; refresh generated labels after a language change without overwriting custom labels. - Add a LoRA-shaped devtool node and focused unit tests. No production LoRA node is needed to exercise the contract. ## Node 2.0 scope DynamicGroup editing requires Modern Node Design. The canvas-specific row renderer has been removed; group headers, add/remove controls, repeated fields and auxiliary controls are excluded from legacy canvas rendering and layout using the existing widget surface policy. Shared row restoration and serialization remain active so switching renderers does not discard saved values. Each group displays one non-interactive `Node 2.0 only` notice on the legacy canvas, regardless of row count. The notice uses the existing Vue-only widget renderer and is excluded from workflow values and prompts. The stacked E2E PR covers this notice and switching back to Node 2.0 as well as storage and execution. ## API import: restoration before execution validation API import prioritizes restoring supplied content. Submitted DynamicGroup rows are recreated in encounter order with consecutive internal indices (for example, `1, 3` become `0, 1`), without allocating missing positions. A node with `max=5` still restores all six submitted rows, including through workflow save/reload. Add stays disabled at six and five rows; deleting down to four enables it again. Backend validation remains unchanged and can reject the restored six-row prompt. Restoring an API workflow and accepting it for execution are separate responsibilities. ## Workflow restoration across node changes Use the common positional or named widget restoration policy. In positional mode, saved values bind sequentially; missing values keep the current defaults, and excess values are unused. Adding or removing template fields does not make DynamicGroup reject the workflow, even when positional values shift across rows or no longer match the current widget type. Node authors remain responsible for schema migrations that preserve field meaning. The named-restore setting is unchanged. A separate pre-allocation bound rejects saved row counts exceeding both the configured maximum and the total number of saved widget values, without requiring a value for every current template field. ## Review focus The lifecycle decision is documented in `docs/adr/WIDGET-GROUP-0031-dynamic-group-widget-lifecycle.md`. Please focus on controller-before-fields restoration order and preservation of values and links when rows are renumbered. The implementation uses the existing workflow serialization format and activates when a node advertises the new input type; a separate feature flag is unnecessary for existing node definitions. ## Feature flag - **Flag**: None - **Reviewer request**: Please assess `flag-exempt` for this generic input contract. No exemption has been granted. Node definitions opt into DynamicGroup, but the PR also changes shared widget layout, remote-widget cleanup and input resolution, so capability opt-in alone does not isolate the entire diff. - **Validation**: Focused unit tests cover existing DynamicCombo, ordinary widget layout, prompt serialization and remote widgets. The stacked integration PR verifies the new contract against the companion backend. A rollout flag around only the DynamicGroup factory would not restore all shared behavior in the OFF path. - **Rollback**: Before exposing DynamicGroup nodes in Cloud, the frontend change can be reverted together with withholding the new node definitions. Once workflows use the new contract, disabling its renderer can impair restoration; a later rollback must coordinate node availability and workflow compatibility. Please review this limitation before approving an exemption. ## Backend and CI dependency The backend contract, [Comfy-Org/ComfyUI#16260 — feat: add DynamicGroup widget input](Comfy-Org/ComfyUI#16260), is merged. Real-backend browser tests and their fixture remain in the stacked draft [Comfy-Org#17510 — test: verify DynamicGroup against the companion backend](Comfy-Org#17510), pinned to the merged backend commit `2d2fa46e18d293ced1b958fe288730e2ef4b322e`. The default CI container still bundles ComfyUI `v0.30.0`, which does not include DynamicGroup, so the child retains its temporary override until the image is updated. Its three scenarios do not require the independent lazy-execution changes in [Comfy-Org/ComfyUI#16377 — fix: preserve dynamic input validation and lazy execution](Comfy-Org/ComfyUI#16377). This implementation PR has no backend override. ## Test plan - Enable Modern Node Design. With the companion backend and `tools/devtools` installed, add the `NodeWithDynamicGroup` devtool node. Add three rows, edit their values, remove the middle row, undo/redo, save and reopen, then queue and inspect Preview as Text. - Check zero-row execution and the static fields surrounding the group. With Modern Node Design disabled, each DynamicGroup should show one Node 2.0-only notice instead of editable controls; re-enable it to continue editing with the saved values. ## Provenance - **Clone regression verified at `69ce536b7c`:** `pnpm exec vitest run src/core/graph/widgets/dynamicGroupWidget.test.ts --maxWorkers=1` passed all 37 tests. Clipboard cloning and subgraph-conversion cloning both reproduced `NullGraphError` before the fix; the regressions now preserve two rows with edited values. Commit and push hooks passed. - **Latest review fixes:** Six directly related unit/component files passed (146 tests, `pnpm exec vitest run` with `--maxWorkers=1`). The locale regression file also passed after isolating its translation setup; after the label-flow refactor, the two affected files passed again (46 tests). Tests cover positional schema changes, locale-aware default labels, custom labels, short in-group labels, and full accessible/out-of-group labels. - **Development startup:** Reproduced the Vite native-ESM initialization error before the fix and verified the app boots afterward. Registered-widget validation now runs at the widget-construction boundary without a direct DynamicGroup-to-widgetStore import. - **Authored by:** interactive session. - **Verified after merging current main:** Eight directly related FE unit-test files, 296 passed and 1 existing skipped, using one worker. Object-info-parser: 48 passed. ADR validation passed. - **Regression proof:** Omitting DynamicGroup from main's new input-spec tree makes the search test fail. Declared `constructor` fields resolve at both the top level and inside a group; inherited properties remain excluded. - **Verified at `6032b46cfe`:** Commit format/lint/type checks and push-time Knip/Fallow passed. Fallow reports no introduced issues across the 33 changed files (eight inherited findings excluded by its existing gate). - **Browser coverage:** Three existing scenarios cover empty execution, edited rows with save/reopen and execution, and the legacy notice with renderer switching. CI on the updated child branch will verify them against the merged backend.
Summary
Implements
io.DynamicGroup(COMFY_DYNAMICGROUP_V3) — a backend-defined input type that lets nodes expose a stackable set of widget rows with add/remove controls, bounded bymin/maxdefined by the node author.Related PR: Comfy-Org/ComfyUI#14507
Changes
io.DynamicGroupnodes. A controller widget renders an "Add {group_name}" button; each group has a header with a remove (✕) button. Works on Vue Nodes 2.0. Row fields follow the flat key naming convention{groupId}.{rowIndex}.{fieldId}for prompt serialization. Rows are non-removable belowmin; the Add button dims and becomes inert atmax.Review Focus
dynamicGroupWidgetindynamicWidgets.ts— controller/header widget creation,addRow/removeRow/rebuildRowslogic, and theObject.definePropertyoncontroller.valuethat drives deserialization viawidgets_valuesremoveGroup— widgets and inputs are renamed in-place; group index is always derived fromwidget.name(never from a captured value) to avoid stale-index bugs after renumbering