Actor filter not working in subprocess

Here I’ve got a main process calling a subprocess with an ACME employee as an initiator and an actor filter with initaitor manager on both main and subprocess.

example

But in the subprocess I can’t use a filter because :

org.bonitasoft.engine.core.process.instance.api.exceptions.SActivityStateExecutionException: PROCESS_DEFINITION_ID=5744411762551475989 | PROCESS_NAME=Pool1 | PROCESS_VERSION=1.0 | PROCESS_INSTANCE_ID=37 | ROOT_PROCESS_INSTANCE_ID=36 | FLOW_NODE_DEFINITION_ID=7110579240968224013 | FLOW_NODE_INSTANCE_ID=119 | FLOW_NODE_NAME=Step4 | no user id returned by the user filter org.bonitasoft.engine.core.process.definition.model.impl.SUserFilterDefinitionImpl@348fe7 on activity Step4

In step 6 I’m setting processInstance.startedBy with the processId of the main process which is mapped before the subprocess starts:
import org.bonitasoft.engine.api.ProcessAPI;
import org.bonitasoft.engine.bpm.process.ProcessInstance;
import java.util.logging.Logger
ProcessAPI processAPI = apiAccessor.getProcessAPI();
ProcessInstance processInstance = processAPI.getProcessInstance(processInstanceId);
processInstance.startedBy=Long.valueOf(id);
Logger logger = Logger.getLogger(“org.bonitasoft”);
logger.severe(“Entro:”+processInstance.getStartedBy());

How can I get the filter to work in the subprocess?

Hi,

Can you share your process .bos file so I can give it a try?

Thanks