ComfyUI Node

Motorway 7x8

The first fan-out, where the off-ramps outnumber the on-ramps

By agilly1989Β·Created 2 years agoΒ·Updated about a year agoΒ· 7
Motorway 7x8
  • MOTORWAY πŸšŒπŸ’¨
  • ANY_(A)
  • ANY_(B)
  • ANY_(C)
  • ANY_(D)
  • ANY_(E)
  • ANY_(F)
  • ANY_(G)
  • MOTORWAY πŸšŒπŸ’¨
  • ANY (A)
  • ANY (B)
  • ANY (C)
  • ANY (D)
  • ANY (E)
  • ANY (F)
  • ANY (G)
  • ANY (H)
β—„ANY_(A)_keyβ€”β–Ί
β—„ANY_(B)_keyβ€”β–Ί
β—„ANY_(C)_keyβ€”β–Ί
β—„ANY_(D)_keyβ€”β–Ί
β—„ANY_(E)_keyβ€”β–Ί
β—„ANY_(F)_keyβ€”β–Ί
β—„ANY_(G)_keyβ€”β–Ί
β—„ANY_(H)_keyβ€”β–Ί

Motorway 7x8 is where the Motorway family starts to fan out. Seven inputs, eight outputs - more off-ramps than on-ramps, which tells you what it's for: a node that spreads the values already riding on the bus to eight different places. It's part of ComfyUI_agilly1989_motorway, a small pack that implements a "pipe" for ComfyUI, where a named-value dictionary rides a single MOTORWAY πŸšŒπŸ’¨ wire through your graph.

The thing to remember about any Motorway node is that inputs write and outputs read, and they're independent. So a 7x8 doesn't mean "plug in seven, get eight copies." It means "attach up to seven new values, and pull up to eight existing values off" - the eight outputs can be keys written anywhere earlier in the graph. That makes 7x8 the natural hub right before a stage that needs to send signals in many directions: a big sampling block, a tiled upscaler, a bundle of preview/save nodes.

How it works

The bus is a dict-like object, keys stored as sha256 hashes of the names you type. Each Motorway node writes connected inputs onto the bus under their _key names, clones the bus, and emits the clone plus one output per non-empty output key, each looking up its own key. Cloning means nothing mutates in place and values persist downstream until overwritten by a later write to the same key.

One quirk specific to nodes where outputs outnumber inputs: the key fields are generated up to the larger of the two counts. So 7x8 has seven input sockets but eight _key fields - ANY (A)_key through ANY (H)_key. The extra key fields exist to drive the output sockets, which is fine and expected, just slightly surprising the first time you open it.

The inputs and outputs that matter

  • MOTORWAY πŸšŒπŸ’¨ - required bus input and output.
  • ANY (A) through ANY (G) - seven inputs; each with a _key field for naming what you attach.
  • ANY (A) through ANY (H) - eight outputs; each with a _key field. The keys you type here are lookups into the bus.

Fill output keys A through H in order, because an empty key makes that socket emit nothing and shifts everything after it up a position. Positional outputs plus optional keys is the one genuinely fiddly bit of this design.

Installing it

cd ComfyUI/custom_nodes
git clone https://github.com/agilly1989/ComfyUI_agilly1989_motorway

Restart ComfyUI, or use ComfyUI Manager (search "motorway"). No pip dependencies, no model downloads - it's pure Python, and the whole ~120-node Motorway family installs at once.

Common issues

  • 'MotorwayClass' object has no attribute 'hash_' - a read key doesn't exist on the bus yet. Spelling and case matter; keys are exact.
  • Output socket shift with gaps - leave ANY (A)_key blank and the value from ANY (B)_key comes out socket A. Keep them in order.
  • Beta, author-broken disclaimer included. The README warns it's broken with async and that the author "will fix when I get the time/motivation." Works fine for normal runs, just know the caveats.
Categoryagilly1989 Nodes/Motorways

Inputs (16)

NameTypeDefaultDescription
MOTORWAY πŸšŒπŸ’¨MOTORWAY πŸšŒπŸ’¨β€”
ANY_(A)opt*β€”
ANY_(B)opt*β€”
ANY_(C)opt*β€”
ANY_(D)opt*β€”
ANY_(E)opt*β€”
ANY_(F)opt*β€”
ANY_(G)opt*β€”
ANY_(A)_keyoptSTRINGβ€”
ANY_(B)_keyoptSTRINGβ€”
ANY_(C)_keyoptSTRINGβ€”
ANY_(D)_keyoptSTRINGβ€”
ANY_(E)_keyoptSTRINGβ€”
ANY_(F)_keyoptSTRINGβ€”
ANY_(G)_keyoptSTRINGβ€”
ANY_(H)_keyoptSTRINGβ€”

Outputs (9)

NameTypeDescription
MOTORWAY πŸšŒπŸ’¨MOTORWAY πŸšŒπŸ’¨β€”
ANY (A)*β€”
ANY (B)*β€”
ANY (C)*β€”
ANY (D)*β€”
ANY (E)*β€”
ANY (F)*β€”
ANY (G)*β€”
ANY (H)*β€”