Aggregate node makes up records

Describe the problem/error/question

We have a flow that works like a map-reduce: It takes an object containing an array, splits the array into several items, then aggregates them back in order to perform a code-node summary.

What we have found, is that the aggregate step “invents” items. This looks like an workflow isolation bug because these invented rows seem to bleed in from previous workflow runs.

What is the error message (if any)?

Please share your workflow

Share the output returned by the last node

Here you can see two different executions, one with 1 item and one with 14 items. The aggregate step always produces an array of 18 items.

Information on your n8n setup

instance information

Debug info

core

  • n8nVersion: 2.1.1
  • platform: docker (self-hosted)
  • nodeJsVersion: 22.21.1
  • nodeEnv: production
  • database: postgres
  • executionMode: scaling (single-main)
  • concurrency: -1
  • license: enterprise (production)
  • consumerId: 2d4ac391-ed5e-4c37-9e68-911c31a108a5

storage

  • success: all
  • error: all
  • progress: false
  • manual: true
  • binaryMode: s3

pruning

  • enabled: true
  • maxAge: 336 hours
  • maxCount: 10000 executions

client

  • userAgent: mozilla/5.0 (macintosh; intel mac os x 10_15_7) applewebkit/537.36 (khtml, like gecko) chrome/143.0.0.0 safari/537.36
  • isTouchDevice: false

Generated at: 2025-12-24T15:16:08.070Z

Perhaps it’s getting this data from older runs? I would manually view each data output to verify which ones are fake and which ones are the ones you want.