Workflow only executing twice, does not continue to loop

Describe the problem/error/question

I have created a workflow that takes a list of names and information about individuals, enriches that data, crafts a personal email, and then saves it to a draft.

The problem I’m encountering is that the loop runs the first available item matching the criteria, loops and runs the second item, and then stops. It does not continue to loop through the items that match the criteria. I don’t know why.

What is the error message (if any)?

No error message.

Please share your workflow

I couldn’t figure out how to copy and paste the workflow code.

Share the output returned by the last node

When it loops, the output is expected. The problem is that it isn’t looping.

Information on your n8n setup

  • n8n version: 1.90.2
  • Database (default: SQLite): whatever default n8n hosting is
  • n8n EXECUTIONS_PROCESS setting (default: own, main): whatever default n8n hosting is
  • Running n8n via (Docker, npm, n8n cloud, desktop app): n8n cloud
  • Operating system: MacOS 15.4.1

Why do you have two Loop Over Items nodes? The one at the end should probably just be a No-Op to combine the true and false paths out of the If node.

Also, odd things happen if you don’t route the end of your loop directly back to the Loop Over Items node, but your return path routes back to a node that preceeds that. It might work, but it might also be what is interrupting the completion of each “batch” in the loop.

The first loop over item node is to limit the API request to prevent it from timing out. I put the second because the process was not re-running so I thought it needed a loop.

Could you elaborate on No-Op?

I’m not sure what you mean in the second paragraph

There is a node called No Operation, Do Nothing which is known, for short, as No-Op. It is the same kind of node that is included when you add a Loop Over Items node to a workflow (but in that case it is labeled Replace Me. You can use that whenever you want to converge multiple paths in a workflow but you don’t want to use Merge or Aggregate or something else like that.

Regarding the 2nd paragraph…
…stick with this flow for a loop:

…but avoid doing this:

1 Like

This was it, thank you!

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.