ComfyUI Node Runs on cloud

Int debug print

Dump an integer to the console with a label

By Derfuu·Created 3 years ago·Updated 2 years ago· 455
Int debug print
      Prefix
      Value1

      When a dimension math chain gives you the wrong number, you want to know what number, and where. Int debug print is the tiny node for that: give it an integer and a text prefix, and it prints prefix: value to the ComfyUI console when the graph runs. It's a sink - nothing comes out the other side - so you hang it off whatever integer you're suspicious of and read the terminal.

      How it works

      It takes an INT plus a label string and writes them to standard output (your console/terminal) during execution. The prefix is there so that when you've got three of these scattered around a graph, you can tell which is which in the log instead of staring at three bare numbers. Being an output node, it runs on its own without needing anything downstream.

      The inputs and outputs that matter

      • Prefix (STRING) - a label printed before the value, so latent width beats an anonymous 768 in the log.
      • Value (INT) - the integer to print.
      • No outputs - this is a terminal debug sink, not a pass-through.

      Where it fits

      Use it to verify the integers flowing through Derfuu math before they hit something expensive. Computed a width from MultiplyInteger? Tap it here and confirm it's 1024 and not 1023 before the sampler burns time on the wrong size. Because it prints to the console rather than a widget, it's handy when you're watching logs anyway. If you'd rather see the value on the canvas - or inspect a non-integer type - Derfuu's To text (Debug) node shows any type in a widget and passes it through, which is often the friendlier choice.

      How to install it

      ComfyUI Manager: search Derfuu_ComfyUI_ModdedNodes, install, restart. Manual:

      cd ComfyUI/custom_nodes
      git clone https://github.com/Derfuu/Derfuu_ComfyUI_ModdedNodes
      

      then restart. No dependencies, no models - plain Python.

      Common issues & troubleshooting

      You don't see the output. It prints to the console where ComfyUI is running, not to the browser UI. If you launched via a desktop app or a service, you may need to open the terminal/log window to see it. And it only prints when the node actually executes - if it's on a branch that got pruned, nothing.

      It won't take your value. The input is typed INT. Feeding a FLOAT needs a conversion first (Integer, Ceil, or Floor); feeding a string obviously won't work - use String debug print for that.

      It's a dead end and you wanted to keep the value. By design there's no output. If you need to inspect and keep wiring, use To text (Debug), which passes the input through.

      Node missing after a pack update. Derfuu has deleted deprecated nodes on updates rather than keeping them, so old graphs can point at gone names - reconnect a fresh copy. A ModuleNotFoundError about Derfuu_ComfyUI_ModdedNodes_legacy means a duplicated folder; keep one named Derfuu_ComfyUI_ModdedNodes.

      CategoryDerfuu_Nodes/Debug

      Inputs (2)

      NameTypeDefaultDescription
      PrefixSTRING
      ValueINT1-9223372036854776000–9223372036854776000

      Outputs (0)

      No outputs