city96 / ComfyUI_NetDist

Run ComfyUI workflows on multiple local GPUs/networked machines.
Apache License 2.0
311 stars 30 forks source link

rename *job* to *event* in remote_control.py #6

Open picobyte opened 12 months ago

picobyte commented 12 months ago

If we want to allow cancel or interrupt, event better describes the action than a job

WIP

picobyte commented 12 months ago

or maybe I should work on the rewrite branch?

city96 commented 12 months ago

The rewrite branch is probably a better base to start from, it's substantially less jank. As promised, I'll work on it today, so I'd wait a bit before sending PRs.

The reason I used "job" is because that's what the backend uses internally - specifically job_id in the /history and /prompt endpoints.

My current best idea for getting cancel to work is to simply have a node that clears all IDs that start with netdist-, unless there's a way to notify all (already executed/pending/etc) custom nodes about when a workflow is interrupted (I don't think there is?.

The queue on remote node could run this clear remote operation automatically as well, though maybe the job_id would need a short UUID part for that so as to still work with multiple people using the same remote backend.