fix: return primitives instead of single-item lists in AutoLoopCalculatorTTSBatch

The AutoLoopCalculatorTTSBatch node was returning its output variables
wrapped in single-item lists (e.g., `[current_chunk_text]`) instead of as
raw primitive values. This caused downstream nodes expecting raw types
(like standard string replacement or string concatenation nodes) to crash,
since Python lists do not have `.replace()` or `.join()` methods.

The brackets were removed from the `return` statement so the node now properly
outputs the exact primitive values.
This commit is contained in:
Meisoftcoltd
2026-05-23 13:45:37 +00:00
parent dc3f4c2c07
commit 4e49b99e2d
2 changed files with 9 additions and 7 deletions
+8 -6
View File
@@ -8,14 +8,16 @@ sys.modules['comfy.model_management'] = unittest.mock.MagicMock()
sys.modules['folder_paths'] = unittest.mock.MagicMock()
# Mock internal import to prevent syntax error on register_node
class DummyRegister:
def __call__(self, cls):
return cls
sys.modules['__main__'].register_node = DummyRegister()
import types
dummy_module = types.ModuleType("dummy")
dummy_module.register_node = lambda c: c
sys.modules[__package__ or '.'] = dummy_module
try:
import loop
with open('loop.py') as f:
code = f.read()
code = code.replace('from . import register_node', 'def register_node(c): return c')
exec(code)
print("Syntax is OK")
except Exception as e:
import traceback