Logging Help

Hello,

I am struggling with a simple way to get fairly detailed logs on what my automation is doing. I know I could add a bunch of log activities, but surely there has to be a better way.

Ideally I would like to have UiPath write to the log for each activity it executes. Is there a way this can be configured for an entire automation or even better an unattended bot?

not recommended when bot is executed in production.
For development / debugging we can enable:

Why is it not recommended for production? My current company routinely requires fairly verbose logs to capture errors in production. It seems that would be helpful with UiPath to see where it failed when a website was a little slow to respond.

Set the Robot to verbose logging. Be prepared for massive logs.

I thought I had done that. Can you list the steps so I can confirm i did it correctly?

You can achieve this with Log Message activities. Also, if you’re doing proper error handling the logs will automatically contain the necessary information in fault messages.

Besides my companies culture around logging, one of the challenges I am having with the automations is that I get fairly generic errors. Errors along the line of “The element was not found”. I’m like … which element?

That’s why you have Log Message activities denoting the steps the automation is taking, so you know where it was when it faulted. But it also sounds like you’re not on modern, because on modern many activities (such as Use Application/Browser) auto-log so you will then know which one failed.

I am using modern activities. I’ve never seen the option for auto-log though. That sounds promising.

Here is what I see for the properties window for the Use Application/Browser activity.

Each Project / RPA Team … has its own set of Rules & Best Practices. So define your own.

We helped several teams to change from over logging to clear logging. Having a mass logs is sometimes as unhelpfully as not having logs. Having a balanced log approach in place leads quick and reliable to the location of interest (e.g. where a bug occurs) and within analysis the details can be inspected.

Teams liked this for many reasons: less log work to do, relaxed when get audited…

But still you decide what you want to. You already mentioned the Verbose log (set it at assistant / robot level). And we did not tell for no logging, we mentioned balanced / controlled a clear reliable and traceable logging with log message seperated at Trance and Info level.

1 Like

It’s not an option. It happens automatically. Check App State does it:

image

And so does Use App/Browser:

image

That doesn’t happen for me. Even though I’ve set the bot to verbose logging I only get an entry that package execution has started.

What version of UiPath.System.Activities and UiPath.UiAutomation.Activities are you using?

image

I’m on 21.10.3 and 21.4.4 and always see the auto-logging for Use App and Check App State. Are you sure your project is actually set to modern? Or did you just select “show modern” in the Activities filter?

Correct. Modern Design Experience is set to yes. but I see different options, so is there something else that I need?

What version of Studio? Is it actually Studio or StudioX? Is it a Process project, or Library? Windows Legacy?

I just looked at one of my library projects and the screen looks like yours. You’ve created a library project, not a process project. Was this intentional?

Yes that project was. But maybe it shouldn’t have been. I also have another project that is a process project. And that is where all the library components are put together for the automation.

What we wanted to do was have re-useable components in a library. Like login, access the reports section, etc. So those functions are in the library.

In any case, both projects are built in Studio and Windows projects (not Windows legacy).

This is all correct, and is how we do things. We have many libraries for common actions in our environment.

I wonder if that’s why you don’t see the auto-logging. The activities aren’t directly in your process project, they’re inside custom activities. Might be that the two things aren’t handled the same, either by design or by accident from UiPath.