An ExceptionDetail, likely created by IncludeExceptionDetailInFaults

I am trying to run my robot (overnight) through the command line and a temporary self-made scheduler in Python. Unfortunately, I run into the following error code every time:

An ExceptionDetail, likely created by IncludeExceptionDetailInFaults=true, whose value is: UiPath.Core.ElementOperationException: Timeout reached. ----> System.Runtime.InteropServices.COMException: Timeout reached. at UiPath.UiNodeClass.BringIntoView() at UiPath.Core.UiElement.BringToForeground() --- End of inner ExceptionDetail stack trace --- at UiPath.Core.Activities.ScopeActivity.OnFaulted(NativeActivityFaultContext faultContext, Exception propagatedException, ActivityInstance propagatedFrom) at System.Activities.Runtime.FaultCallbackWrapper.Invoke(NativeActivityFaultContext faultContext, Exception propagatedException, ActivityInstance propagatedFrom) at System.Activities.Runtime.FaultCallbackWrapper.FaultWorkItem.Execute(ActivityExecutor executor, BookmarkManager bookmarkManager)

I believe this might have something to do with Windows automatically logging out (going to Sleep). Since running the same commands does not produce any error. Neither does letting the scheduler run and wait for execution.

The thing is I’ve included code in my Python script to prevent Windows from going to sleep. I’ve tested this code as well, and it works for several consecutive hours.

Moreover, I’ve also disabled all sleep/hibernate settings in Windows.

Another interesting thing to notice is, is that the robot partially executes and does some stuff the first 30 seconds. I assume this is because some code can run without actually being logged on (assuming this is the problem)?

Any advice or thoughts are welcome.

Hi @stevenvd

Did it reoccur or was it a one-off type of issue?

This error reoccurred a few times.

However, it was solved by downloading Don’t Sleep for Windows. Which confirmed my suspicion that Windows went to sleep although I turned all settings off.

1 Like

I found that starting UiPath Robot to establish an initial connection and then letting the job disconnect you from the RDC also does the trick. Other jobs can even be run without incident as long as you don’t log into the machine and log back out.

It’s wonky but it works.

I’m not sure if a definite causation to this error has been found. But I get this when I do the following:

  1. Open an Excel Workbook and get a WorkBook Application reference
  2. Pass that reference to another Sequence that will rename the default worksheet Sheet1 using hotkeys (Alt+h, then o , then r)
  3. Control returns back to the original sequence in step 1 and workbook is closed

And the message below pops up in Studio when the sequence completes execution successfully and exits.
When I open the workbook, I see that it has been renamed and saved.

An ExceptionDetail, likely created by IncludeExceptionDetailInFaults=true, whose value is:
    System.Exception: Could not retrieve the result of the job execution. This might be because a message was too large to process.

This is a show stopper for me right now! :frowning:

Yes, there seems to be an issue when an Excel Workbook Application is passed to another sequence and an action such as renaming a worksheet causes a change in the state of the Workbook Application reference.

I ran a quick test. I altered the rename sequence to open the workbook anew instead of using the Workbook Application reference, renamed the worksheet and closed the workbook.

This time, the error did not show up. This seems to be a workaround but a silly one at best because I have to close the excel and then reopen it just to rename a worksheet.

I can’t do it in the parent sequence because it contains many steps and will become too large. Besides, I have to add 2 more sheets and rename them.


This happens when individual sequence files are tested in Debug mode and the workbook reference is passed between these two sequences.

When these sequences are called inside of a Invoke Workflow from Main.xaml the error does not occur! :slight_smile: