YJpause
Drop a real breakpoint on any ComfyUI wire
- value
- value
ComfyUI has one big gap compared to a normal program: once you hit Queue, the whole graph runs to the end and there's no clean way to stop halfway and look. YJpause is the missing breakpoint. You splice it onto any data wire, it freezes execution at that exact spot, and hands you three buttons - continue, restart, or stop. It's the node from the YJNodes pack that turns a one-shot pipeline into something you can babysit.
Why would you bother? Picture the classic two-phase workflow: generate a frame, then run the expensive upscale or video pass. Normally you build both halves, queue, and hope. With YJpause between them you get a real decision point - look at what came out, and only green-light the pricey half if it's worth it. Same idea for a workflow you hand to someone who isn't you: they generate, approve the image, then the latent-video or upscale stage runs. It's also quietly useful for debugging, since a paused graph is a graph you can poke at before the next stage clobbers it.
How it works
Under the hood YJpause is a passthrough node with a wildcard type, so it sits on any connection - image, latent, conditioning, model, you name it. When execution reaches it and enabled is on, the server registers a pause session and the executor simply blocks in a wait loop. Nothing is processed or copied; the value you feed in is exactly the value that comes out the other side. If you hit Cancel in ComfyUI's top bar while it's paused, that still works - the wait loop watches for the global interrupt, so you're never trapped.
Two implementation details matter. The node reports itself as always changed when enabled (IS_CHANGED returns NaN), so ComfyUI can't skip it as "already ran." And the pause state lives server-side in a session registry, which is why refreshing the page while paused restores the node's status and buttons instead of silently losing your spot. The node also adapts its shown connection type to whatever's actually wired in, even though the schema type is *.
The inputs that matter
Just three, and you mostly touch two:
- value - the data wire. Feed anything in, get the identical thing out.
- enabled - a toggle, on by default. Flip it off and YJpause becomes a dumb connector: data passes straight through, no pause. Handy when you want to keep the node in a shared workflow but stop it interrupting.
- timeout_minutes -
0(default) means wait forever. Set a positive number and the job auto-stops when the clock runs out, which is your failsafe for walking away from the queue.
The output is value, wired straight into whatever consumed the node's input.
Continue, restart, or stop
When paused, the node highlights and shows a countdown plus three actions. The differences matter:
- Continue resumes in place - the current execution state is kept and downstream just runs. This is the one you'll use most.
- Restart kills the current job and re-submits the whole workflow from the top. Models reload, everything regenerates. Only reach for it if the upstream genuinely needs redoing - it's the expensive option.
- Stop kills just this job. Nothing re-runs.
You can drop several YJpauses in one workflow; each enabled one pauses in turn as execution reaches it.
Installing it
The usual two routes, and this pack has no Python dependencies to babysit:
# ComfyUI Manager: search "ComfyUI-YJNodes" and install
# or by hand:
cd ComfyUI/custom_nodes
git clone https://github.com/yujianvip/ComfyUI-YJNodes
Then restart ComfyUI (or hit "reload" if you're on a version that supports it) so the frontend picks up the node's JS. Requires Python 3.10+.
Gotchas
The big one is conceptual: a pause freezes the whole queue, not just this workflow - that blocking wait is the entire point, so don't leave a paused job queued overnight without a timeout. A couple of smaller things: if the node never pauses, check that enabled is actually on; and while YJpause itself is bilingual (it follows ComfyUI's language setting, defaulting to English outside Chinese locales), some other parts of the pack - like the completion-sound settings - are still Chinese-only labels. Cosmetic, but it surprises people the first time they open settings. YJNodes is a young pack from a solo author, so treat it as a small, sharp tool rather than an ecosystem - and for that one job, it genuinely has no direct competitor in the stock install.
Inputs (3)
| Name | Type | Default | Description |
|---|---|---|---|
| value | * | — | |
| enabled | BOOLEAN | true | — |
| timeout_minutes | INT | 00–525600 | — |
Outputs (1)
| Name | Type | Description |
|---|---|---|
| value | * | — |