bump version to 2.0.0
- Critical change that ensures reliablity and **should** have no bad side effects, but when you see any, please report: DICT, LIST, SET and Data List nodes (plus the DICT/LIST-taking STRING nodes) now degrade gracefully when their data source is not connected (`None`) instead of raising: read/query nodes return their natural "no data" result (the `get` default, an empty list, `False`, `0`, `None`), and transform nodes behave as if given an empty container. - Add a "continue if not empty" flow-control node: it passes a value through unchanged when it is non-empty, and blocks execution (via an execution blocker) when the value is empty. It is list-aware (`INPUT_IS_LIST` / `OUTPUT_IS_LIST`), so it is immune to ComfyUI's empty-input batching crash and passes data lists through unchanged. By default the block is silent; an optional `message` can be set to show a dialog. Use it before nodes that cannot handle an empty input (e.g. a node receiving an empty Data List) to stop execution instead of failing.
This commit is contained in:
@@ -371,6 +371,7 @@ class StringFormatMap(ComfyNodeABC):
|
||||
FUNCTION = "format_map"
|
||||
|
||||
def format_map(self, template, mapping):
|
||||
mapping = mapping if mapping is not None else {}
|
||||
try:
|
||||
result = template.format_map(mapping)
|
||||
return (result,)
|
||||
@@ -778,6 +779,7 @@ class StringDataListJoin(ComfyNodeABC):
|
||||
|
||||
def join(self, sep, strings):
|
||||
separator = sep[0] # everything comes as a list, so sep is list[str]
|
||||
strings = strings if strings is not None else []
|
||||
return (separator.join(strings),)
|
||||
|
||||
|
||||
@@ -806,6 +808,7 @@ class StringListJoin(ComfyNodeABC):
|
||||
FUNCTION = "join"
|
||||
|
||||
def join(self, sep, strings):
|
||||
strings = strings if strings is not None else []
|
||||
return (sep.join(strings),)
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user