How to "Run Python Script" only?

Hi everyone!

I would like to use “Run Python Script” only but always got error message “The specific python path is not valid”.Settings please refer to picture 1.

For Library Path and Path, I put the same path as below:
“C:\Users\huanglikai\AppData\Local\Programs\Python\Python313\python.exe”

I have saved my python code in a file (called test.py). Settings please refer picture 2.

Wondering where I got wrong?


@tombillydavid3,

Try using this readymade test code to try if it’s working.

@tombillydavid3

Path and library path are not same…and you would give location till folder not file exe

Cheers

got this error this time…

@tombillydavid3

Please open details and check the error

Also in general it needs .net runtime 5 or 6 based on the python version…so check the same. Details basically will have the error details

Cheers

After installing .NET, got this error this time.

//Quote
System.InvalidOperationException: Error initializing Python engine —> System.InvalidOperationException: Python instantiation exception
Python Invoker program exception:
Exception has been thrown by the target of an invocation.
at UiPath.Shared.Service.PythonResponse.ThrowExceptionIfNeeded()
at UiPath.Python.Service.PythonProxy.Initialize(String path, String libraryPath, Version version, String workingFolder)
at UiPath.Python.Impl.OutOfProcessEngine.Initialize(String workingFolder, CancellationToken ct, Double timeout)
at UiPath.Python.Activities.PythonScope.ExecuteAsync(NativeActivityContext context, CancellationToken cancellationToken)
— End of inner exception stack trace —
at UiPath.Shared.Activities.AsyncTaskNativeImplementation.BookmarkResumptionCallback(NativeActivityContext context, Object value)
at UiPath.Shared.Activities.AsyncTaskNativeActivity.BookmarkResumptionCallback(NativeActivityContext context, Bookmark bookmark, Object value)
at System.Activities.Runtime.BookmarkWorkItem.Execute(ActivityExecutor executor, BookmarkManager bookmarkManager)
Unquote//

@tombillydavid3

Can you show what paths you gave and what si the python version. Python package in UiPath version and what version of .net is installed

Library path should be a .dll file and python path would generally be like python310

Cheers

Library Path:“C:\Users\huanglikai\AppData\Local\Programs\Python\Python313\python313.dll”
Path:“C:\Users\huanglikai\AppData\Local\Programs\Python\Python313”
UiPath.Python.Activities version:1.9.0
.NET version:6.0.428

.NET version : 6.0.36

Not sure if there’s anything relevant to what I use is Parallels Desktop?

If you have multiple versions of python installed on your machine keep only one. Remove other.

Check if the target is x64 or x86.

@tombillydavid3

Your python version is the issue …current support is 3.12 or lower

Cheers