I'm trying to get around the bpm_package being mandatory by creating an empty back with start execution listener:
var node =workflow.createPackage(); execution.setVariable('bpm_package', node);
This complains that:
Caused by: org.activiti.engine.ActivitiException: Passed value is not an instance of ActivitiScriptNode, cannot set variable value. at org.alfresco.repo.workflow.activiti.variable.ScriptNodeVariableType.setValue(ScriptNodeVariableType.java:76)
I appreciate the reply, but this wasn't what I was looking for. Let me elaborate:
I have a subprocess that is spun off from the main one, this subprocess is no longer linked to the bpm_package from the main workflow, so will not complete because the bpm_package property is mandatory. I don't want to relink the package, because I don't want the documents to appear on two workflows when they only belong to the main process.