Parallel activity doesn't work with a while activity inside it

I’ve been working in a project that I have to run some activities in parallel. I’ve been setting some sequences inside a parallel activity and inside one of these sequences I have a while activity.

The issue here is that when the process reach the while activity inside one of the sequences that is inside the parallel activity, the other sequences that also are inside the same parallel activity doesn’t continue running. All the activities in all the sequences stop running and wait for the while activity that is set for only one of the sequences, not for all of them.

Does anyone here knows how to deal with it?


Welcome to UiPath Community…!

Can you please change the category to Help from feedback for a better response?

Also, are you using multiple parallel activities or single parallel activity with multiple branches?


Hello Rahul!

Honestly I don’t know how to change the category of this post… I couldn’t find the option to change it…

Answering you question: I’m using one only parallel activity and, inside this parallel activity, I have a few sequences. Inside one of these sequences I have a while activity.

Hi @YWLLIN please check if there is error or not in that while activity because if the error is happen in any individual process then other process will not execute in parallel process.

Run the process in debug mode to check…

Hi Tapan!

I’m already running the process in debug mode, I’m not getting any error message. The process just keeps waiting the while activitie, even if the other sequences have nothing to do with this while activitie…

For example: Imagine a parallel activity, named “A”, in with you have four sequences running in parallel, named “Seq 1”, “Seq 2”, “Seq 3” and “Seq 4”. The activities in Seq 1 are completely independent of the other sequences. The same for the activities in the other sequences. Imagine you have a while activity inside the Seq 1 in some point of this sequence. When the process reaches the while activity in Seq 1, the activities in Seq 2, witch have nothing to do with the activities in Seq 1 (even with the while activitie), stop running to wait the while activitie in Seq 1. The same occurs with the activities inside the other sequences.

Parallel doesn’t actually run the activities at the same time. It still runs them sequentially. It just doesn’t continue past the parallel until all sections of the parallel are complete.

Hi, Paul!

I’m not sure if that is the case… If the parallel runs sequentially, it should run an entire sequence and then start to run the next sequence…

In my project, the activities in all the sequences are executed until the process reaches the while activity. When it reaches the while activity, all the other activities stop, even in the middle of the sequence. None of the sequences runned completely, all of them stopped somewhere in it’s middle.

// A Parallel activity operates by simultaneously scheduling each Activity in its Branches collection at the start. It completes when all of its Branches complete or when its CompletionCondition property evaluates to true . While all the Activity objects run asynchronously, they do not execute on separate threads, so each successive activity only executes when the previously scheduled activity completes or goes idle. If none of the child activities of this activity go idle, this activity execute in the same way that a Sequence activity does.//

1 Like

What @postwick tried to say is that if you go to a deep level, those activities, will never run in parallel, instead you can imagine it as the bot switching continuously from A to B, and then back to A… super fast, until both workflows reach the end, is like if the active point keeps changing from parallel path to parallel path, simulating this “parallel” action

Using Step into, since you’re stopping the activity from doing this “fast” changes from A to B, seems that the parallel activity is not working, but it’s because the changes from A to B, are currently slower


@postwick and @ignasi.peiris, now I see! Thanks for the help!

1 Like

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