Python node [GOT CREATED]

OK, the first beta version is ready to be tested.

Example command to start it:

docker run -it --rm --name n8n -p 5678:5678 -v ~/.n8n:/home/node/.n8n n8nio/n8n:PR-4295-python-code-node

There is now an additional setting in the Code-Node where Python can be selected:

A few important things to consider:

  • This is a beta. So there are probably still issues. It is also possible that things will change in the final production version. So workflows that get created now may not work in the production version without modifications.
  • We did not do a security review yet. That means you should not give users you do not trust access to an n8n instance with this n8n version running.
  • The Python editor is very basic. It only provides syntax highlighting but not the more fancy things like auto-complete or lining like the JavaScript version does.

Regarding usage

The variables that are available are identical between JavaScript and Python. But because of variable naming restrictions in Python do they not start with $ but rather with _. So it is for example _input.all(), _input.first().json, _itemIndex, _workflow, and so on.

So give it a try and please share with us any feedback you have and problems you face. Also if you tried it, but did not face any issues and have no feedback. Then we know that one more person tested it, which is also an important data point.

Thanks a lot for your help and support!

9 Likes