comfyui-mcp 0.50.28 → 0.50.30

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -5573,7 +5573,7 @@ export function buildPanelToolDefs() {
5573
5573
  },
5574
5574
  },
5575
5575
  ])),
5576
- def("panel_add_node", "Add a node to the user's OPEN ComfyUI graph by class_type (e.g. 'KSampler', 'CheckpointLoaderSimple'). The user sees it appear live; Ctrl+Z undoes it. Returns the created node's id, slots, and default widget values. Frontend-only virtual types are addable too: 'Note' and 'MarkdownNote' — the supported way to ANNOTATE a workflow with on-canvas instructions (add the node, then put the text in its 'text' widget via panel_set_widget) — plus 'Reroute' and 'PrimitiveNode'. These are LiteGraph-native and never appear in the backend node registry, so they legitimately bypass the backend class_type check.", {
5576
+ def("panel_add_node", "Add a node to the user's OPEN ComfyUI graph by class_type (e.g. 'KSampler', 'CheckpointLoaderSimple'). The user sees it appear live; Ctrl+Z undoes it. Returns the created node's id, slots, and default widget values. Frontend-only virtual types are addable too: 'Note' and 'MarkdownNote' — the supported way to ANNOTATE a workflow with on-canvas instructions (add the node, then put the text in its 'text' widget via panel_set_widget) — plus 'Reroute' and 'PrimitiveNode'. These are LiteGraph-native and never appear in the backend node registry, so they legitimately bypass the backend class_type check. ADD NODES ONE AT A TIME, not as a parallel batch: each add carries a fresh /object_info payload and those register SERIALLY, so N concurrent adds become N sequential refresh cycles. On a large install that outruns the 30s per-command deadline and the later adds time out WHILE STILL QUEUED — they then apply when their turn arrives, leaving nodes you were told had failed (panel#767). Sequential adds each get the refresh to themselves and stay well inside the deadline.", {
5577
5577
  class_type: z.string().describe("Exact ComfyUI node class_type to create."),
5578
5578
  pos: xy()
5579
5579
  .optional()
@@ -7769,7 +7769,23 @@ export function buildPanelToolDefs() {
7769
7769
  "INSTEAD: unlike this panel-scoped restart, it is not tied to a browser tab " +
7770
7770
  "— it acts on the ComfyUI this server is configured for, which it CAN " +
7771
7771
  "identify and check before stopping. Or restart ComfyUI from whatever " +
7772
- "launches it (its own launcher, the Desktop app, or your terminal).",
7772
+ "launches it (its own launcher, the Desktop app, or your terminal)." +
7773
+ // artokun/comfyui-mcp-panel#769 — a REMOTE ComfyUI reached over a
7774
+ // tunnel or port-forward has a LOOPBACK host, and remoteUrlActive is
7775
+ // derived from exactly that (`forceRemote || !isLoopbackHost(host)`).
7776
+ // So a cloud pod fronted at 127.0.0.1:<port> classifies as LOCAL, this
7777
+ // branch runs, and it correctly reports it cannot find a local process
7778
+ // to account for — because there isn't one. The refusal is right about
7779
+ // what it observed and useless about what to do, since the reader is
7780
+ // looking for a local install that does not exist. Name the one setting
7781
+ // that re-classifies it; it is a config fix, not a workaround.
7782
+ " NOTE: if this ComfyUI is actually REMOTE but reached through a tunnel " +
7783
+ "or port-forward (a 127.0.0.1 address that is not this machine), it is " +
7784
+ "being classified as local because that classification reads the HOST — " +
7785
+ "which proves the route is local, not the instance. Set " +
7786
+ "COMFYUI_MCP_FORCE_REMOTE=1 (or pass --force-remote) and this tool takes " +
7787
+ "the remote path, which restarts through ComfyUI-Manager and does not " +
7788
+ "need a local process to account for.",
7773
7789
  });
7774
7790
  }
7775
7791
  if (preflightBound) {
@@ -7999,6 +8015,38 @@ export function buildPanelToolDefs() {
7999
8015
  // 3.x — #425, panel #253/#266) AND the target is a LOCAL, process-controllable
8000
8016
  // ComfyUI, fall back to the headless managed restart (kill + relaunch). A
8001
8017
  // busy-guard / security refusal is NOT eligible (rebootNoEndpoint excludes them).
8018
+ // #425 RECURRENCE (remote RunPod, 0.50.27). The managed fallback below is
8019
+ // LOCAL-ONLY and correctly does nothing here — there is no process on this
8020
+ // machine to restart. But falling through returned the bare "no reboot
8021
+ // endpoint … was NOT restarted", which is where the owner's report ended:
8022
+ // freshly installed custom nodes stayed unavailable "until a provider/host
8023
+ // restart", and nothing had told them a host restart was the requirement.
8024
+ //
8025
+ // Say what this target actually needs. We do NOT cycle the pod ourselves:
8026
+ // stop/resume bills, interrupts everything else on the box, and on a spot
8027
+ // instance may not come back — that is the user's call, not a side effect
8028
+ // of asking to restart ComfyUI.
8029
+ if (isRemoteMode() && rebootNoEndpoint(res)) {
8030
+ return ok({
8031
+ rebooting: false,
8032
+ ready: false,
8033
+ confirmed_cycle: false,
8034
+ note: `${toolResultText(res)}\n\n` +
8035
+ `This ComfyUI is REMOTE, so the managed restart that covers a local install ` +
8036
+ `does not apply — there is no process on this machine to cycle. A 405 from a ` +
8037
+ `Manager reboot route means that route is not registered on the running ` +
8038
+ `Manager (the frontend catchall answers every unregistered POST with 405), so ` +
8039
+ `it is a Manager version/dialect that exposes no reboot API rather than an ` +
8040
+ `auth failure.\n\n` +
8041
+ `WHAT WILL WORK: restart the HOST. Anything you just installed — custom nodes ` +
8042
+ `especially — stays unavailable until the ComfyUI process itself restarts, and ` +
8043
+ `nothing this MCP can reach will load it. On RunPod, runpod (action:"stop") ` +
8044
+ `then runpod (action:"start") with the pod_id cycles the box (stop ends ` +
8045
+ `billing; start bills again). Otherwise restart the container or provider ` +
8046
+ `however you normally would.\n\n` +
8047
+ `Do NOT report the newly installed nodes as ready: they are not loaded.`,
8048
+ });
8049
+ }
8002
8050
  if (!isRemoteMode() &&
8003
8051
  rebootNoEndpoint(res) &&
8004
8052
  // ENDPOINT BINDING: restartComfyUI() acts on the orchestrator's GLOBAL config