Python Activity: No import Module named skimage

20.10.4-beta.1+Branch.release-v20.10.4.Sha.37d549846d5ef51c36ecc7e3bab8ad2ae1436ee9

Source: Load Python Script

Message: One or more errors occurred.

Exception Type: System.AggregateException

RemoteException wrapping System.AggregateException: One or more errors occurred. —> RemoteException wrapping System.InvalidOperationException: Error loading Python script —> RemoteException wrapping System.ServiceModel.FaultException`1[[System.ServiceModel.ExceptionDetail, System.ServiceModel, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089]]: ImportError : No module named skimage

Server stack trace:
at System.ServiceModel.Channels.ServiceChannel.ThrowIfFaultUnderstood(Message reply, MessageFault fault, String action, MessageVersion version, FaultConverter faultConverter)
at System.ServiceModel.Channels.ServiceChannel.HandleReply(ProxyOperationRuntime operation, ProxyRpc& rpc)
at System.ServiceModel.Channels.ServiceChannel.Call(String action, Boolean oneway, ProxyOperationRuntime operation, Object ins, Object outs, TimeSpan timeout)
at System.ServiceModel.Channels.ServiceChannelProxy.InvokeService(IMethodCallMessage methodCall, ProxyOperationRuntime operation)
at System.ServiceModel.Channels.ServiceChannelProxy.Invoke(IMessage message)

Exception rethrown at [0]:
at System.Runtime.Remoting.Proxies.RealProxy.HandleReturnMessage(IMessage reqMsg, IMessage retMsg)
at System.Runtime.Remoting.Proxies.RealProxy.PrivateInvoke(MessageData& msgData, Int32 type)
at UiPath.Python.Service.IPythonService.LoadScript(String code)
at UiPath.Python.Impl.OutOfProcessEngine.<>c__DisplayClass13_0.b__0()
at System.Threading.Tasks.Task`1.InnerInvoke()
at System.Threading.Tasks.Task.Execute()
— End of stack trace from previous location where exception was thrown —
at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
at UiPath.Python.Activities.LoadScript.d__12.MoveNext()
— End of inner exception stack trace —
at UiPath.Python.Activities.LoadScript.d__12.MoveNext()
— End of inner exception stack trace —
at UiPath.Shared.Activities.AsyncTaskCodeActivity.EndExecute(AsyncCodeActivityContext context, IAsyncResult result)
at System.Activities.AsyncCodeActivity.System.Activities.IAsyncCodeActivity.FinishExecution(AsyncCodeActivityContext context, IAsyncResult result)
at System.Activities.AsyncCodeActivity.CompleteAsyncCodeActivityData.CompleteAsyncCodeActivityWorkItem.Execute(ActivityExecutor executor, BookmarkManager bookmarkManager)

Can Someone help me with this error, I have scikit-image already installed in my system, and my python script also running fine using cmd.

Hi @roopali_jain

This may help you!!!

Thanks!!
Happy Learning!!

@roopali_jain

Is in your environment do you have one or more python versions installed?

If so, then switch to 3.6 and install scikit-image

OR you can share your flow which you are getting error

Thanks

I have tried this already, still issue persists

I have installed python 3.9, is it needed to install 3.6 ?

@roopali_jain

Previously UiPath Python scope has upto 3.6 only, but now it got update to 3.9 also, but you can try using a sample script and try to run, If the error then share the screenshot, else you have check with the installation of the module

Thanks

I have uninstalled python 3.9 also and switched to python 3.6.8 even though facing same issue. Attached is the error snapshot. Please let me know you comments…
Is there anything I’m missing?
Yes, even I tried small incrementing number example using python script which doesn’t contains any packages import like scikit-image, its running and working fine, so there is no issue with installation module. This error is coming when i am using skimage imports in my python script which basically working fine with vsCode and cmd.

Thanks in advance

Hi @Srini84 ,

I think, m doing some mistake in passing parameters to the python method using UIPath, I need to pass 2 arguments with images path. Can you help me with this:
syntax of python method: def snapCompare(benchmark,output, algorithm=“kmeans”, threshold=0.1): I am passing like this:
image

Thanks