comfy-org/comfy-cli

comfy-custom-nodes-caching

Packaged fallback for a custom node's cache signature and why it silently recomputes.

Voir la source

Mode d’emploi

  1. Copiez la commande et examinez le paquet avant de l’installer dans votre environnement agent.
  2. Consultez le document original pour les outils, identifiants et environnements requis.
  3. Décrivez les entrées et le livrable souhaité ; comparez la sortie aux sources.
npx skills add https://github.com/comfy-org/comfy-cli --skill comfy-custom-nodes-caching

Avant de commencer

  • L’installation n’inclut ni abonnement au modèle, ni quota API, ni accès aux fichiers.
  • Étoiles et installations reflètent l’activité, pas un test indépendant de qualité ou de sécurité.
Document Skill original

Rendu depuis le dépôt source en conservant titres, exemples, code, tableaux, liens et images.

Execution caching fallback

A node declares its cache signature with fingerprint_inputs (V3) or IS_CHANGED (V1). Declaring neither lets the node's declared inputs decide, which is the right default; add one only when the output depends on something those inputs do not capture.

The signature is taken before the graph runs, so a linked input arrives as None — only widget values, literals and the UNIQUE_ID hidden are real. The other hiddens are not: the signature pass calls get_input_data with no dynamic prompt and no extra data, so PROMPT arrives as {} and DYNPROMPT, EXTRA_PNGINFO, EXECUTION_LIST and the auth-token hiddens arrive as None. Fingerprinting one of those yields a constant, which is the stale-output failure this file warns about. The exception is an input declaring rawLink, handed its [node_id, output_index] reference instead. Reaching into a tensor or model through either form raises, and the executor catches that, logs a warning, and makes the signature a not-a-number value that never compares equal to itself. A broken signature therefore shows up as a node that recomputes every run — never as a crash. Return scalars, and lists/tuples/dicts whose keys are all one type, of scalars: a set, a non-str Enum or a dataclass becomes an unhashable sentinel that recomputes every run, and a dict with mixed-type keys raises outside that handler.

The signature is not local: a node's cache key embeds every ancestor's signature, so one value that never repeats forces its whole downstream cone to recompute. A wall-clock reading is the usual cause — correct for a live fetch that must always re-read, a cache defeat for everything after it. Derive the value from what the output depends on: resolved widget values, plus external state the node reads, such as a file's size and modification time — a content digest instead, as core's LoadImage does, when a file may be rewritten in place and leave both unchanged — environment variables, and a version constant bumped when behaviour changes.

Prove both halves: call the signature twice with identical arguments and require equality, then change one field and require a difference. Failing the first is a cache defeat; failing the second is a stale-output bug. Marking a node non-idempotent or as producing intermediate output changes cache behaviour separately and does not substitute for a correct signature.

Tâches connexes

du même dépôt

Autres Skills

Tous les Skills
comfy-org
Communauté

comfy

Generate images, videos, audio, and 3D via ComfyUI — CLI surface, workflow creation hierarchy (template → fragment → raw JSON), domain gotchas, cloud auth, multi-stage orchestration.

installations
2
GitHub Stars
1 k
Mis à jour
20 oct.
comfy-org
Communauté

comfy-agent-permissions

Use when a permission blocks the local comfy agent — a folder it cannot read or write, a host a download was refused for, a shell it does not have — to know what the agent may reach by default, how a request is recorded (requestpath, requesthost) and how only the user approves it (the agent panel or the in-chat card), the start-time settings, and what can never be granted.

installations
2
GitHub Stars
1 k
Mis à jour
20 oct.
comfy-org
Communauté

comfy-build

Build a custom ComfyUI environment on the Comfy developer platform with comfy-cli: turn a local install, a ComfyUI Desktop snapshot, a workflow JSON, or nothing but a Dockerfile, a Modal script or a sentence into a committed comfy-build.yaml and a green release. Use whenever the user wants to package, build, pin, or reproduce a ComfyUI environment, decide the dependency pins before the first cut, or read a failed build's log. Stops at a green release; comfy-deploy takes it from there.

installations
2
GitHub Stars
1 k
Mis à jour
20 oct.
comfy-org
Communauté

comfy-build-authoring

Reference skill cited by comfy-build. Read it with comfy skills show comfy-build-authoring when authoring a comfy-build.yaml definition by hand — the user has no ComfyUI install to scan, or you are editing a spec's models and customNodes directly. Covers searching the node registry, resolving model filenames to public sources, choosing the directory a weight lands in, and every field of the definition schema.

installations
2
GitHub Stars
1 k
Mis à jour
20 oct.