Nodes/AsyncOutput/AsyncOutput[module_config] Global Auto Reset
ComfyUI Node

AsyncOutput[module_config] Global Auto Reset

The switch that decides whether AsyncOutput forgets everything between runs

By teddy1565·Created 5 months ago·Updated 5 months ago· 0
AsyncOutput[module_config] Global Auto Reset
    • AsyncOutputModule_AutoReset
    global_auto_resettrue

    AsyncOutput[module_config] Global Auto Reset (class AsyncOutputGlobalAutoReset) is the master switch for the whole AsyncOutput pack's memory. By default the pack wipes every one of its global dictionaries at the start of each queued run - that's what "auto reset" means here. This node flips that behavior on or off from inside the graph, and it's the first thing to reach for when the "collect then callback" pattern acts like it's got amnesia.

    Why does the pack wipe itself so aggressively? Because the author built state as a side effect of execution, and ComfyUI's execution model doesn't promise anything about node state across passes. Auto-reset is the safe default: it makes sure a stale collection from the previous run can't leak into the next one and fire your callback with garbage. The hook that does the wiping is registered with PromptServer.instance.on_prompt_handlers, so it runs before each prompt is executed, and it clears the storage, counter, multiline-yield, and remote-control dicts all at once.

    How it works

    It's a module-level global flag, not per-workflow data. Set global_auto_reset to true and every run starts with empty AsyncOutput memory. Set it to false and whatever the Collection and Emitter nodes stashed survives into the next queued run - which is what you want if your loop depends on state accumulating across several runs, but it also means you're responsible for cleanup. The node's own output, AsyncOutputModule_AutoReset (BOOLEAN), just echoes the current flag value back so you can inspect or log it.

    The inputs that matter

    Just one, really:

    • global_auto_reset (BOOLEAN, default true) - true = forget everything before each run; false = keep state across runs until you clear it yourself.

    Installing it

    Same as the rest of the pack - no dependencies, no model downloads. ComfyUI Manager → search "AsyncOutput" → install and restart, or:

    cd ComfyUI/custom_nodes
    git clone https://github.com/teddy1565/ComfyUI-AsyncOutput
    

    It sits under AsyncOutput/Deprecated(ComfyUI NOT Turing complete)/Global.

    Where people get burned

    The classic mistake is leaving auto-reset on while trying to use this pack to carry state between queued runs - the collection is wiped before the next run even starts, so your callback either never fires or fires empty. If you're doing that, disable auto-reset. The counter-mistake is disabling it and then wondering why an old run's data shows up in the next workflow; use AsyncOutputGlobalManualReset to wipe when you need a clean slate.

    One more quirk worth knowing: the manual-reset node in this pack doesn't only clear memory - it also sets the auto-reset flag to whatever boolean you pass it. So if you've got a Global Memory Reset node wired to a false toggle, you're simultaneously disabling auto-reset for the process. Not a bug to fight, just something to be aware of before you put both nodes in the same graph.

    CategoryAsyncOutput/Deprecated(ComfyUI NOT Turing complete)/Global

    Inputs (1)

    NameTypeDefaultDescription
    global_auto_resetBOOLEANtrue

    Outputs (1)

    NameTypeDescription
    AsyncOutputModule_AutoResetBOOLEAN