Sometimes we are facing the issue that the robot is getting stuck in running state. It usually occurs when a System Exception is thrown while processing a transaction item (REF). Then we expect the initialization to run again.
We can safely say that Init State is restarted because of a Log Message “Start Init”. After that Log Messages it takes minutes or hours until the next activity is processed.
At some point another SE is thrown “Node not found”. Sometimes the robot terminates with a faulted Job or it takes more and more hours not doing anything.
Do you know how to solve this?
We are using 2023.10 at the moment - preparing to update to 2024.10
Hello @JenJen
You can try this
After a System Exception (SE), the Init process may restart but can get stuck for minutes or hours, leading to a “Node not found” SE. Sometimes, the job might remain faulted or inactive for too long.
Prevent Init from Sticking:
Set a timeout for the Init state to ensure it restarts automatically.
Enhance Exception Handling:
Set MaxRetryNumber to 0 for queue-level retries and adjust the SetTransactionStatus.xaml to reset transactions.
Address Orchestrator Delays:
Add log messages around GetTransactionData to spot delays. If necessary, use “Force Stop” and “Restart.”
Fix Session and “Node Not Found” Issues**:
Ensure the UiPath Assistant is active before retrying Init, and use “Kill Process”
for the UiPath Executor to clear stuck processes.
Final Steps:
Check Orchestrator Logs for execution gaps. Enable Auto-Restart under Job Triggers. Upgrade to version 2024.10 for stability fixes.
I would suggest you to put a break point in the INIT stage and debug to see where exactly is the delay
There are mainly 3 sections in the INIT stage
Section Starting with If First run - This sequence will be executed only first time when the BOT is running. During TE - this section wont be executed. So the error might not be in this section
Section 2 starting with If Max Consecutive error - This portion is executed if the process is throwing continious error for all the transactions. Based on the configured value - INIT will also throw error and stop the process
Section 3 starting with InvokeAllApplication → This will be executed everytime. So focus on this sequence and see any error is coming from this section
The problem is that we cannot recreate the situation locally. It only occurs unattended on our virtual machine in production…
It never happens in local debug mode or in our test environment per remote debug mode.
We have also noticed that at our end , sometimes process gets stuck for long hours eventually making VM go in unresponsive state not necessarily after any SE.
But we noticed that it was mainly happening due to some application updates happening on VM while bot was still running a process hence messing up the bot run.
In these situations, we had to bring back our VM by giving it a restart.