mergeIncomingSubgraphDefinitions was speculative: it tried
app.subgraphService.loadSubgraphs (which doesn't exist on the official
ComfyUI frontend — useSubgraphService() is a Vue/Pinia composition
function only invoked from inside app.loadGraphData), then fell back
to direct mutation of app.graph.definitions.subgraphs (which doesn't
register the UUID with LiteGraph.registered_node_types and so doesn't
help the pre-flight check below).
Honest scope:
- serializeSelection still carries definitions.subgraphs so a saved
selection containing a subgraph wrapper round-trips correctly through
native Load (which DOES call useSubgraphService().loadSubgraphs and
registers).
- The subgraph-aware pre-flight error stays. It directs the user to
native-Load the file once (which registers the UUID), then retry
Insert. After that, all subsequent Inserts of files referencing the
same UUID work normally.
The "transparent fresh-session Insert" goal would require a public
extension API for subgraph registration that the frontend doesn't yet
expose. Tracked as a follow-up note in the issue.