ComfyUI Node

AllowPass

A data gate that lets you kill a branch of your workflow without deleting a single wire

By mittimi·Created 7 months ago·Updated 6 months ago· 0
AllowPass
  • AnyData
  • AnyData
Passtrue

AllowPass is a gate for any data type. Flip Pass to true and whatever you feed in comes out the other side untouched. Flip it to false and the node returns nothing - the branch it feeds effectively goes dark. It's ComfyUI's closest thing to pulling a wire, except you don't have to pull it.

The name makes it sound fancier than it is. This isn't a permissions system or a security check, it's an on/off valve. It just happens to work with any data type, which is the clever bit: ComfyUI's "any" wildcard type means the same gate carries a model, a latent, an image, conditioning, or a string without you choosing a type up front.

Why you'd actually reach for it

ComfyUI has no built-in "disable this connection" button. You can mute or bypass whole nodes, but that's a hammer when you want a scalpel. AllowPass sits between nodes, so you can keep everything wired and switch a section off for a test run.

The pattern I reach for: two competing setups - say a plain img2img pass versus a detailer - where I want to A/B them without rebuilding the graph. Gate one branch with AllowPass, run with Pass on, then turn it off and you've effectively disconnected that whole side. No deleting, no re-wiring, instant rollback.

It's also handy for toggling optional steps - an extra upscale, a LoRA chain, a second pass - on and off while you dial in a workflow.

How it works

The whole logic is about six lines:

def allowPassMittimi(self, Pass, AnyData):
    return_data = None
    if Pass:
        return_data = AnyData
    return (return_data, )

True means passthrough, false means None. One honest caveat: when it's off, whatever it feeds gets None, and most downstream nodes will choke on that rather than gracefully skip. Treat "off" as "this branch errors out on purpose" - the node is a disconnect switch, not a conditional that reroutes around the dead branch. If you want a real "pick one of two" switch, look at something like rgthree's Any Switch instead.

The inputs that matter

There are only two, and one of them is obvious:

  • Pass - the toggle. Defaults to true, so the node passes data through the moment you add it.
  • AnyData - the thing you're gating. Wire whatever node's output you want to control into this.

The output is also called AnyData, and it carries whatever type you sent in. Wire it to the next node in the branch you're toggling.

Installing it

This ships in mittimi/ComfyUI_mittimiTools, a tiny personal "some tools" pack by mittimi (the README is literally two lines). Install it like any custom node:

cd ComfyUI/custom_nodes
git clone https://github.com/mittimi/ComfyUI_mittimiTools

Then restart ComfyUI. Or, easier, use ComfyUI Manager - search for ComfyUI_mittimiTools and hit Install. The only Python dependency is toml, which ComfyUI already ships, so there's no extra install step and no model downloads.

The honest troubleshooting section

There's not much to break here. The one thing people get burned by is expecting the "off" output to be a harmless empty value - it isn't, it's None, and the next node will usually throw a type error. Design around that: put AllowPass on the source side of a branch you're willing to see error out, or gate something that tolerates a None. Also worth knowing: this pack is small and barely updated, with essentially no docs or community chatter, so if something behaves oddly, your options are reading the (short) source or swapping in a more supported switch node.

CategorymittimiTools

Inputs (2)

NameTypeDefaultDescription
PassBOOLEANtrue
AnyData*

Outputs (1)

NameTypeDescription
AnyData*