Python snippet error

Hi Guys,

I am quite new to Knime and I have a problem regarding running Python Snippet

I have to combine all the xml files into one big xml file. I have written a python script for that which is running fine in its runtime environment. I have used the below mentioned import statement and I am getting error.

from xml.etree import ElementTree

ERROR     PythonSnippetNodeModel               File "C:\Python27\lib\xml\etree\", line 1182, in parse
ERROR     PythonSnippetNodeModel                 tree.parse(source, parser)
ERROR     PythonSnippetNodeModel               File "C:\Python27\lib\xml\etree\", line 647, in parse
ERROR     PythonSnippetNodeModel                 source = open(source, "rb")

I am not sure what the problem is but I hope if someone can help me with it. Your help will be highly appreciated.


I can't solve your problem but when I have those types of incidents, I use the misc -> External tool node to execute  my python programs. It avoids you to copy your script in the knime python snippet interface.

The error messages itself seem to come from your script (see ). To troubleshoot the problem one needs to find out the differences from the script running inside/outside KNIME. But there are far too less information for me to do this (input table, how the script looks like, how it was called outside).