comfyui-mcp 0.52.178 → 0.52.180

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.
@@ -1338,7 +1338,7 @@ function isWorkerTransportRetrySafeCmd(cmd) {
1338
1338
  // This is an EXPLICIT ALLOWLIST, deliberately NOT "everything not read-only":
1339
1339
  // several genuine reads/probes/views that flow through ctx.call are absent from
1340
1340
  // BRIDGE_READONLY_CMDS (e.g. graph_list_subgraphs, training_get_state,
1341
- // graph_canvas, graph_screenshot), so an exclusion rule would wrongly make THOSE
1341
+ // graph_canvas), so an exclusion rule would wrongly make THOSE
1342
1342
  // wait out the reconnect budget. Under-inclusion here is at worst an unfixed edge
1343
1343
  // (a command keeps today's behavior); over-inclusion would regress a read — so we
1344
1344
  // list only commands that unambiguously mutate the graph. Keep in sync when new
@@ -21432,8 +21432,39 @@ CHECKED FOR YOU: the graph read this message prescribes was just run, and it ` +
21432
21432
  // never carries the token (a ledger answer for a read is a STALE
21433
21433
  // outcome), and the withRetryToken wrapper can't reach this direct send.
21434
21434
  { cmd: "graph_screenshot", padding: args.padding }, target ?? { mode: "current" });
21435
+ // panel#2191 — the SAME bounded budget the sibling idempotent reads
21436
+ // already take, for the same reason and against the same evidence.
21437
+ //
21438
+ // A screenshot's cost scales with the graph: the frontend handler forces
21439
+ // one synchronous LiteGraph repaint of every node and group at the fitted
21440
+ // transform, PNG-encodes the result, and repaints again on restore — all
21441
+ // on the panel's single main thread. Dispatched with no `timeoutMs` it
21442
+ // took the bare 20 000 ms default, and a reporter's 264-node / 63-group
21443
+ // graph was declared "backgrounded or frozen" on a tab that, in the same
21444
+ // session, answered panel_query_graph, panel_get_errors over all 264
21445
+ // nodes, and panel_save_workflow. That is a busy-but-alive main thread,
21446
+ // which is precisely what graph_get_errors' own budget comment describes
21447
+ // — and graph_get_errors survived that graph because it already passes
21448
+ // this constant while the screenshot alone was left on the default.
21449
+ //
21450
+ // Safe to widen because the read is idempotent (see the panel#2191 entry
21451
+ // in BRIDGE_READONLY_CMDS): waiting longer costs a slow reply, never a
21452
+ // double-applied write. Still BOUNDED, never Infinity, so a genuinely
21453
+ // frozen tab fails — at 90 s instead of 20 s.
21454
+ //
21455
+ // ONE-SHOT ACROSS RECONNECTS, deliberately — and still so after #2761.
21456
+ // Being a read makes this command eligible for the bridge's
21457
+ // park-and-resume. That resume now requires the returning connection to
21458
+ // PROVE it is the tab that issued the read (#2761), so the wrong-canvas
21459
+ // outcome this originally guarded against is closed at the bridge for
21460
+ // every command in the set, not just this one. The budget stays zero
21461
+ // regardless: a capture is free to re-ask, so it gains nothing from
21462
+ // resuming, and keeping it out of the branch entirely means this call
21463
+ // site does not depend on that rule staying correct.
21435
21464
  const res = (await ctx.bridge.send(cmd, {
21436
21465
  tabId: ctx.tabId,
21466
+ timeoutMs: OBJECT_INFO_REFRESH_ACK_TIMEOUT_MS,
21467
+ maxReconnectRetries: 0,
21437
21468
  }));
21438
21469
  if (!res?.image)
21439
21470
  return fail("screenshot returned no image");