Nodes/Comfyui-EzFlex-Presets/EzFlex-NodeSwitchGroup
ComfyUI Node

EzFlex-NodeSwitchGroup

Mute a Whole Region of Your Graph by Name or Color

By blackbossokok·Created 20 days ago·Updated about 15 hours ago· 1
EzFlex-NodeSwitchGroup
      config{}

      Large workflows have two lives. There's the "my good 2K img2img branch" life and the "let me try the video one" life, and both live on the same canvas because deleting a branch to test another is a miserable way to work. The classic answer is to select the nodes and hit Ctrl+M. The better answer is a switch panel that remembers which regions are on.

      EzFlex-NodeSwitchGroup is that panel. Switches in the list get matched to canvas groups, and flipping a switch sets the matched nodes' node.mode - 0 for on, 2 for mute, 4 for bypass. If you know rgthree's Fast Groups Muter and Fast Groups Bypasser, you already understand the shape; the pack's own source comment cites them as the reference.

      How the matching works

      This is where it differs from the rgthree tools, and it's the part worth reading twice. A switch doesn't hold a list of node ids - it holds a match rule, and the rule is either a group's title or a group's color, including groups inside subgraphs. So the switch named "video branch" follows whatever group is called that, even after you add three nodes to it, and the color rule lets you tag regions by hue instead of naming conventions.

      The switches themselves live in config: a JSON blob, written by the panel, holding the switch list, the match rules and the current preset name. There's also an auto-sort for the switch cards (by canvas position or by name), which matters once you have more than about six of them.

      Inputs and outputs: there are none

      Be clear about this before downloading it. The node has exactly one input, config (STRING, multiline, default "{}"), and its tooltip gives the game away: "Config JSON produced by the Node Switch Group panel (switch list / match rules / current preset)." The Python side is:

      def run(self, config="{}", **kwargs):
          return ()
      

      No outputs. You do not wire this node into anything and you cannot use it to branch data. It is a control surface that reaches into the canvas and flips other nodes' mode flags. Intent-lowering: it can't mute things that aren't matched by a rule, so a loose node you forgot to group stays on forever, silently feeding the graph.

      Named presets - combinations of switch states - are saved and stored per node instance, which has a real gotcha attached: deleting the node takes its presets with it. Save the presets you care about before you tidy up the canvas.

      Install

      Search EzFlex in ComfyUI Manager, or:

      cd ComfyUI/custom_nodes
      git clone https://github.com/blackbossokok/Comfyui-EzFlex-Presets
      pip install -r requirements.txt   # mutagen - the pack's only mandatory requirement
      

      Restart ComfyUI, then add the node from the EzFlex category and drag it somewhere out of the way. No models, no API keys. The pack asks for ComfyUI 0.3.13+ in its metadata because it uses the official i18n endpoint for its panel strings.

      Common issues

      A switch toggles nothing. The rule didn't match. Title matching is exact-ish on the group's title and color matching is by the group's color, and a group created after you wrote the rule still matches as long as it has that title or color. Groups inside subgraphs are included, which is usually the answer to "it worked before I collapsed that region."

      Nodes visually muted but still executing. Mute and bypass are different modes: mute (2) starves the node of inputs, bypass (4) passes through. If a branch still produces output, check which of the three states the switch is actually applying.

      Presets gone after deleting the node. Documented behavior - presets are per node instance. This is also the reason EzFlex-NodeSwitchMaster exists: it keeps a master map of "this group node → that preset", so you can keep the switches and re-flip the whole set in one go.

      Panel is unresponsive or blank. This node's controls are a hand-rolled DOM panel, which puts it in the same fragile class as rgthree's dashboard nodes under ComfyUI's Nodes 2.0 frontend rewrite. If the buttons die on you, the legacy canvas is still the community's standing workaround.

      Worth saying plainly: the pack is new - one author, MIT, first released September 2026, version around v1.2.5. Its own changelog is the best bug list you'll find, and V1.2.2 already fixed a broken preset dropdown in exactly this node.

      CategoryEzFlex

      Inputs (1)

      NameTypeDefaultDescription
      configSTRING{}Config JSON produced by the Node Switch Group panel (switch list / match rules / current preset).

      Outputs (0)

      No outputs