Python code editor (ace_code_editor)¶
What it does: Allows you to insert multi-line Python code directly through the block's built-in editor box.

Inputs¶
- No classic connectors.
- Field
code: multi-line Python code.
Output¶
- None (statement block).
When to use it¶
- When you need a longer manual Python part inside a block program.
- Advanced scenarios that cannot be conveniently assembled with standard blocks.
Tips and pitfalls¶
- Keep embedded code short and well commented.
- An error in this code will cause the generated Python to fail as well as the manual script.
Generated Python example¶
# code from the editor is inserted 1:1 into the resulting Python
for i in range(3):
print(i)