I’m working with a system of workflow / subworkflow, using the dedicated “execute workflow” node.
The workflow I’m calling as a subworkflow is one I already had and that I’ve modified for that purpose.
However, when I start the process and my main WF does its job of calling the sub, I get this error :
“cannot start workflow session multiple starting steps found”.
The error seems pretty clear and if I’m posting this message it’s because I’m trying to solve the problem and to get some infos on what is possible and what isn’t.
For sure, I have to look for steps with no parents in my WF, other than the one I wish to use as a starting point. But as my subworkflow is a big one (probably not far from 200 steps), I’d be pleased if I had a way to locate that kind of node
I already checked my WF for orphan nodes, but with no success, so such a system would be a game changer for me
Besides, I was looking for a way to call a sub-WF not only by it’s ID but adding a starting stepID, which would do the job for me and might open new possibilities too.
Well… I see my message is becoming long enough to make anyone think twice before even reading it, so I’ll be stopping here
If anyone sees the light threw this topic’s window and pushes the door with an idea, I’d be pleased to thank this dear person
Export your subworkflow and sent it here for me to visualize.
We use sub-workflows for those highly used, repeatable patterns that might be common across multiple workflows. We try to keep the sub-workflows super simple, typically in the 2-10 step range. 200 steps is burdensome
We build them for very specific and narrow tasks (e.g. for running scheduled webhooks, and correcting dates for timezone offsets), which helps to simplify large workflows and makes troubleshooting and error-proofing that little bit easier.
I think you can only call a sub-workflow by its ID or its handle. I don’t think you can have multiple starting steps on the sub-workflow, which, by the description of your error, sounds like your sub-workflow has multiple starting steps.
First thing first : thanks for having read and thanks for your answers
@mark : you’re right of course, that how a subWF should be used, and that’s what I’d like to do. However, those are not my WF and I have to work with what I have. There was a node using a JS script to call the “subWF” directly with the right stepID and it was working just fine. The problem came with an update : from now on, it seems I can’t use this famous node with the script but I have to use the standard “execute WF” node… so no more stepID.
I deleted all non-mandatory steps and now my WF can call the subWF, so that’s ok. The problem is that all other steps were what made this WF so generic… which means I have to duplicate and filtrate this WF in order to keep its purpose. Well, in fact, I think I would need to cut this big WF into many atomic WFs that could call one each other if needed.
It’s going to be one hell of a job and that’s why I was wondering if there was a native system for calling a subWF with a starting stepID.
@ thiagomarcal : thanks ! Maybe you have something to check if a node as no parent (what I was looking for in the beginning ), but as I’m not the owner of those WF I can’t really share them
I know this doesn’t make things easy for you to help me, thanks anyway