Problem with loading comand prompt by python

When trying send cmd command to command prompt in python script node it returns error

‘cmd’ is not recognized as an internal or external command,
operable program or batch file

But when running same code in other python compiler outside knime(like Jupiter) it works.
How to overcome this problem

Hi @sahak08 and welcome to the community.

The error message you’re showing is just a standard Windows command line error when it can’t find an executable. So maybe there’s an issue with your path or similar?

Can you post your workflow that includes the code that you’re using within the Python Script node?

Thank you ScottF for response. Sure I am going do that. What about path. I check that. I mean path variable exist and it has links to either command prompt and program be called by it(clustalw2). And it works perfectly when I am running that code from Jupiter or Pycharm, but it is showing error message when running from Python Script node from Knime. My question is more about why python run from Knime fails to recognize environmental variables.
BLAST_the_tree.knwf (87.1 KB)

Hi @sahak08 -

So far I haven’t been able to reproduce the problem on my end using your workflow - my Python environment is able to call out to external executables using cmd.

Are you using a different Python environment with KNIME than the one you’re using with Jupyter or PyCharm? Perhaps C:\WINDOWS\system32 isn’t included in the PATH of the Python environment you use with KNIME?

Thank you @ScottF for response. With Knime I am using conda environment the same as with Jupiter and Pycharm. When I am installing some libararyes by conda they becoming available for Knime, Jupiter and Pycharm. But either way if it runs on your PC than I guess the problem is in my os rather in Knime, so I am satisfied with that. For now I can just mention full path to cmd.exe and it will work until find what’s is wrong.