Has Value (Any)
The tiny gate that asks 'is this socket actually wired?'
- value
- has_value
Has Value (Any) is a one-trick node, and the trick is quietly load-bearing: it takes any value you throw at it and outputs a BOOLEAN telling you whether that value exists. One input, one output, no settings. It's the ComfyUI equivalent of if (x is not None) - and once you've wired one, you'll start seeing all the places you needed it.
What counts as "has a value"
The node outputs true when the value input is present (not None), and false when it isn't. That's the entire contract, and its usefulness comes entirely from what you do with the boolean. Because the input is the * any-type socket, you can point it at almost anything - a STRING, an image, a mask, an IPT-IMAGEINFO bundle - and ask the same question.
This slots into the ecosystem's switch and condition patterns. The pack ships alongside nodes like Any Switch and Optional Switch that pick between branches, and Has Value (Any) is the natural companion: a fallback branch feeds one input, the real value feeds another, and the boolean decides which to pass. It's the same family of graph-cleaning ideas that makes utility packs like rgthree-comfy indispensable, except this one doesn't need a bundle - it just answers one question.
Where you'll actually use it
Three spots come up constantly:
- Fallbacks. Feed a possibly-empty value and a default, switch on the boolean, get a guaranteed value. This pairs naturally with the pack's
Image Info Fallbackand the extras getters, which returnNonefor missing keys. - Conditional branches. Only run a detailer or upscaler if there's actually something to process. Wire the boolean into the switch controlling that branch.
- Debugging. A single
Has Valuenode staring at a socket that "should" have data tells you in one glance whether the upstream node actually ran. When a workflow silently skips a step, this is a faster probe than console logs.
The honest limits
It checks for existence, not validity. An empty string "" is still a value, so Has Value returns true for it - if you care whether text is non-empty, you need to normalize first. Same deal for a zero-length list or a 1×1 image; the node doesn't judge, it just reports whether the socket carried something. That's a feature when you're gating on None, and a trap when you assume "has value" means "useful."
Installing it
Part of the ComfyUI-Info-Prompt-Toolkit pack. ComfyUI Manager - search "Info Prompt Toolkit" - or:
cd ComfyUI/custom_nodes
git clone https://github.com/kinorax/comfyui-info-prompt-toolkit.git
cd comfyui-info-prompt-toolkit
pip install -r requirements.txt
Restart ComfyUI. No model downloads. It's a small single-author pack (GPL-3.0), and this is one of those nodes that looks trivial until your workflow stops working mysteriously and the culprit turns out to be a None flowing where you expected data.
Inputs (1)
| Name | Type | Default | Description |
|---|---|---|---|
| valueopt | * | — |
Outputs (1)
| Name | Type | Description |
|---|---|---|
| has_value | BOOLEAN | — |