Compare commits
2
Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
5423b4ee6f | ||
|
|
2c1656756d |
+9
-9
@@ -1280,7 +1280,7 @@ async def send_json_override(self, event, data, sid=None):
|
|||||||
if prompt_id in prompt_metadata:
|
if prompt_id in prompt_metadata:
|
||||||
prompt_metadata[prompt_id].start_time = time.perf_counter()
|
prompt_metadata[prompt_id].start_time = time.perf_counter()
|
||||||
|
|
||||||
await update_run(prompt_id, Status.RUNNING)
|
asyncio.create_task(update_run(prompt_id, Status.RUNNING))
|
||||||
|
|
||||||
|
|
||||||
if event == "executing" and data and CURRENT_START_EXECUTION_DATA:
|
if event == "executing" and data and CURRENT_START_EXECUTION_DATA:
|
||||||
@@ -1320,10 +1320,10 @@ async def send_json_override(self, event, data, sid=None):
|
|||||||
])
|
])
|
||||||
|
|
||||||
prompt_id = data.get("prompt_id")
|
prompt_id = data.get("prompt_id")
|
||||||
await update_run_with_output(
|
asyncio.create_task(update_run_with_output(
|
||||||
prompt_id,
|
prompt_id,
|
||||||
node_execution_array, # Send the array instead of the OrderedDict
|
node_execution_array, # Send the array instead of the OrderedDict
|
||||||
)
|
))
|
||||||
|
|
||||||
print(node_execution_array)
|
print(node_execution_array)
|
||||||
|
|
||||||
@@ -1342,11 +1342,11 @@ async def send_json_override(self, event, data, sid=None):
|
|||||||
if prompt_metadata[prompt_id].start_time is not None:
|
if prompt_metadata[prompt_id].start_time is not None:
|
||||||
elapsed_time = current_time - prompt_metadata[prompt_id].start_time
|
elapsed_time = current_time - prompt_metadata[prompt_id].start_time
|
||||||
logger.info(f"Elapsed time: {elapsed_time} seconds")
|
logger.info(f"Elapsed time: {elapsed_time} seconds")
|
||||||
await send(
|
asyncio.create_task(send(
|
||||||
"elapsed_time",
|
"elapsed_time",
|
||||||
{"prompt_id": prompt_id, "elapsed_time": elapsed_time},
|
{"prompt_id": prompt_id, "elapsed_time": elapsed_time},
|
||||||
sid=sid,
|
sid=sid,
|
||||||
)
|
))
|
||||||
|
|
||||||
if event == "executing" and data.get("node") is not None:
|
if event == "executing" and data.get("node") is not None:
|
||||||
node = data.get("node")
|
node = data.get("node")
|
||||||
@@ -1370,7 +1370,7 @@ async def send_json_override(self, event, data, sid=None):
|
|||||||
prompt_metadata[prompt_id].last_updated_node = node
|
prompt_metadata[prompt_id].last_updated_node = node
|
||||||
class_type = prompt_metadata[prompt_id].workflow_api[node]["class_type"]
|
class_type = prompt_metadata[prompt_id].workflow_api[node]["class_type"]
|
||||||
logger.info(f"At: {round(calculated_progress * 100)}% - {class_type}")
|
logger.info(f"At: {round(calculated_progress * 100)}% - {class_type}")
|
||||||
await send(
|
asyncio.create_task(send(
|
||||||
"live_status",
|
"live_status",
|
||||||
{
|
{
|
||||||
"prompt_id": prompt_id,
|
"prompt_id": prompt_id,
|
||||||
@@ -1378,10 +1378,10 @@ async def send_json_override(self, event, data, sid=None):
|
|||||||
"progress": calculated_progress,
|
"progress": calculated_progress,
|
||||||
},
|
},
|
||||||
sid=sid,
|
sid=sid,
|
||||||
)
|
))
|
||||||
await update_run_live_status(
|
asyncio.create_task(update_run_live_status(
|
||||||
prompt_id, "Executing " + class_type, calculated_progress
|
prompt_id, "Executing " + class_type, calculated_progress
|
||||||
)
|
))
|
||||||
|
|
||||||
if event == "execution_cached" and data.get("nodes") is not None:
|
if event == "execution_cached" and data.get("nodes") is not None:
|
||||||
if prompt_id in prompt_metadata:
|
if prompt_id in prompt_metadata:
|
||||||
|
|||||||
@@ -1,4 +0,0 @@
|
|||||||
/** @typedef {import('../../../web/scripts/api.js').api} API*/
|
|
||||||
import { api as _api } from '../../scripts/api.js';
|
|
||||||
/** @type {API} */
|
|
||||||
export const api = _api;
|
|
||||||
@@ -1,4 +0,0 @@
|
|||||||
/** @typedef {import('../../../web/scripts/app.js').ComfyApp} ComfyApp*/
|
|
||||||
import { app as _app } from '../../scripts/app.js';
|
|
||||||
/** @type {ComfyApp} */
|
|
||||||
export const app = _app;
|
|
||||||
+7
-6
@@ -1,8 +1,11 @@
|
|||||||
import { app } from "./app.js";
|
import { app } from "../../scripts/app.js";
|
||||||
import { api } from "./api.js";
|
import { api } from "../../scripts/api.js";
|
||||||
import { ComfyWidgets, LGraphNode } from "./widgets.js";
|
// import { LGraphNode } from "../../scripts/widgets.js";
|
||||||
|
LGraphNode = LiteGraph.LGraphNode;
|
||||||
|
import { ComfyDialog, $el } from "../../scripts/ui.js";
|
||||||
|
|
||||||
import { generateDependencyGraph } from "https://esm.sh/[email protected]";
|
import { generateDependencyGraph } from "https://esm.sh/[email protected]";
|
||||||
import { ComfyDeploy } from "https://esm.sh/comfydeploy@0.0.19-beta.30";
|
import { ComfyDeploy } from "https://esm.sh/comfydeploy@2.0.0-beta.69";
|
||||||
|
|
||||||
const styles = `
|
const styles = `
|
||||||
.comfydeploy-menu-item {
|
.comfydeploy-menu-item {
|
||||||
@@ -1287,8 +1290,6 @@ function addButton() {
|
|||||||
|
|
||||||
app.registerExtension(ext);
|
app.registerExtension(ext);
|
||||||
|
|
||||||
import { ComfyDialog, $el } from "../../scripts/ui.js";
|
|
||||||
|
|
||||||
export class InfoDialog extends ComfyDialog {
|
export class InfoDialog extends ComfyDialog {
|
||||||
constructor() {
|
constructor() {
|
||||||
super();
|
super();
|
||||||
|
|||||||
@@ -1,18 +0,0 @@
|
|||||||
// /** @typedef {import('../../../web/scripts/api.js').api} API*/
|
|
||||||
// import { api as _api } from "../../scripts/api.js";
|
|
||||||
// /** @type {API} */
|
|
||||||
// export const api = _api;
|
|
||||||
|
|
||||||
/** @typedef {typeof import('../../../web/scripts/widgets.js').ComfyWidgets} Widgets*/
|
|
||||||
import { ComfyWidgets as _ComfyWidgets } from "../../scripts/widgets.js";
|
|
||||||
|
|
||||||
/**
|
|
||||||
* @type {Widgets}
|
|
||||||
*/
|
|
||||||
export const ComfyWidgets = _ComfyWidgets;
|
|
||||||
|
|
||||||
// import { LGraphNode as _LGraphNode } from "../../types/litegraph.js";
|
|
||||||
|
|
||||||
/** @typedef {typeof import('../../../web/types/litegraph.js').LGraphNode} LGraphNode*/
|
|
||||||
/** @type {LGraphNode}*/
|
|
||||||
export const LGraphNode = LiteGraph.LGraphNode;
|
|
||||||
Reference in New Issue
Block a user