Slice Machine Error: An error occurred with Segment (code: 'delivery_failure')

This error is logged in my console where I ran my slice machine, how to get rid of it?

An error occurred with Segment {
  code: 'delivery_failure',
  reason: TypeError: fetch failed
      at Object.fetch (node:internal/deps/undici/undici:11730:11)
      at process.processTicksAndRejections (node:internal/process/task_queues:95:5)
      at async Publisher.send (/Users/cody/Code/lf-web/node_modules/.pnpm/@segment+analytics-node@1.1.3/node_modules/@segment/analytics-node/dist/cjs/plugins/segmentio/publisher.js:151:34) {
    cause: Error: getaddrinfo ENOTFOUND api.segment.io
        at GetAddrInfoReqWrap.onlookupall [as oncomplete] (node:dns:118:26) {
      errno: -3008,
      code: 'ENOTFOUND',
      syscall: 'getaddrinfo',
      hostname: 'api.segment.io'
    }
  },
  ctx: Context {
    attempts: 1,
    event: {
      timestamp: 2024-01-23T07:37:56.297Z,
      integrations: {},
      event: 'SliceMachine Page View',
      type: 'track',
      properties: [Object],
      context: [Object],
      userId: '**HIDDEN**',
      messageId: 'node-next-**HIDDEN**',
      _metadata: [Object]
    },
    _id: '41b51dcc-5e5b-4689-b790-b172f33b4008',
    logger: CoreLogger { _logs: [Array] },
    stats: NullStats { metrics: [] },
    _failedDelivery: { reason: [TypeError] }
  }
}

Hello,

Thank you for the report of this error. It's a bug we are planning to fix in the next release. You can continue to use Slice Machine as it's non-blocking.

Xavier

2 Likes