Procedure Builder: Debugging Sub-Procedures From a Parent Procedure

Currently, since sub-procedures are not instantiated like procedures, they do not produce execution logs. However, since a sub-procedure is also a procedure step, the result of that sub-procedure is represented in the steps object of the parent procedure

If you're receiving a specific error, it should correlate to an individual step. For example, if you receive the following error: "Cannot read property 'Example' of undefined", then you know that there is something wrong with the Example object. You should make sure that you are giving your objects and properties unique names that correlate to the specific step they're in. This setup will help you understand where the error is.

Generally speaking, it's likely that if a step fails, then it's the last one run for the sub-procedure and therefore you should see it as the results of the procedure step.

Finally, the best way to debug a sub-procedure is to pass the `steps` object into your done() function. This will give you visibility into which steps have executed up to the point where the sub-procedure completes or returns an error.