Async method calls from custom libraries

We have a custom code library for our projects. We are then trying to do a series of asyncronous calls to different end points to authenticate an Amazon Web Service Connection then a series of calls to that AWS service.

It works perfectly when we run the code from Visual Studio, but when we import the library to UiPath, the first async call never returns.

image

Do any of you have similar experiences with asyncronous calls just running forever when calling them through UiPath?

2 Likes

We managed to find a solution for this problem today.

It seems like UiPath does not like await statements. The fix was to remove all await statements and just call Result on the Task that returns. The advantage of this also is that the method doesnt have to be async and return a task. This is the new version of the code above:

image

5 Likes

This topic was automatically closed 3 days after the last reply. New replies are no longer allowed.