mirror of
https://github.com/comfyanonymous/ComfyUI.git
synced 2026-02-10 13:32:36 +08:00
bugfix: pass 'prompt' and 'extra_data' to get_input_data for determine IS_CHANGED
This commit is contained in:
parent
9f2986318f
commit
e29dca958e
@ -204,7 +204,7 @@ def recursive_will_execute(prompt, outputs, current_item):
|
||||
|
||||
return will_execute + [unique_id]
|
||||
|
||||
def recursive_output_delete_if_changed(prompt, old_prompt, outputs, current_item):
|
||||
def recursive_output_delete_if_changed(prompt, old_prompt, outputs, current_item, extra_data):
|
||||
unique_id = current_item
|
||||
inputs = prompt[unique_id]['inputs']
|
||||
class_type = prompt[unique_id]['class_type']
|
||||
@ -217,7 +217,7 @@ def recursive_output_delete_if_changed(prompt, old_prompt, outputs, current_item
|
||||
if unique_id in old_prompt and 'is_changed' in old_prompt[unique_id]:
|
||||
is_changed_old = old_prompt[unique_id]['is_changed']
|
||||
if 'is_changed' not in prompt[unique_id]:
|
||||
input_data_all = get_input_data(inputs, class_def, unique_id, outputs)
|
||||
input_data_all = get_input_data(inputs, class_def, unique_id, outputs, prompt=prompt, extra_data=extra_data)
|
||||
if input_data_all is not None:
|
||||
try:
|
||||
#is_changed = class_def.IS_CHANGED(**input_data_all)
|
||||
@ -244,7 +244,7 @@ def recursive_output_delete_if_changed(prompt, old_prompt, outputs, current_item
|
||||
input_unique_id = input_data[0]
|
||||
output_index = input_data[1]
|
||||
if input_unique_id in outputs:
|
||||
to_delete = recursive_output_delete_if_changed(prompt, old_prompt, outputs, input_unique_id)
|
||||
to_delete = recursive_output_delete_if_changed(prompt, old_prompt, outputs, input_unique_id, extra_data)
|
||||
else:
|
||||
to_delete = True
|
||||
if to_delete:
|
||||
@ -340,7 +340,7 @@ class PromptExecutor:
|
||||
del d
|
||||
|
||||
for x in prompt:
|
||||
recursive_output_delete_if_changed(prompt, self.old_prompt, self.outputs, x)
|
||||
recursive_output_delete_if_changed(prompt, self.old_prompt, self.outputs, x, extra_data)
|
||||
|
||||
current_outputs = set(self.outputs.keys())
|
||||
for x in list(self.outputs_ui.keys()):
|
||||
|
||||
Loading…
Reference in New Issue
Block a user