Comfy-Org / Comfy-Org/ComfyUI_frontend

Pass legacy SubgraphNode widgets_values explicitly during configure

Open
#11,742 0 comments 0 reactions 0 assignees View on GitHub
area:subgraph
Dominant language
TypeScript
Stars
2k
Forks
699
Avg merge
1d 7h
Merged PRs (30d)
490

Description

Follow-up from #11559 and DrJKL's review.

Current state:
- `src/lib/litegraph/src/subgraph/SubgraphNode.ts:1058` stores legacy `widgets_values` in `_pendingLegacyWidgetsValues` before calling `super.configure()`.
- `src/lib/litegraph/src/subgraph/SubgraphNode.ts:1146` and `src/lib/litegraph/src/subgraph/SubgraphNode.ts:1195` read that temporary field during post-slot hydration.
- `src/lib/litegraph/src/subgraph/SubgraphNode.ts:1113` clears it in `finally`.

Goal:
- Pass legacy `widgets_values` explicitly through the configure/hydration path instead of temporarily storing it on the instance.
- Keep the #11559 legacy migration behavior and warning behavior intact.

Why:
- The field is a covert parameter used only during one configure call. Making it explicit reduces action-at-a-distance and future callback coupling.

┆Issue is synchronized with this [Notion page](https://app.notion.com/p/Issue-11742-Pass-legacy-SubgraphNode-widgets_values-explicitly-during-configure-3516d73d365081759d09c5d0ae11b847) by [Unito](https://www.unito.io)

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.