@richarddenton: Can’t help but notice your signature “R2D2”
If we are logging and naming the activities, we will know which activity is throwing the error and narrow down the asset name, right? Still I would like to know the asset name when the error is thrown.
I don’t believe that even naming the Get Asset activity gives you this information. Possibly at trace level but I don’t want to have to log every asset value (as much as I love logging!)
What happens if you put your Get Asset activity into a Try Catch scope and add a write line to the exception part, writing exception.Message + vbnewline + exception.Data.ToString in it? I am not sure if it helps, but maybe…
I agree more details are a good thing. I feel like this doesn’t need to be limited to only Get Asset though, because you would essentially be outputting which variable or the value in the variable that caused the error, which could be useful with basically every activity.
Yeah, you don’t always have the luxury of good logging and a well-organized framework model for your process. But on the other hand, using good practices like simply naming your activities will identify the location of the error pretty quickly. Like, for example, naming it “Get Credentials - Email” will show that activity name when an error occurs if you are testing a workflow individually. Then, you would also want to work from a Main where initialization occurs within an Invoked workflow that is surrounded by a Try/Catch that captures the exception.Source, and that is something you would need to do anyway if you want to get which activity threw the exception.