ComfyUI Node
VRGDG_PythonCodeRunner
A ComfyUI node in VRGDG/General with 3 inputs and 3 outputs.
VRGDG_PythonCodeRunner
- result_text
- result_json
- has_error
◄python_code# Available vars: input_text, input_json, json, math, re
# Safety mode: imports, filesystem/process/network APIs are blocked.
# Set `result` to any value.
data = json.loads(input_json) if input_json.strip() else {}
result = json.dumps(data, indent=2)►
◄input_text—►
◄input_json—►
CategoryVRGDG/General
Inputs (3)
| Name | Type | Default | Description |
|---|---|---|---|
| python_code | STRING | # Available vars: input_text, input_json, json, math, re # Safety mode: imports, filesystem/process/network APIs are blocked. # Set `result` to any value. data = json.loads(input_json) if input_json.strip() else {} result = json.dumps(data, indent=2) | — |
| input_textopt | STRING | — | |
| input_jsonopt | STRING | — |
Outputs (3)
| Name | Type | Description |
|---|---|---|
| result_text | STRING | — |
| result_json | STRING | — |
| has_error | BOOLEAN | — |