Within your workflows, a script error may occur. To understand what caused the failures its important to retrieve the error to diagnose the problem.


There are two ways to retrieve errors from scripts within vCommander.


*Note - Powershell scripts require the following debug option to be turned on. 


#enable script output logging

log4j.logger.com.embotics.vlm.service.task.a.e=DEBUG


For instructions on enabling debug logs please use the following KB article


Using the "capture program output as comment" option.
 

  • Within your workflow, select the step the script or command will execute from. Ensure the “Capture program output as comment” is selected within the step.  

  • To view the comment of the step:
  • After the workflow has been run, go to Tools then Workflow Status. 
  • Right Click the Workflow and select Workflow Management
  • Click the Comments tab, and view the error.




Send an email with the output of the script or command.


  • Add a step within your workflow to send an email, then, add a variable within the Email Body section to display the output of the script in a previous step within the workflow.
  • Ensure the step your script runs from is set to proceed to next workflow step, so the email is generated and the workflow does not stop at the failure.
  • Add a Send Email step to your workflow. Select the #{.} hyperlink to see a list of variables to add to the Email Body.



  • Scroll down the list and select the Output option. You will see that within the top of the window in the Email Body section, the variable has been added. Read the details of the variable to change the step which the email will output for. Example: #{steps[2].output} would output the error of step 2 within your workflow.


  • Fill out the Address List option within the email step to indicate what addresses will receive the email.